Package: controlaula ltsp-controlaula Version: 1.3-1 Severity: important Tags: patch User: initscripts-ng-de...@lists.alioth.debian.org Usertags: incorrect-runlevels incorrect-dependency
With dependency based boot sequencing, I discovered what I believe is a bug in the init.d script. The init.d scripts have a hard dependency on dbus, which is supposed to be optional and is missing on kfreebsd. The scripts used to start after the syslog collector, but do not depend on $syslog. The avahi-daemon provide do not exist (the script provide avahi instead). Prehaps it should be dropped as a optional dependency? Also, the ltsp-sirvecole script do not have the runlevel 1 listed. This will make it fail to restart when switching from runlevel 1 back to 2-5, and probably should be fixed. I notice the update-rc.d calls look like this: update-rc.d sirvecole start 98 2 3 5 . stop 20 0 1 6 . update-rc.d ltsp-sirvecole start 24 2 3 5 . If ltsp-sirvecole really should not stop at all, no runlevel should be listed in default-stop at all, but I believe that is the wrong approach. I would suggest to change the update-rc.d call like this instead: update-rc.d ltsp-sirvecole start 24 2 3 5 . stop 1 . If the script do not need special handling to stop, the stop symlinks for runlevels 0 and 6 can be dropped for the sirvecole script. Should the ltsp-sirvecole script depend on some LTSP specific scripts? Why did the sirvecole start so late? Should it depend on more init.d scripts to ensure it is started behind something else? This untested patch should fix the issues I know about. The code in the postinst is needed to update the runlevel settings for existing installations. diff -uNr controlaula-1.3.1/debian/controlaula.postinst controlaula-1.3.1-pere/debian/controlaula.postinst --- controlaula-1.3.1/debian/controlaula.postinst 1970-01-01 01:00:00.000000000 +0100 +++ controlaula-1.3.1-pere/debian/controlaula.postinst 2009-09-12 09:01:16.000000000 +0200 @@ -0,0 +1,11 @@ +#!/bin/sh + +case "$1" in + configure) + if dpkg --compare-versions "$2" le "1.3.1-1" ; then + update-rc.d -f sirvecole remove >/dev/null 2>&1 || : + fi + ;; +esac + +#DEBHELPER# diff -uNr controlaula-1.3.1/debian/controlaula.sirvecole controlaula-1.3.1-pere/debian/controlaula.sirvecole --- controlaula-1.3.1/debian/controlaula.sirvecole 2009-09-12 08:21:23.000000000 +0200 +++ controlaula-1.3.1-pere/debian/controlaula.sirvecole 2009-09-12 08:40:31.000000000 +0200 @@ -1,11 +1,12 @@ #! /bin/sh ### BEGIN INIT INFO # Provides: sirvecole -# Should-Start: avahi-daemon -# Required-Start: $remote_fs $network dbus avahi -# Required-Stop: $remote_fs $network dbus avahi +# Required-Start: $remote_fs $network $syslog avahi +# Required-Stop: $remote_fs $network $syslog avahi +# Should-Start: avahi-daemon dbus +# Should-Stop: avahi-daemon dbus # Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 +# Default-Stop: 1 # Short-Description: Controlaula root daemon # Description: Debian init script for Controlaula root monitoring daemon ### END INIT INFO diff -uNr controlaula-1.3.1/debian/ltsp-controlaula.ltsp-sirvecole controlaula-1.3.1-pere/debian/ltsp-controlaula.ltsp-sirvecole --- controlaula-1.3.1/debian/ltsp-controlaula.ltsp-sirvecole 2009-09-12 08:21:23.000000000 +0200 +++ controlaula-1.3.1-pere/debian/ltsp-controlaula.ltsp-sirvecole 2009-09-12 08:40:38.000000000 +0200 @@ -1,11 +1,12 @@ #!/bin/sh ### BEGIN INIT INFO # Provides: ltsp-sirvecole -# Should-Start: avahi-daemon -# Required-Start: $local_fs $remote_fs dbus avahi -# Required-Stop: $local_fs $remote_fs dbus avahi +# Required-Start: $remote_fs $network $syslog avahi +# Required-Stop: $remote_fs $network $syslog avahi +# Should-Start: avahi-daemon dbus +# Should-Stop: avahi-daemon dbus # Default-Start: 2 3 4 5 -# Default-Stop: 0 6 +# Default-Stop: 1 # Short-Description: Controlaula root daemon in a ltsp environment # Description: Debian init script for Controlaula root monitoring daemon when using ltsp ### END INIT INFO diff -uNr controlaula-1.3.1/debian/ltsp-controlaula.postinst controlaula-1.3.1-pere/debian/ltsp-controlaula.postinst --- controlaula-1.3.1/debian/ltsp-controlaula.postinst 1970-01-01 01:00:00.000000000 +0100 +++ controlaula-1.3.1-pere/debian/ltsp-controlaula.postinst 2009-09-12 09:02:00.000000000 +0200 @@ -0,0 +1,11 @@ +#!/bin/sh + +case "$1" in + configure) + if dpkg --compare-versions "$2" lt "1.3.1-1" ; then + update-rc.d -f ltsp-sirvecole remove >/dev/null 2>&1 || : + fi + ;; +esac + +#DEBHELPER# diff -uNr controlaula-1.3.1/debian/rules controlaula-1.3.1-pere/debian/rules --- controlaula-1.3.1/debian/rules 2009-09-12 09:04:03.000000000 +0200 +++ controlaula-1.3.1-pere/debian/rules 2009-09-12 09:05:15.000000000 +0200 @@ -59,7 +59,7 @@ dh_installchangelogs -i dh_installdocs -i dh_install -i - dh_installinit -i --init-script ltsp-sirvecole -r --no-start -u"start 24 2 3 5 ." + dh_installinit -i --init-script ltsp-sirvecole -r --no-start -u"start 24 2 3 5 . stop 20 1 ." dh_installman debian/ltsp-sirvecole.gambas.8 -pltsp-controlaula dh_link -i dh_compress -i @@ -75,7 +75,7 @@ dh_installdocs -a dh_installchangelogs -a dh_install -a - dh_installinit -a --init-script sirvecole -r --no-start -u"start 98 2 3 5 . stop 20 0 1 6 ." + dh_installinit -a --init-script sirvecole -r --no-start -u"start 98 2 3 5 . stop 20 1 ." dh_installman debian/sirvecole.gambas.8 debian/pwd_controlaula.8 -pcontrolaula dh_installman debian/controlaula.gambas.1 debian/monitor.gambas.1 debian/monitorProfe.gambas.1 -pcontrolaula dh_strip -a diff -uNr controlaula-1.3.1/gambas-sources/debian/controlaula.sirvecole controlaula-1.3.1-pere/gambas-sources/debian/controlaula.sirvecole --- controlaula-1.3.1/gambas-sources/debian/controlaula.sirvecole 2008-11-24 12:02:06.000000000 +0100 +++ controlaula-1.3.1-pere/gambas-sources/debian/controlaula.sirvecole 2009-09-12 08:40:44.000000000 +0200 @@ -1,12 +1,12 @@ #!/bin/sh ### BEGIN INIT INFO # Provides: sirvecole -# Should-Start: avahi-daemon -# Should-Stop: avahi-daemon -# Required-Start: $remote_fs $network dbus avahi -# Required-Stop: $remote_fs $network dbus avahi +# Required-Start: $remote_fs $network $syslog avahi +# Required-Stop: $remote_fs $network $syslog avahi +# Should-Start: avahi-daemon dbus +# Should-Stop: avahi-daemon dbus # Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 +# Default-Stop: 1 # Short-Description: Controlaula root daemon # Description: Debian init script for Controlaula root monitoring daemon ### END INIT INFO diff -uNr controlaula-1.3.1/gambas-sources/debian/ltsp-controlaula.ltsp-sirvecole controlaula-1.3.1-pere/gambas-sources/debian/ltsp-controlaula.ltsp-sirvecole --- controlaula-1.3.1/gambas-sources/debian/ltsp-controlaula.ltsp-sirvecole 2008-11-24 12:02:06.000000000 +0100 +++ controlaula-1.3.1-pere/gambas-sources/debian/ltsp-controlaula.ltsp-sirvecole 2009-09-12 08:40:55.000000000 +0200 @@ -1,11 +1,12 @@ #!/bin/sh ### BEGIN INIT INFO # Provides: ltsp-sirvecole -# Should-Start: avahi-daemon -# Required-Start: $local_fs $remote_fs dbus avahi -# Required-Stop: $local_fs $remote_fs dbus avahi +# Required-Start: $remote_fs $network $syslog avahi +# Required-Stop: $remote_fs $network $syslog avahi +# Should-Start: avahi-daemon dbus +# Should-Stop: avahi-daemon dbus # Default-Start: 2 3 4 5 -# Default-Stop: 0 6 +# Default-Stop: 1 # Short-Description: Controlaula root daemon in a ltsp environment # Description: Debian init script for Controlaula root monitoring daemon when using ltsp ### END INIT INFO Happy hacking, -- Petter Reinholdtsen -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org