Bug 1409649

Summary: initscripts contain old links (fedora-autorelabel.service, fedora-autorelabel-mark.service)
Product: [Fedora] Fedora Reporter: slartibart70
Component: initscriptsAssignee: systemd-maint
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 25CC: c.schwarzgruber.cs, danielsun3164, edgar.hoch, johannbg, jonathan, lnykryn, luigi.augello, mjg, msekleta, muadda, ssahani, s, systemd-maint, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-08-02 13:15:42 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 slartibart70 2017-01-02 18:20:00 UTC
Description of problem:

Install docker on fedora25
as root, try to do a 'systemctl start docker.service' by just typing:
systemctl start docker<tab>

Now, you will not see the following 'completion':
"systemctl start dockerUnit fedora-autorelabel-mark.service could not be found."

After having started docker, try it again by typing:
systemctl start docke<tab>

Now, you get the following 'completion':
systemctl start dockeUnit cloud-init.service could not be found.

This only seems to happen when 'starting' services, esp. docker (did not try others) and is a bit annoying...

Comment 1 Edgar Hoch 2017-01-09 17:22:31 UTC
This bug is assigned to the wrong component. It should be changed to initscripts.

initscripts-9.69-1.fc25 contains the following links which points to files that doesn't exist:

lrwxrwxrwx. 1 root root   34 31. Aug 09:41 /usr/lib/systemd/system/basic.target.wants/fedora-autorelabel-mark.service -> ../fedora-autorelabel-mark.service
lrwxrwxrwx. 1 root root   29 31. Aug 09:41 /usr/lib/systemd/system/basic.target.wants/fedora-autorelabel.service -> ../fedora-autorelabel.service

The autorelabel service files was moved to package policycoreutils, and renamed. 

The links in package initscripts should be changed to point to
../selinux-autorelabel-mark.service
../selinux-autorelabel.service
respective.

The name of the bug should changed to something like "initscripts contains old links (fedora-autorelabel.service, fedora-autorelabel-mark.service)".

Comment 2 slartibart70 2017-01-09 19:28:59 UTC
workaround by removing links and recreating them seems to solve the problem.
Renamed bug report and assigned it to initscripts

Comment 3 Zbigniew Jędrzejewski-Szmek 2017-01-10 06:25:42 UTC
Sounds like a bug in our completion scripts too...

Comment 4 Lukáš Nykrýn 2017-01-10 10:52:24 UTC
https://github.com/fedora-sysv/initscripts/pull/53

Comment 5 Zbigniew Jędrzejewski-Szmek 2017-01-11 22:40:01 UTC
https://github.com/systemd/systemd/pull/5069

Comment 6 luigi67 2017-02-12 17:05:45 UTC
Hi
I adopted  the workaround proposed by slartibart70, but as secondary effect I obtain that Fedora 25 reboots  every 3 minutes about.

I made these links

ln -s /usr/lib/systemd/system/selinux-autorelabel.service /usr/lib/systemd/system/basic.target.wants/fedora-autorelabel.service


ln -s /usr/lib/systemd/system/selinux-autorelabel-mark.service /usr/lib/systemd/system/basic.target.wants/fedora-autorelabel-mark.service

After these Fedora reboots  every 3 minutes about.
Cheers
Luigi

Comment 7 slartibart70 2017-02-13 13:00:40 UTC
@luigi67
sorry, but you're not alone.
I only wanted to indicate that renaming fixes the problem with the commandline-completion, but, as you already found out, it has some side-effects ... :-(
Still waiting for the 'holistic' fix for the problem