#!/bin/bash # # sendmail This shell script takes care of starting and stopping # sendmail. # # chkconfig: 2345 80 30 # description: Sendmail is a Mail Transport Agent, which is the program \ # that moves mail from one machine to another. # processname: sendmail # config: /etc/mail/sendmail.cf # pidfile: /var/run/sendmail.pid # See how we were called. case "$1" in start) /etc/rc.d/init.d/sendmail-receiving start /etc/rc.d/init.d/sendmail-delivery start /etc/iscan/iscansmtps start ;; stop) /etc/rc.d/init.d/sendmail-receiving stop /etc/rc.d/init.d/sendmail-delivery stop /etc/iscan/iscansmtps stop ;; restart|reload) /etc/rc.d/init.d/sendmail-receiving stop /etc/rc.d/init.d/sendmail-delivery stop /etc/iscan/iscansmtps stop /etc/rc.d/init.d/sendmail-receiving start /etc/rc.d/init.d/sendmail-delivery start /etc/iscan/iscansmtps start RETVAL=$? ;; *) echo $"Usage: $0 {start|stop|restart}" exit 1 esac exit $RETVAL