3 # xend Script to start and stop the Xen control daemon.
5 # Author: Keir Fraser <keir.fraser@cl.cam.ac.uk>
7 # chkconfig: 2345 98 01
8 # description: Starts and stops the Xen control daemon.
10 # Source function library
11 . /etc/rc.d/init.d/functions
13 if ! [ -e /proc/xen/privcmd ]; then
23 while [ $? -ne 0 -a $i -lt $rets ]; do
26 /usr/sbin/xend status > /dev/null 2>&1
31 if [ ! -f /var/lock/subsys/xend ]; then
33 daemon /usr/sbin/xend start
36 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/xend
38 msg_already_running Xend
43 if [ -f /var/lock/subsys/xend ]; then
45 daemon /usr/sbin/xend stop
46 rm -f /var/lock/subsys/xend >/dev/null 2>&1
53 if [ -f /var/lock/subsys/xend ]; then
84 msg_usage "$0 {start|stop|restart|try-restart|force-reload|status}"