[Pkg-sysvinit-devel] Bug#538304: update-rc.d: Should reject packages trying to install start and stop symlinks in the same runlevel

Petter Reinholdtsen pere at hungry.com
Fri Jul 24 17:08:27 UTC 2009


Package: sysv-rc
Version: 2.80-1
Severity: important

I've discovered what I believe is misuse of the sysvinit boot system.
The nslu2-utils package calls update-rc.d like this (see #507545):

  update-rc.d zleds start 99 S 1 2 3 4 5 . stop 5 0 1 2 3 4 5 6 .

This inserts both start and stop symlinks in the runlevel directories.
It is, as far as I can see, not possible to recreate such setting
using dependency based boot sequencing.

As I understand the sysv init system, an underlying expectation is
that a given script will only provide a start or a stop symlink, never
both.  My opinion is that the nslu2-utils package only work by
accident, and that it should be changed to not depend on what I
consider is undefined behavior.

Luckily there is only one of the 850 packages with init.d scripts in
Debian misusing the boot system like this, and to make sure this idea
do not spread, I suggest we rewrite the update-rc.d script to reject
all calls asking for both start and stop symlinks in the same
runlevel.

Happy hacking,
-- 
Petter Reinholdtsen





More information about the Pkg-sysvinit-devel mailing list