4f57eb9581
1.0.11-0.fdr.6 - -server: Requires(preun,postun): /sbin/service - add a few more %doc files to base pkg. - initscript: add (real) 'reload' action. - initscript: use $prog instead of hardcoded slpd. 1.0.11-0.fdr.5 - -server: fix %postun on uninstall 1.0.11-0.fdr.4 - *really* do %config(noreplace) slp.conf 1.0.11-0.fdr.3 - capitalize Summary's. - %config(noreplace) slp.conf 1.0.11-0.fdr.2 - docs: remove CVS files, include rfc, move ProgrammersGuide to -devel. - improve sub-pkg descriptions. - improve server %preun,%postun scripts: condrestart on upgrade, suppress output of server shutdown,restarts. 1.0.11-0.fdr.1 - specfile cleanups for fedora packaging. 1.0.11-0.fdr.0 - 1.0.11 release. - fedorize things 1.0.10-1.0 - sanitize specfile - -devel,-server subpkgs.
87 lines
1.2 KiB
Bash
Executable File
87 lines
1.2 KiB
Bash
Executable File
#!/bin/bash
|
|
#
|
|
# $Id: openslp.init,v 1.2 2003/05/30 12:59:30 rexdieter Exp $
|
|
#
|
|
# chkconfig: 345 40 60
|
|
# description: OpenSLP daemon for the Service Location Protocol
|
|
# processname: slpd
|
|
|
|
# Source function library.
|
|
. /etc/rc.d/init.d/functions
|
|
|
|
# Source networking configuration.
|
|
. /etc/sysconfig/network
|
|
|
|
if [ -f /etc/sysconfig/slpd ]; then
|
|
. /etc/sysconfig/slpd
|
|
fi
|
|
|
|
# Check that networking is up.
|
|
[ ${NETWORKING} = "no" ] && exit 0
|
|
|
|
RETVAL=0
|
|
|
|
prog="slpd"
|
|
|
|
start () {
|
|
echo -n $"Starting $prog: "
|
|
daemon $prog
|
|
RETVAL=$?
|
|
echo
|
|
[ $RETVAL -eq 0 ] && touch /var/lock/subsys/$prog
|
|
return $RETVAL
|
|
}
|
|
|
|
stop () {
|
|
echo -n $"Stopping $prog: "
|
|
killproc $prog
|
|
RETVAL=$?
|
|
echo
|
|
[ $RETVAL -eq 0 ] && rm -f /var/lock/subsys/$prog
|
|
return $RETVAL
|
|
}
|
|
|
|
reload(){
|
|
echo -n $"Reloading configuration: "
|
|
killproc $prog -HUP
|
|
RETVAL=$?
|
|
echo
|
|
return $RETVAL
|
|
}
|
|
|
|
restart () {
|
|
stop
|
|
start
|
|
}
|
|
|
|
condrestart(){
|
|
[ -e /var/lock/subsys/$prog ] && restart
|
|
}
|
|
|
|
case "$1" in
|
|
start)
|
|
start
|
|
;;
|
|
stop)
|
|
stop
|
|
;;
|
|
reload)
|
|
reload
|
|
;;
|
|
restart)
|
|
restart
|
|
;;
|
|
condrestart)
|
|
condrestart
|
|
;;
|
|
status)
|
|
status $prog
|
|
RETVAL=$?
|
|
;;
|
|
*)
|
|
echo "Usage: $0 {start|stop|restart|reload|condrestart|status}"
|
|
exit 1
|
|
esac
|
|
|
|
exit $RETVAL
|