Bug 1149069

Summary: systemctl enable should return 1 and warn when attempting to enable masked service
Product: [Fedora] Fedora Reporter: Jan Synacek <jsynacek>
Component: systemdAssignee: Jan Synacek <jsynacek>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: dustymabe, johannbg, jsynacek, lnie, lnykryn, msekleta, pvn, rjones, s, swadeley, systemd-maint, vpavlin, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: systemd-208-26.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-11-02 07:26:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Synacek 2014-10-03 05:56:37 UTC
Description of problem:
$ sudo systemctl mask debug-shell
ln -s '/dev/null' '/etc/systemd/system/debug-shell.service'

$ sudo systemctl is-enabled debug-shell
masked

$ sudo systemctl enable debug-shell
ln -s '/usr/lib/systemd/system/debug-shell.service' '/etc/systemd/system/sysinit.target.wants/debug-shell.service'

$ sudo echo $?
0

$ ls -la /etc/systemd/system/sysinit.target.wants/debug-shell.service
lrwxrwxrwx. 1 root root 43 Oct  3 07:51 /etc/systemd/system/sysinit.target.wants/debug-shell.service -> /usr/lib/systemd/system/debug-shell.service

$ systemctl status debug-shell
debug-shell.service
   Loaded: masked (/dev/null)
   Active: inactive (dead)


Version-Release number of selected component (if applicable):
systemd-208-22.fc20.x86_64


Steps to Reproduce:
1. See description.


Actual results:
systemctl enable on a masked service returns 0 and all looks well.


Expected results:
systemctl enable on a masked service should return 1 and probably warn users that they're trying to enable a masked service.

Comment 3 Fedora Update System 2014-10-26 23:10:28 UTC
systemd-208-25.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/systemd-208-25.fc20

Comment 4 lnie 2014-10-30 09:23:21 UTC
systemd-208-25.fc20 works

Comment 5 Fedora Update System 2014-10-30 12:00:01 UTC
systemd-208-26.fc20,kmod-15-2.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/systemd-208-26.fc20,kmod-15-2.fc20

Comment 6 Zbigniew Jędrzejewski-Szmek 2014-10-30 13:41:44 UTC
(In reply to lnie from comment #4)
> systemd-208-25.fc20 works
Thanks. Please add karma.

Comment 7 Fedora Update System 2014-11-01 01:40:48 UTC
Package systemd-208-26.fc20, kmod-15-2.fc20:
* should fix your issue,
* was pushed to the Fedora 20 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing systemd-208-26.fc20 kmod-15-2.fc20'
as soon as you are able to, then reboot.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-14032/systemd-208-26.fc20,kmod-15-2.fc20
then log in and leave karma (feedback).

Comment 8 Fedora Update System 2014-11-02 07:26:50 UTC
systemd-208-25.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 9 Fedora Update System 2014-11-05 03:56:36 UTC
systemd-208-26.fc20, kmod-15-2.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.