When upgrading my server I ran into the following error:
error: Unable to migrate to dependency based boot sequencing.
error: Problems detected: insserv: warning: script ‘K20mydns’ missing LSB tags and overrides, insserv: warning: script ‘S13fixudev’ missing LSB tags and overrides, insserv: warning: script ‘bastille-firewall’ missing LSB tags and overrides, insserv: warning: script ‘fixudev’ missing LSB tags and overrides, insserv: warning: script ‘mydns’ missing LSB tags and overrides, , package amavisd-new removed but not purged, package clamav-daemon removed but not purged, package clamav-freshclam removed but not purged
See http://wiki.debian.org/LSBInitScripts/DependencyBasedBoot for
more information about dependency based boot sequencing. To
reattempt the migration process run ‘dpkg-reconfigure sysv-rc’.
After investigating, this is due to ‘insserv’ package generating warnings and preventing dpkg to reconfigure sysv-rc.
How to solve this?
In my case, we can see that some packages were removed but not purged. Purging them solves this part of the issue.
package amavisd-new removed but not purged, package clamav-daemon removed but not purged, package clamav-freshclam removed but not purged
#apt-get purge amavisd-new clamav-daemon clamav-freshclam
Now we need to handle the hard part:
insserv: warning: script ‘K20mydns’ missing LSB tags and overrides
Errors with “missing LSB tags and overrides” means that some scripts in /etc/init.d/ do not contain the appropriate comments for insserv to find out correct boot order.
Basically insserv is complementing sysv-rc to determine correct boot sequence for scripts, by passing old convention based on alphetical sorting of script names.
Unfortunately, as illustrated by such error messages, not all scripts have been updated to include LSB comments.
To get rid of these warnings and be able to reconfigure sysv-rc, which is a vital part of the system, I found out the following generic comment, found in this post, which I pasted into all the above scripts (mydns, fixudev, bastille-firewall in my case, all others being shortcuts to these three scripts):
### BEGIN INIT INFO # Provides: scriptname # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start daemon at boot time # Description: Enable service provided by daemon. ### END INIT INFO
Make sure to replace “scriptname” with the actual name of the script this comment is pasted into (mydns, fixudev and bastille-firewall in my case).
WARNING: I am not sure at all start boot-ordering information pasted into the scripts is the correct one! I only wanted to get rid of the warnings so that I could reconfigure sysv-rc.
Then I was able to run
without issues. During this reconfiguration, I was asked if I wanted to activate the new ordering mechanism, which I refused given that I am not sure pasted comment contained appropriate boot-ordering info.
All in all, my issue is solved as I was able to reconfigure sysv-rc and I am still using good-old boot ordering system.