#!/bin/bash # # chkconfig: 345 25 65 # description: System Tools Backends ### BEGIN INIT INFO # Provides: system-tools-backends # Required-Start: messagebus # Required-Stop: messagebus # Default-Start: 3 4 5 # Short-Description: System Tools Backends # Description: This is a daemon for system administration # It is controlled by the programs in gnome-system-tools ### END INIT INFO # Source function library. . /etc/init.d/functions DAEMON=/usr/bin/system-tools-backends PIDFILE=/var/run/system-tools-backends.pid NAME=system-tools-backends DESC="System Tools Backends" start() { echo -n $"Starting $DESC:" daemon --pidfile $PIDFILE $DAEMON RETVAL=$? [ $RETVAL = 0 ] && touch /var/lock/subsys/$NAME && success || failure echo return $RETVAL } stop() { echo -n $"Stopping $DESC: " killproc $NAME RETVAL=$? if [ $RETVAL -eq 0 ] ; then rm -f /var/lock/subsys/$NAME fi echo return $RETVAL } restart() { stop start } RETVAL=0 # See how we were called. case "$1" in start) start ;; stop) stop ;; status) status $NAME ;; restart) restart ;; *) echo $"Usage: $0 {start|stop|status|restart}" exit 1 esac exit $?