krb5/kpropd.init
Nalin Dahyabhai f072055a76 - some init script cleanups
- drop unquoted check and silent exit for "$NETWORKING" (#426852, #242500)
- krb524: don't barf on missing database if it looks like we're using
    kldap, same as for kadmin
- return non-zero status for missing files which cause startup to fail
2008-01-02 17:03:38 +00:00

69 lines
1.2 KiB
Bash
Executable File

#!/bin/bash
#
# kpropd.init Start and stop the Kerberos 5 propagation client.
#
# chkconfig: - 35 65
# description: Kerberos 5 is a trusted third-party authentication system. \
# This script starts and stops the service that allows this \
# KDC to receive updates from your master KDC.
# processname: kpropd
#
# Get config.
. /etc/sysconfig/network
# Source function library.
. /etc/init.d/functions
RETVAL=0
prog="Kerberos 5 Propagation Server"
kpropd=/usr/kerberos/sbin/kpropd
# Shell functions to cut down on useless shell instances.
start() {
[ -f /var/kerberos/krb5kdc/kpropd.acl ] || exit 6
[ -x $kpropd ] || exit 5
echo -n $"Starting $prog: "
daemon ${kpropd} -S
RETVAL=$?
echo
[ $RETVAL = 0 ] && touch /var/lock/subsys/kprop
}
stop() {
echo -n $"Stopping $prog: "
killproc ${kpropd}
RETVAL=$?
echo
[ $RETVAL = 0 ] && rm -f /var/lock/subsys/kprop
}
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
restart)
stop
start
;;
status)
status ${kpropd}
retval=$?
;;
condrestart)
if [ -f /var/lock/subsys/kprop ] ; then
stop
start
fi
;;
*)
echo $"Usage: $0 {start|stop|status|restart|condrestart}"
RETVAL=2
;;
esac
exit $RETVAL