Fix omitpids to work with readonly images.
[live-boot-grml.git] / debian / live-boot.init
index 298295d..12d0f94 100644 (file)
@@ -2,12 +2,12 @@
 
 ### BEGIN INIT INFO
 # Provides:            live-boot
-# Required-Start:      $syslog
+# Required-Start:      $syslog bootmisc
 # Required-Stop:
 # Should-Start:                $local_fs
 # Should-Stop:         halt reboot
 # X-Stop-After:                umountroot
-# Default-Start:
+# Default-Start:       S
 # Default-Stop:                0 6
 # Short-Description:   live-boot init script
 # Description:         Resyncs snapshots, evantually caches files in order to
@@ -25,9 +25,6 @@ DO_SNAPSHOT=/sbin/live-snapshot
 # Exit if system was not booted by live-boot
 grep -qs boot=live /proc/cmdline || exit 0
 
-# Exit if the system was booted from an ISO image rather than a physical CD
-grep -qs find_iso= /proc/cmdline && exit 0
-
 # Read configuration variable file if it is present
 [ -r /etc/live.conf ] && . /etc/live.conf
 
@@ -153,6 +150,9 @@ do_stop ()
 
        if [ -z ${QUICKREBOOT} ]
        then
+
+               # Exit if the system was booted from an ISO image rather than a physical CD
+               grep -qs find_iso= /proc/cmdline && return 0
                # TODO: i18n
                BOOT_DEVICE="$(get_boot_device)"
 
@@ -201,8 +201,15 @@ case "${1}" in
        restart|reload|force-reload|status)
                [ "${VERBOSE}" != no ] && log_end_msg 0
                ;;
+       start)
+               log_begin_msg "${NAME} is configuring sendsigs..."
+               if [ -f /live/root.pid ] ; then
+                       cat /live/root.pid >> /var/run/sendsigs.omit
+               fi
+               log_end_msg 0
+               ;;
 
-       start|stop)
+       stop)
                log_begin_msg "${NAME} is resyncing snapshots and caching reboot files..."
                do_stop