Bug#975591: update-rc.d disable

Jesse Smith jessefrgsmith at yahoo.ca
Mon Dec 21 17:19:59 GMT 2020


I have be mostly following this discussion on disabling init scripts and
this part, for me, seems to be the key:

"I found that: update-rc.d remove works but does not persist across
package upgrades. update-rc.d disables the service, not the init script,
by calling the init script with 'stop' in every runlevel, which is not
the same, as it would also stop manually-started instances."

It seems to me there is a bit of a conflict here between what the admin
wants to set up (using update-rc.d or insserv) versus what the package
manager is doing. So we need some way to make a lasting change (removing
init links from each runlevel) that is not overwritten by the package
manager the next time the service is updated.

As I understand it Thorsten is looking for a way to have a service
installed, that can be run or stopped manually. But the service is never
started/stopped automatically when switching runlevels. Is that correct?

If it is, I wonder if insserv's "overrides" feature would work here? An
override is a file which sets which runlevels will be used to start/stop
a service that is kept in a separate location so as to not be
overwritten by the package manager. If the override file was created and
set so it had no start/stop runlevels then I think the service would
only start/stop when manually controlled (ie with
/etc/init.d/service-name stop).

There is a short write-up on insserv overrides in its manual page. Would
that suit the purposes here? If so, then I think we don't need to extend
insserv, jut add a feature to update-rc.d which would create a minimal
overrides file for given service. Thoughts?

Jesse



More information about the Debian-init-diversity mailing list