3 # cancd netconsole daemon
5 # chkconfig: 2345 11 89
7 # description: This is the CA NetConsole Daemon, \
8 # a daemon to receive output from the Linux netconsole driver.
12 # Source function library
13 . /etc/rc.d/init.d/functions
16 . /etc/sysconfig/network
18 # Get service config - may override defaults
19 [ -f /etc/sysconfig/cancd ] && . /etc/sysconfig/cancd
21 # Check that networking is up.
22 if is_yes "${NETWORKING}"; then
23 if [ ! -f /var/lock/subsys/network ]; then
24 msg_network_down cancd
32 # Check if the service is already running?
33 if [ ! -f /var/lock/subsys/cancd ]; then
35 daemon --user "$USER" /usr/sbin/cancd -p ${CANCD_PORT} -l "${CRASH_DIR}" -o "${CRASH_FORMAT}"
37 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/cancd
39 msg_already_running cancd
44 if [ -f /var/lock/subsys/cancd ]; then
48 rm -f /var/lock/subsys/cancd
55 if [ -f /var/lock/subsys/cancd ]; then
65 # See how we were called.
88 msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"