OSDN Git Service

The restart processing of libvirt-bin is added.
authorniwa-hideyuki <niwa.hideyuki@jp.fujitsu.com>
Sat, 20 Sep 2014 11:23:15 +0000 (20:23 +0900)
committerniwa-hideyuki <niwa.hideyuki@jp.fujitsu.com>
Sat, 20 Sep 2014 11:23:15 +0000 (20:23 +0900)
lxcf/cmd/lxcf

index ee74af3..317b3b4 100755 (executable)
@@ -54,6 +54,18 @@ if [ -x /usr/bin/systemctl ] ; then
   fi
 fi
 
+# check upstart for lxcf and lxcf-sched service
+if [ -x /sbin/initctl ] ; then
+  initctl status lxcf-sched |& grep "start/running" >& /dev/null
+  if [ $? -ne 0 ] ; then
+    initctl start lxcf-init >& /dev/null
+    initctl start lxcf-sched >& /dev/null
+    initctl restart libvirt-bin >& /dev/null
+    /etc/init.d/libvirt-bin restart >& /dev/null
+  fi
+fi
+
+
 # check on repetition execution
 if [ -f /etc/lxcf/container_name ] ; then
   echo "The lxcf command is executed in the LXCF container."