Improved init.d script
Gareth
list-mailscanner at linguaphone.com
Tue Aug 7 16:16:47 IST 2007
Hello Jules,
I have made a few changes to your redhat script to add some additional
options that I use and to fix a minor bug.
1) Modified the postfix detection 'if' command to check for the
postfix.in directory at an earlier point so that the code to detect if
postfix is working in hold queue mode now works and displays a suitable
message.
2) Added postfix hold queue detection to the stop routine.
3) Added stopms and restartms command options so that you can stop and
restart mailscanner independantly.
4) Added stopmswait command option to stop mailscanner and wait for
processes to finish. This is handy in cron scripts when you want to stop
mailscanner in order to backup the database or any other maintenance.
It needs testing for people not using the postfix hold queue method.
On Thu, 2007-08-02 at 18:38, Julian Field wrote:
> Attached are new versions of the RedHat and SuSE /etc/init.d/MailScanner
> scripts.
> The improvement is obvious when you do
> /etc/init.d/MailScanner restart
> or
> service MailScanner restart
>
> It used to just wait for a fixed length of time (30 seconds by default).
> Now it watches to see when the old MailScanner processes have actually
> died, and starts it all back up again as soon as the previous
> MailScanner is dead.
>
> It is important not to 'kill -9' the MailScanner processes, as they do
> quite a bit of cleanup so they don't leave a mess behind, for example in
> /var/spool/MailScanner/incoming.
>
> Please let me know what you think of them, and if they work for you okay.
>
> Jules
-------------- next part --------------
A non-text attachment was scrubbed...
Name: RedHat.MailScanner.diff.gz
Type: application/x-gzip
Size: 1034 bytes
Desc: not available
Url : http://lists.mailscanner.info/pipermail/mailscanner/attachments/20070807/90fc5a09/RedHat.MailScanner.diff.gz
More information about the MailScanner
mailing list