Thanks.....

where did you find this script??, so I know for future reference

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Chuck Mead
Sent: Tuesday, March 20, 2001 6:24 AM
To: REDHAT . .
Subject: Re: postfix


On Tue, 20 Mar 2001, mjs blurted out:

m>
m>I've installed postfix on rh 6.2, unfortunetly the tarball doesn't come
with
m>a startup script to add with ntsysv, it seems only the rpm does.

So why not use the rpm?

m>Does anyone know how to create a initialization script to put in
m>/etc/rc.d/rc3.d dir, like S80postfix or something along those lines, so i
m>can have postfix start on boot,..i don't want to have to use rc.local to
m>start postfix...

Make sure you adjust the paths accordingly:

#!/bin/sh
#
# postfix      This shell script takes care of starting and stopping
#               postfix.
#
# chkconfig: 2345 80 30
# description: Postfix is a Mail Transport Agent, which is the program \
#              that moves mail from one machine to another.
# processname: postfix
# config: /etc/postfix/
# pidfile: /var/run/postfix.pid

# Hacked by jam 25 Feb 99.  Mostly s/sendmail/postfix/g :-)

# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0

[ -f /usr/sbin/postfix ] || exit 0

RETVAL=0

# See how we were called.
case "$1" in
  start)
        # Start daemons.
        echo -n "Starting postfix: "
        /usr/sbin/postfix start
        RETVAL=$?
        [ $RETVAL -eq 0 ] && touch /var/lock/subsys/postfix
        ;;
  stop)
        # Stop daemons.
        echo -n "Shutting down postfix: "
        /usr/sbin/postfix stop
        RETVAL=$?
        [ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/postfix
        echo
        ;;
  restart)
        $0 stop
        $0 start
        ;;
  reload)
        /usr/sbin/postfix reload
        exit $?
        ;;
  abort)
        /usr/sbin/postfix abort
        exit $?
        ;;
  flush)
        /usr/sbin/postfix flush
        exit $?
        ;;
  check)
        /usr/sbin/postfix check
        exit $?
        ;;
  *)
        echo "Usage: postfix
{start|stop|restart|reload|abort|flush|check}"
        exit 1
esac

exit $RETVAL

--
Chuck Mead, csm -AT- moongroup.com, Owner, MoonGroup.com
(Note: html formatted email sent to me is filtered & deleted unread)
GnuPG Public Key Available: http://wwwkeys.us.pgp.net




---
Incoming mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.237 / Virus Database: 115 - Release Date: 3/7/2001

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.237 / Virus Database: 115 - Release Date: 3/7/2001



_______________________________________________
Redhat-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-list

Reply via email to