[Pkg-sysvinit-devel] Bug#747854: sysvrc: invoke-rc.d fails on masked systemd units
Martin Pitt
martin.pitt at ubuntu.com
Mon May 12 09:27:49 UTC 2014
Package: sysv-rc
Version: 2.88dsf-55
Tags: patch
User: ubuntu-devel at lists.ubuntu.com
Usertags: origin-ubuntu ubuntu-patch utopic
Hello,
if you have a masked systemd unit, i. e. one that just points to
/dev/null, invoke-rc.d fails with error code 100:
| $ sudo sh -x /usr/sbin/invoke-rc.d cgroup-lite start
| [...]
| + test -d /run/systemd/system
| + is_systemd=1
| [...]
| + systemctl -p LoadState show cgroup-lite.service
| + _state=LoadState=masked
| + [ LoadState=masked != LoadState=masked ]
| + [ = 1 ]
| + [ -z ]
| + test ! -f /etc/init.d/cgroup-lite
| + querypolicy
| + policyaction=start
| + test x = x101
| + test x/usr/sbin/policy-rc.d != x
| + test -x /usr/sbin/policy-rc.d
| + test x = x
| + RC=104
| + return
| + exit 100
As these units are meant to be no-ops, I think invoke-rc.d should
succeed instead of failing a package install/upgrade due to that.
Tested patch against current git attached (on top of the one in bug
#747851, but this only collides on debian/changelog).
Thanks for considering,
Martin
--
Martin Pitt | http://www.piware.de
Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-invoke-rc.d-Don-t-fail-if-a-systemd-unit-is-masked.patch
Type: text/x-diff
Size: 1514 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-sysvinit-devel/attachments/20140512/96820064/attachment.patch>
More information about the Pkg-sysvinit-devel
mailing list