Bug 1921787

Summary: rhsm and syspurpose commands written into /root/anaconda-ks.cfg when subscription is not enabled
Product: Red Hat Enterprise Linux 8 Reporter: Jan Stodola <jstodola>
Component: anacondaAssignee: Vendula Poncova <vponcova>
Status: CLOSED ERRATA QA Contact: Release Test Team <release-test-team-automation>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.4CC: jikortus, pzatko, rvykydal, vponcova
Target Milestone: rcKeywords: Triaged
Target Release: 8.0Flags: pm-rhel: mirror+
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: anaconda-33.16.4.10-1 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-05-18 15:47:16 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:
Bug Depends On:    
Bug Blocks: 1879091, 1903942    

Description Jan Stodola 2021-01-28 15:48:01 UTC
Description of problem:
/root/anaconda-ks.cfg created by anaconda on the installed system contains the "rhsm" and "syspurpose" commands from the original kickstart file even when the subscription module was not enabled by the anaconda config files.

It can also happen that some of the commands are present twice in the kickstart file generated by anaconda when the subscription module is enabled (it means the default RHEL installation without any anaconda config files).

Mentioning both cases, since it would be good to verify both of them when this bug is fixed.

Related bug 1913689.

Version-Release number of selected component (if applicable):
anaconda-33.16.4.8-1.el8

How reproducible:
always

Steps to Reproduce:
0. prepare a kickstart file with the rhsm and syspurpose commands set
1. run the installation with the subscription module disabled (use updates.img, see bug 1913689)
2. run the installation with the subscription module enabled (default RHEL installation)

Actual results:
1) rhsm and syspurpose commands present in /root/anaconda-ks.cfg even when the subscription module was disabled.
2) rhsm and/or syspurpose commands present twice in /root/anaconda-ks.cfg when the subscription module was enabled (default RHEL installation)

Expected results:
1) no rhsm and syspurpose commands in /root/anaconda-ks.cfg
2) rhsm and syspurpose commands in /root/anaconda-ks.cfg exactly once.

Comment 10 errata-xmlrpc 2021-05-18 15:47:16 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (anaconda bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2021:1844