[Pkg-systemd-maintainers] Bug#723855: "systemctl disable rsyslog" fails to remove syslog.service symlink

Alessandro Ghedini ghedo at debian.org
Wed Nov 27 11:15:37 GMT 2013

Control: tags -1 patch fixed-upstream

On ven, set 20, 2013 at 05:03:03 +0200, Michael Biebl wrote:
> Package: systemd
> Version: 204-4
> Severity: normal
> root at pluto:~# find /etc/systemd/ -name "*syslog*"
> /etc/systemd/system/multi-user.target.wants/rsyslog.service
> /etc/systemd/system/syslog.service
> root at pluto:~# systemctl disable rsyslog
> Synchronizing state for rsyslog with sysvinit using update-rc.d...
> Executing /usr/sbin/update-rc.d rsyslog disable
> insserv: warning: current start runlevel(s) (empty) of script `rsyslog' overrides LSB defaults (2 3 4 5).
> insserv: warning: current stop runlevel(s) (0 1 2 3 4 5 6) of script `rsyslog' overrides LSB defaults (0 1 6).
> root at pluto:~# find /etc/systemd/ -name "*syslog*"
> /etc/systemd/system/syslog.service
> Interestingly, using "systemctl disable rsyslog.service", the
> syslog.service is correctly removed on disable.
> Not quite sure if this is a bug in our SysV synchronization code or an
> upstream issue.

The problem seems to be that "rsyslog" is not recognized as a systemd unit
because it lacks the ".service" suffix, so systemctl only disables the sysv

I dug through the upstream repository and I found this commit [0] which, at
first glance, seems to be what's needed here (basically that "mangle_names()"
function is what adds the ".service" suffix if it's not present).

The upstream patch doesn't work as-is though, because there have been other
changes before that, so I modified it a little bit (see attachment) and
verified that it works with systemd v204. I don't know if it has any bad side
effect though, so more testing is advised.


[0] http://cgit.freedesktop.org/systemd/systemd/commit/?id=3a05c0f9

perl -E '$_=q;$/= @{[@_]};and s;\S+;<inidehG ordnasselA>;eg;say~~reverse'
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-systemctl-mangle-names-when-avoiding-dbus.patch
Type: text/x-diff
Size: 4100 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-systemd-maintainers/attachments/20131127/9ad2470d/attachment-0001.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-systemd-maintainers/attachments/20131127/9ad2470d/attachment-0001.sig>

More information about the Pkg-systemd-maintainers mailing list