6 # nm Starts and stops Node Manager daemon
9 # description: Starts and stops Node Manager daemon
12 # Source function library.
13 . /etc/init.d/functions
15 [ -f /etc/sysconfig/NodeManager ] && . /etc/sysconfig/NodeManager
17 options=${OPTIONS-"-d -s"}
18 restartoptions=${RESTARTOPTIONS-"-d"}
20 verboseoptions=${DEBUGOPTIONS-"-v -d"}
21 # debug mode is interactive, and has faster period
22 debugoptions=${DEBUGOPTIONS-"-v -p 30 -r 15"}
24 nm=${NM-"python /usr/share/NodeManager/nm.py"}
26 pidfile=${PIDFILE-/var/run/nm.pid}
27 lockfile=${LOCKFILE-/var/lock/subsys/nm}
32 echo -n $"Starting $prog: "
33 daemon --check=nm $nm "$@"
36 [ $RETVAL -eq 0 ] && touch ${lockfile}
41 echo -n $"Stopping $prog: "
45 [ $RETVAL -eq 0 ] && rm -f ${lockfile} ${pidfile}
62 start $restartoptions "$@"
66 [ -f ${pidfile} ] && { stop; start $restartoptions "$@"; }
71 $nm $verboseoptions "$@"
76 echo "Restarting with $debugoptions $@ .."
77 $nm $debugoptions "$@"
80 echo $"Usage: $0 {start|stop|status|restart|condrestart|restartdebug [-d]}"