3 # nm Starts and stops Node Manager daemon
6 # description: Starts and stops Node Manager daemon
9 # Source function library.
10 . /etc/init.d/functions
12 [ -f /etc/sysconfig/nodemanager ] && . /etc/sysconfig/nodemanager
14 # Wait for libvirt to finish initializing
17 options=${OPTIONS-"-d"}
19 verboseoptions=${DEBUGOPTIONS-"-v -d"}
20 # debug mode is interactive, and has faster period
21 # run in deamon mode with service nm restardebug -d
22 debugoptions=${DEBUGOPTIONS-"-v -p 30 -r 15"}
24 nodemanager=${NODEMANAGER-"python /usr/share/NodeManager/nodemanager.py"}
26 pidfile=${PIDFILE-/var/run/nodemanager.pid}
31 action $"Starting $prog: " daemon --pidfile=$pidfile --check=nodemanager $nodemanager "$@"
35 action $"Stopping $prog: " killproc -p $pidfile nodemanager
46 status -p $pidfile nodemanager
56 [ -f ${pidfile} ] && { stop; start $options "$@"; }
61 $nodemanager $verboseoptions "$@"
66 echo "Restarting with $debugoptions $@ .."
67 $nodemanager $debugoptions "$@"
70 echo $"Usage: $0 {start|stop|status|restart|condrestart|restartdebug [-d]}"