Tran Nghi's Site  - Make notes and share experience

insserv: warning: script ‘sendmailanalyzer’ missing LSB tags and overrides

This post is also available in: English

Have you ever seen this annoying warning, and it stuck you to do something with apt, dpkg…

[email protected]:~# apt autoremove --purge
Setting up util-linux (2.27.1-6ubuntu3.6) ...
insserv: warning: script 'sendmailanalyzer' missing LSB tags and overrides
insserv: There is a loop between service monit and sendmailanalyzer if stopped
insserv:  loop involving service sendmailanalyzer at depth 2
insserv:  loop involving service monit at depth 1
insserv: Stopping sendmailanalyzer depends on monit and therefore on system facility `$all' which can not be true!
insserv: exiting now without changing boot order!
update-rc.d: error: insserv rejected the script header
dpkg: error processing package util-linux (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:

How to fix it?

On above output, it has mentioned the “insserv: warning: script ‘sendmailanalyzer’ missing LSB tags and overrides”

So, I simply insert below comments into /ect/init.d/sendmailanalyzer


# Provides:          sendmailanalyzer
# Required-Start:    $remote_fs
# Required-Stop:     $remote_fs
# Default-Start:     S
# Default-Stop:
# Short-Description: screen sessions cleaning
# Description: Cleans up the screen session directory and fixes its
#  permissions if needed.


More information:

If look at the /etc/init.d/sendmailanalyzer script, in the beginning of it there are two marks : ### BEGIN INIT INFO and ### END INIT INFO.

All the data inside those marks is the configuration for runtime dependences and you can look them up in the Debian Wiki.

Your script is missing these tags and configuration so insserv just uses some defaults.

This is just a warning and is not something to worry about, but you can fix it very easily and then you can be Linux Standards Base-compliant (That’s what LSB means).

The easiest way to fix the warning, is to copy the LSB tags from the skeleton script to the beginning of your mathkernel script and just change skeleton to mathkernel.