[Libvir] LSBization of libvirt init script

Daniel Veillard veillard at redhat.com
Thu Jul 5 16:07:27 UTC 2007


  Small patch applied to qemud/libvirtd.init.in:
    - adds an LSB compliant header
    - add a couple of LSB defined functions
    - fixes the name in the chkconfig comments

  Hopefully it's correct :-)

Daniel

-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard at redhat.com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/
-------------- next part --------------
Index: qemud/libvirtd.init.in
===================================================================
RCS file: /data/cvs/libxen/qemud/libvirtd.init.in,v
retrieving revision 1.3
diff -u -r1.3 libvirtd.init.in
--- qemud/libvirtd.init.in	26 Jun 2007 23:48:47 -0000	1.3
+++ qemud/libvirtd.init.in	5 Jul 2007 16:03:06 -0000
@@ -1,14 +1,29 @@
 #!/bin/sh
 
-# libvirt_qemud:   QEMU and virtual network management daemon
+# the following is the LSB init header see
+# http://www.linux-foundation.org/spec//booksets/LSB-Core-generic/LSB-Core-generic.html#INITSCRCOMCONV
+#
+### BEGIN INIT INFO
+# Provides: libvirtd
+# Should-Start: xend
+# Default-Start: 3 4 5
+# Short-Description: daemon for libvirt virtualization API
+# Description: This is a daemon for managing QEMU guest instances
+#              and libvirt virtual networks
+#              See http://libvirt.org
+### END INIT INFO
+
+# the following is chkconfig init header
+#
+# libvirtd:   QEMU and virtual network management daemon
 #
 # chkconfig: 345 97 03
 # description:  This is a daemon for managing QEMU guest instances
 #               and libvirt virtual networks
 #               See http://libvirt.org
 #
-# processname: libvirt_qemud
-# pidfile: @localstatedir@/run/libvirt_qemud.pid
+# processname: libvirtd
+# pidfile: @localstatedir@/run/libvirtd.pid
 #
 
 # Sanity checks.
@@ -76,7 +91,10 @@
         status $PROCESS
         RETVAL=$?
         ;;
-    condrestart)
+    force-reload)
+        reload
+	;;
+    condrestart|try-restart)
         [ -f @localstatedir@/lock/subsys/$SERVICE ] && restart || :
         ;;
     *)


More information about the libvir-list mailing list