Hi Łukasz, stl...@poczta.fm writes: > I've got a problem with avah-daemon.service. I cannot enable it with > "systemctl enable" because > > 1. its sysv version created from /etc/init.d/avahi-daemon requires dbus > 2. dbus is provided by a native systemd service file and > 3. when insserv tries to enable avahi-daemon it complains that dbus is > not enabled dbus is not only provided as a native service file, it still ships /etc/init.d/dbus. Have you tried enabling that using update-rc.d dbus defaults?
> --8<---------------cut here---------------start------------->8--- > # systemctl enable avahi-daemon.service > Synchronizing state for avahi-daemon.service with sysvinit using > update-rc.d... > Executing /usr/sbin/update-rc.d avahi-daemon defaults > update-rc.d: using dependency based boot sequencing > insserv: Service dbus has to be enabled to start service avahi > insserv: exiting now! > update-rc.d: error: insserv rejected the script header > --8<---------------cut here---------------end--------------->8--- > > I assume (I haven't debugged it with gdb) returns r < 0 at systemctl.c:4256 > which prevents systemct from doing anything more with native units. > > And even if there was no insserv error enable_sysv_units() should not > operate on sysv services if native one are available because the native > ones may be designed (like avahi-daemon does) to be socket activated > and should not be overriden by sysv derived units. […] No. enable_sysv_units() should totally operate on sysv services if native service files are available. Otherwise, the enabled/disabled state diverges between systemd and sysvinit. So, the feature works as intended. I do agree that the error handling could be a bit better, i.e. one could handle native service files first and sysv init scripts later, so that the systemd action is still done even if the state syncing fails. Patches welcome :). -- Best regards, Michael -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org