MailScanner restart fails?

Denis Beauchemin Denis.Beauchemin at USHERBROOKE.CA
Thu Nov 14 19:03:26 GMT 2002


Julian,

I know you do a tremendous job with MS and I am thankful for it.  This
is a minor problem and you can take all the time you need to fix it.

If the init.d script fails to kill all processes with the killproc
function, why don't you try something different such as:
kill $(for i in $(awk '/^ *PID dir =/{print $NF}' /etc/MailScanner/MailScanner.conf)/*; do echo ${i##*.}; done)
if [[ $? == 0 ]]; then
   echo_success
else
   echo_failure
fi

You already have the process IDs, why not use them?

I've replaced the killproc by my suggestion and it works fine here. 

Denis
Le jeu 14/11/2002 à 12:07, Julian Field a écrit :
> At 16:53 14/11/2002, you wrote:
> >Le jeu 14/11/2002 à 11:34, Julian Field a écrit :
> >
> > > >And when I try to restart MailScanner it gives this output:
> > > >
> > > >[root at linuxgw rules]# /etc/rc.d/init.d/MailScanner restart
> > > >Shutting down MailScanner daemons:
> > > >          MailScanner:       We haven't got any child processes, which
> > > >isn't right!, No child processes at /usr/sbin/MailScanner line 191.
> > > >We have just tried to reap a process which wasn't one of ours!, No child
> > > >processes at /usr/sbin/MailScanner line 194.
> > >
> > > This is down to the exact order in which the processes are shut down. I
> > > have removed this error message from the next release as it causes 
> > confusion.
> >
> >Julian,
> >
> >I don't believe that not printing the error message will make things OK
> >since a restart does a stop followed by a start and the start can't
> >succeed unless the stop has stopped all processes (which it doesn't).
> 
> The error messages you included didn't imply that the stop didn't stop 
> everything.
> I know there are problems with the init.d script, it's far from perfect. I 
> need to build a whole range of machines with different versions of 
> different distributions installed, to sort this out. That takes time... 
> (and requires me to be in my office).
-- 
Denis Beauchemin <Denis.Beauchemin at USherbrooke.ca>
Université de Sherbrooke




More information about the MailScanner mailing list