[systemd-devel] [PATCH] sysv-generator: Skip init scripts for existing native services

Martin Pitt martin.pitt at ubuntu.com
Wed Feb 4 06:06:23 PST 2015


Hey,

Lennart Poettering [2015-02-04 13:42 +0100]:
> Well, but their enablement status so far is not ignored. i.e. if you
> drop in a unit file, as well as a sysv script, and the latter is
> enabled, but the former not, then systemd currently reads that so that
> the sysv one is overriden by the native one, and the native one is
> considered enabled.
> 
> With this change you alter that behaviour. Is that really desired?

Since it's rather confusing what happens in this case, we made
systemctl sync the status to update-rc.d (the chkconfig equivalent in
Debian) on enable/disable:

  http://anonscm.debian.org/cgit/pkg-systemd/systemd.git/tree/debian/patches/systemctl-don-t-skip-native-units-when-enabling-disa.patch

That of course doesn't change the behaviour with manual rc?.d/ symlinks.

But if you have a native unit, I think it's rather unexpected if you
disable it with systemctl, enable it in sysv, but still get it
started. It seems to me that systemctl disable should win here --
after all, that's closer to the running systemd than the rc.d links.
So in that regard it would be an intended behaviour change indeed.
But either way this is a corner case for sure. I just wouldn't like to
carry this patch forever as it's relatively unimportant.

Maybe Jon can chime in about his intentions with this?

Thanks,

Martin

-- 
Martin Pitt                        | http://www.piware.de
Ubuntu Developer (www.ubuntu.com)  | Debian Developer  (www.debian.org)


More information about the systemd-devel mailing list