[Mimedefang] OT: Sendmail Startup Script Question
Jeff Grossman
jeff at stikman.com
Wed Dec 18 21:33:00 EST 2002
I am running Redhat 7.3. I have my sendmail startup script to start two
instances of Sendmail. One for normal mail delivery and the other for
queue control. But, when I start up my machine, or restart, the
machine, the queue control never starts up. But, I issue a restart to
the Sendmail startup script, it starts both instances of Sendmail just
fine. I am including my startup script below. Would anybody be able to
point me in a direction of modifying the script so it starts both
instances upon a restart or boot up?
Thanks,
Jeff
#!/bin/sh
#
# Red Hat Linux Boot Script
#
# $Id: redhat.init,v 1.5 2000/01/31 09:16:07 peterh Exp $ (Sendmail)
$Date: 200
0/01/31 09:16:07 $
# Copyright (c) 1998 Sendmail, Inc. and its suppliers. All rights
reserved.
#
# Red Hat provides daemon startup/stop functions
. /etc/rc.d/init.d/functions
# Exit codes
EX_OK=0
EX_USAGE=64
case "$1" in
start)
if [ -e /usr/sbin/sendmail -a -e /etc/mail/sendmail.cf ]
then
echo -n "Starting sendmail: "
daemon /usr/sbin/sendmail -L sm-mta -bd -q30m
daemon /usr/sbin/sendmail -Ac -qp1m
# Red Hat method for preventing multiple
instances
touch /var/lock/subsys/sendmail
echo
fi
;;
stop)
if [ -f /var/lock/subsys/sendmail ]
then
echo -n "Shutting down sendmail: "
killproc sendmail
killproc sendmail
rm -f /var/lock/subsys/sendmail
echo
fi
;;
restart)
$0 stop
$0 start
;;
*)
echo "Usage: $0 {start|stop|restart}"
exit $EX_USAGE
esac
exit $EX_OK
--
Jeff Grossman (jeff at stikman.com)
More information about the MIMEDefang
mailing list