13 # Source function library
14 . /etc/rc.d/init.d/functions
17 . /etc/sysconfig/network
20 [ -f /etc/sysconfig/distccd ] && . /etc/sysconfig/distccd
22 # Check that networking is up.
23 if is_yes "${NETWORKING}"; then
24 if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
25 msg_network_down distccd
35 # See how we were called.
38 # Check if the service is already running?
39 if [ ! -f /var/lock/subsys/distccd ]; then
41 daemon /usr/bin/distccd --user nobody --allow $HOSTS_ALLOW
43 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/distccd
45 msg_already_running distccd
49 if [ -f /var/lock/subsys/distccd ]; then
52 rm -f /var/run/distccd.pid /var/lock/subsys/distccd >/dev/null 2>&1
54 msg_not_running distccd
67 if [ -f /var/lock/subsys/distccd ]; then
72 msg_not_running distccd >&2
77 msg_usage "$0 {start|stop|restart|reload|force-reload|status}"
83 # This must be last line !
84 # vi:syntax=sh:tw=78:ts=8:sw=4