Hello.

Does anyone have any good scripts to put in /etc/rc.d to handle sound
(through OSS 3.9.2g) and the mailer 'postfix'? I'm thinking about scripts
in the same style as the other scripts that comes with SuSE Linux 6.0.

I have tried changing the 'sendmail' script to work with 'postfix', but it
doesnt work 100% like it should. For example, it gives status = "failed"
when I try to stop the service (with '/etc/rc.d/postfix stop').

I hope someone can help me here. At least, I hope someone can point me in
the right direction.
(Btw, Postfix itself was much, MUCH easier to set up than Sendmail 8.9.3..
;)

This is how my '/etc/rc.d/postfix' script looks like:

-START-
#! /bin/sh

. /etc/rc.config

# Determine the base and follow a runlevel link name.
base=${0##*/}
link=${base#*[SK][0-9][0-9]}

# Force execution if not called by a runlevel directory.
test $link = $base && SMTP=yes
test "$SMTP" = yes || exit 0

# The echo return value for success (defined in /etc/rc.config).
return=$rc_done
case "$1" in
        start)
                echo -n "Initializing SMTP port. (postfix)"
                startproc /usr/sbin/postfix start || return=$rc_failed
                echo -e "$return"
                ;;
        stop)
                echo -n "Shutting down SMTP port:"
                startproc /usr/sbin/postfix stop || return=$rc_failed
                echo -e "$return"
                ;;
        restart)
                $0 stop  &&  $0 start  ||  return=$rc_failed
                ;;
        reload)
                echo -n "Reload service postfix"
                startproc /usr/sbin/postfix reload
                echo -e "$return"
                ;;
        status)
                echo -n "Checking for service postfix: "
                checkproc /usr/local/bin/postfix && echo OK || echo No
process
                ;;
        *)
                echo "Usage: $0 {start|stop|status|restart|reload}"
                exit 1
esac

# Inform the caller not only verbosely and set an exit status.
test "$return" = "$rc_done" || exit 1
exit 0
-STOP-

-- 
Eivind Olsen - [EMAIL PROTECTED]

--
To get out of this list, please send email to [EMAIL PROTECTED] with
this text in its body: unsubscribe suse-linux-e
Check out the SuSE-FAQ at http://www.suse.com/Support/Doku/FAQ/ and the
archive at http://www.suse.com/Mailinglists/suse-linux-e/index.html

Reply via email to