4 # doldacond: Direct Connect client as daemon
8 # description: doldacond
10 # config: /etc/sysconfig/doldacond
12 # Source function library
13 . /etc/rc.d/init.d/functions
16 if [ -f /etc/sysconfig/doldacond ]; then
17 . /etc/sysconfig/doldacond
20 # Check that networking is up.
21 if is_yes "${NETWORKING}"; then
22 if [ ! -f /var/lock/subsys/network -a "$1" != stop -a "$1" != status ]; then
23 msg_network_down doldacon
30 # See how we were called.
33 # Check if service is already running?
34 if [ ! -f /var/lock/subsys/doldacond ]; then
35 msg_starting doldacond
36 daemon doldacond -p /var/run/doldacond.pid ${ADD_OPT}
38 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/doldacond
40 msg_already_running doldacond
44 if [ -f /var/lock/subsys/doldacond ]; then
45 msg_stopping doldacond
46 killproc doldacond --pidfile /var/run/doldacond.pid
47 rm -f /var/lock/subsys/doldacond
49 msg_not_running doldacond
57 if [ -f /var/lock/subsys/doldacond ]; then
58 msg_reloading doldacond
59 killproc doldacond -HUP
62 msg_not_running doldacond >&2
71 msg_usage "$0 {start|stop|restart|force-reload|status}"