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
34 if [ ! -f /var/lock/subsys/xend ]; then
36 daemon /usr/sbin/xend start
39 [ $RETVAL -eq 0 ] && touch /var/lock/subsys/xend
41 msg_already_running xend
45 if [ -f /var/lock/subsys/xend ]; then
47 daemon /usr/sbin/xend stop
48 rm -f /var/lock/subsys/xend >/dev/null 2>&1
50 msg_not_running "xend"
61 # do not advertise unreasonable commands that there is no reason
62 # to use with this device
63 echo $"Usage: $0 {start|stop|status|restart|force-reload}"