Bug 1417068

Summary: System does not get registered because {"network.hostname-override":""} in /etc/rhsm/facts/katello.facts is empty due `hostname -f`
Product: Red Hat Satellite Reporter: Satellite Program <pm-sat>
Component: RegistrationAssignee: satellite6-bugs <satellite6-bugs>
Status: CLOSED ERRATA QA Contact: Lukas Pramuk <lpramuk>
Severity: urgent Docs Contact:
Priority: urgent    
Version: 6.2.5CC: bbuckingham, cdonnell, chrobert, ehelms, greartes, jcallaha, lpramuk, marcus.oliphant, mmello, nitthoma, nshaik, oshtaier, prsharma, wrichter
Target Milestone: UnspecifiedKeywords: PrioBumpGSS, Triaged
Target Release: Unused   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1405614 Environment:
Last Closed: 2018-02-21 16:47:15 UTC Type: ---
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: 1405614    
Bug Blocks:    

Comment 3 Lukas Pramuk 2017-10-20 10:33:35 UTC
VERIFIED.

@satellite-6.3.0-20.0.beta.el7sat.noarch
katello-installer-base-3.4.5.4-1.el7sat.noarch
tfm-rubygem-katello-3.4.5.10-1.el7sat.noarch

1. Create a VM that SAT (6.3.0) is not aware of (preferably behind NAT)

2. Simulate that `hostname -f` fails for on the VM
# cat > /usr/bin/hostname <<<'exit 1'

3. Install CA consumer certs
# rpm -Uvh http://$SAT/pub/katello-ca-consumer-latest.noarch.rpm

4. Check contents of /etc/rhsm/facts/katello.facts
# cat /etc/rhsm/facts/katello.facts
cat: /etc/rhsm/facts/katello.facts: No such file or directory

5. Register new (not yet registered) host
# subscription-manager register --username admin --password changeme
Registering to: <SAT_FQDN>:443/rhsm
Environment: Library
The system has been registered with ID: 26e6fed3-de03-4273-bcfd-2bed451e2aa6 

>>> the new host registration succeeds regardless of /etc/rhsm/facts/katello.facts content

Comment 4 Bryan Kearney 2018-02-21 16:43:02 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, 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/RHSA-2018:0336

Comment 5 Bryan Kearney 2018-02-21 16:47:15 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, 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/RHSA-2018:0336