"mailscanner reload" for Solaris?

Jeff A. Earickson jaearick at COLBY.EDU
Thu Aug 11 21:36:36 IST 2005


Thanks!  Updated my script to add a reload option, like so:

kill -HUP -`cat /opt/MailScanner/var/MailScanner.pid`

Works great, thanks.

Jeff Earickson

On Thu, 11 Aug 2005, Julian Field wrote:

> Date: Thu, 11 Aug 2005 21:16:43 +0100
> From: Julian Field <MailScanner at ECS.SOTON.AC.UK>
> Reply-To: MailScanner mailing list <MAILSCANNER at JISCMAIL.AC.UK>
> To: MAILSCANNER at JISCMAIL.AC.UK
> Subject: Re: "mailscanner reload" for Solaris?
> 
> Jeff A. Earickson wrote:
>
>> Julian,
>> 
>> I was looking at Steve Swaney's Rules_Du_Jour install script,
>> and his script does "/etc/init.d/MailScanner reload", probably
>> in Linux-land.  My Solaris /etc/init.d script is attached, having
>> not been touched in a long time.  What would a "reload" action
>> be in Solaris?  Does MailScanner catch signals?
>
> Yes.
>
> Find the PID of MailScanner from the PID File setting in MailScanner.conf.
> If this PID is 123 then do
>
> kill -HUP -123
>
> Note the -123 as opposed to 123. This will HUP the whole process group, which 
> all the children will catch and commit suicide. They are then respawned by 
> the parent, which ignores the HUP itself.
>
>
>> #!/sbin/sh
>> #
>> 
>> #---prevent core dumps
>> /usr/bin/ulimit -c 0
>> 
>> case "$1" in
>> start)
>> 	#---v4
>> 	(/opt/MailScanner/bin/check_mailscanner > /dev/null) && echo 
>> "mailscanner started"
>> 	status=$?
>> 	;;
>> stop)
>> 	kill `pgrep MailScanner` && echo "mailscanner stopped"
>> 	status=$?
>> 	;;
>> *)
>> 	echo "Usage: $0 {start|stop}"
>> 	exit 1
>> 	;;
>> esac
>> 
>> if [ $status != 0 ]; then
>> 	echo "$status"
>> 	exit 1
>> fi
>> exit 0
>> 
>
> -- 
> Julian Field
> www.MailScanner.info
> Buy the MailScanner book at www.MailScanner.info/store
> Professional Support Services at www.MailScanner.biz
> MailScanner thanks transtec Computers for their support
>
> PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
>
> ------------------------ MailScanner list ------------------------
> To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
> 'leave mailscanner' in the body of the email.
> Before posting, read the Wiki (http://wiki.mailscanner.info/) and
> the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).
>
> Support MailScanner development - buy the book off the website!
>

------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the Wiki (http://wiki.mailscanner.info/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).

Support MailScanner development - buy the book off the website!



More information about the MailScanner mailing list