Bug 1251490

Summary: Initial Setup units should not be enabled in the the default service preset
Product: [Fedora] Fedora Reporter: Martin Kolman <mkolman>
Component: fedora-releaseAssignee: Dennis Gilmore <dennis>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: rawhideCC: dennis, jdisnard, kevin, mkolman, pbrobinson, pwhalen, sgallagh, vpodzime, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-02-12 18:23:07 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:
Attachments:
Description Flags
patch removing the Initial Setup units from the preset file none

Description Martin Kolman 2015-08-07 13:37:20 UTC
Created attachment 1060370 [details]
patch removing the Initial Setup units from the preset file

Description of problem:
The Initial Setup units (TUI and GUI) are marked as enabled in the service preset file (/usr/lib/systemd/system-preset/90-default.preset), so they are always enabled once the package containing the unit is installed.

This is an issue when the Initial Setup package is not installed by Anaconda during the initial OS installation but gets installed later, for example as part of a package group. This can result in the IS UI interrupting the boot process and waiting for user input. 

Therefore the Initial Setup unit files (initial-setup-graphical.service
and initial-setup-text.service) should be removed from the preset file to prevent this from happening.

NOTE: Removal of the preset won't break cases where the package is installed during the OS installation, because Anaconda makes sure to enable the appropriate IS services.

How reproducible:
always

Steps to Reproduce:
1. install the "minimal install" environment and don't create a user
2. reboot and check that Initial Setup is not running
3. install the KDE Desktop package group (or any other group that pulls in Initial Setup)
4. reboot

Actual results:
The boot process is interrupted by Initial Setup waiting for user input.

Expected results:
Boot is not interrupted by Initial Setup and it's services are not enabled.

Additional info:
A patch removing the Initial Setup units from the preset file is attached.

Comment 1 Martin Kolman 2015-08-07 13:45:28 UTC
CCing Paul Whalen as Initial Setup is release blocking for the ARM images, but I don't think the preset is needed on ARM either.

Comment 2 Peter Robinson 2015-08-07 13:47:18 UTC
How does it run on the first run if not enabled?

Comment 3 Stephen Gallagher 2015-08-07 16:43:03 UTC
(In reply to Peter Robinson from comment #2)
> How does it run on the first run if not enabled?

From the original description: "Anaconda makes sure to enable the appropriate IS services.". I assume (but have not checked), that this implies that Anaconda essentially calls 'systemctl enable initial-setup.service' before rebooting into the new environment.

I'd like to have someone confirm that interpretation, however.

As for the ARM images, which don't run Anaconda, I think the preset might still be needed (or else the image-generation needs to manually created the WantedBy association links). That said, we *can* also move this into another package that the ARM images would include that would amend the default configuration (similar to what the fedora-release-workstation and fedora-release-server packages do).

Comment 4 Vratislav Podzimek 2015-08-11 07:14:51 UTC
(In reply to Stephen Gallagher from comment #3)
> (In reply to Peter Robinson from comment #2)
> > How does it run on the first run if not enabled?
> 
> From the original description: "Anaconda makes sure to enable the
> appropriate IS services.". I assume (but have not checked), that this
> implies that Anaconda essentially calls 'systemctl enable
> initial-setup.service' before rebooting into the new environment.
Yes, that's exactly what happens except that there are two services (graphical, text) that are both enabled and that the 'firstboot' kickstart command is taken into account.

> 
> I'd like to have someone confirm that interpretation, however.
> 
> As for the ARM images, which don't run Anaconda, I think the preset might
> still be needed (or else the image-generation needs to manually created the
> WantedBy association links). That said, we *can* also move this into another
> package that the ARM images would include that would amend the default
> configuration (similar to what the fedora-release-workstation and
> fedora-release-server packages do).
Aren't ARM images created with anaconda too? Based on kickstarts? If so, it should be enough to make sure 'firstboot --enable' is used in those kickstarts.

Comment 5 Kevin Fenzi 2015-08-18 16:01:08 UTC
This was merged already upstream in 
https://pagure.io/fedora-release/pull-request/4
I think. 

We just need to cut a new release of fedora-release. ;)

Comment 6 Martin Kolman 2016-02-12 18:23:07 UTC
(In reply to Kevin Fenzi from comment #5)
> This was merged already upstream in 
> https://pagure.io/fedora-release/pull-request/4
> I think. 
> 
> We just need to cut a new release of fedora-release. ;)

I'm pretty sure this already happened a while ago so this could be closed. :)