Bug 1978995

Summary: [RFE] The satellite-installer should display the mismatched FQDN additionally rather than just showing the commands to verify the output
Product: Red Hat Satellite Reporter: Sayan Das <saydas>
Component: InstallationAssignee: Eric Helms <ehelms>
Status: CLOSED ERRATA QA Contact: Jameer Pathan <jpathan>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9.0CC: ahumbe, dhjoshi, ehelms, gtalreja, jpathan
Target Milestone: 6.13.0Keywords: FutureFeature, Triaged
Target Release: Unused   
Hardware: All   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2023-05-03 13:20:33 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 Sayan Das 2021-07-04 02:59:19 UTC
1. Proposed title of this feature request

The satellite-installer should display the mismatched FQDN additionally rather than just showing the commands to verify the output.


2. What is the nature and description of the request?

Same as above


3. Why does the customer need this? (List the business requirements here)

Right now, if the output of `hostname -f` differs with `facter fqdn` then the customer will be prompted with the following output.

###

Output of 'facter fqdn' is different from 'hostname -f'

Make sure above command gives the same output. If needed, change the hostname permanently via the
'hostname' or 'hostnamectl set-hostname' command
and editing the appropriate configuration file.
(e.g. on Red Hat systems /etc/sysconfig/network,
on Debian based systems /etc/hostname).

If 'hostname -f' still returns an unexpected result, check /etc/hosts and put
the hostname entry in the correct order, for example:

 1.2.3.4 hostname.example.com hostname

The fully qualified hostname must be the first entry on the line
Your system does not meet configuration criteria

###

Under normal circumstances, by following the steps from the output or https://access.redhat.com/solutions/6165292, someone can easily solve the issue but in case the primary IP has two different DNS aliases then the confusion with FQDN selection will increase.

So suggested is that the message should be expanded to include and display the output of the two different FQDN's detected by the installer.


4. How would the customer like to achieve this? (List the functional requirements here)

Via satellite-installer



5. For each functional requirement listed, specify how Red Hat and the customer can test to confirm the requirement is successfully implemented.

- Install Satellite

- Create some anomaly with fqdn by adding some puppet facts or modifying /etc/hosts.

- Execute satellite-installer and verify whether it shows both the bad and good fqdn as a part of the existing error message or not.



6. Is there already an existing RFE upstream or in Red Hat Bugzilla?

NA


7. Does the customer have any specific timeline dependencies and which release would they like to target (i.e. RHEL5, RHEL6)?

Satellite 6.9 or 6.10


8. Is the sales team involved in this request and do they have any additional input?
No.


9. List any affected packages or components.

satellite-installer


10. Would the customer be able to assist in testing this functionality if implemented?

Yes

Comment 5 Lukas Pramuk 2022-10-05 13:59:58 UTC
FailedQA.

@Satellite 6.12.0 Snap13
foreman-installer-3.3.0.8-1.el8sat.noarch

# grep ^DIFFERENT /usr/share/foreman-installer/checks/hostname.rb
DIFFERENT = "Output of 'facter fqdn' is different from 'hostname -f

vs. 

Expected (change in upstream):
DIFFERENT = "Output of 'facter fqdn' (#{facter_fqdn}) is different from 'hostname -f' (#{hostname_f})

>>> the fix has not landed in downstream

Comment 9 Jameer Pathan 2023-02-02 07:29:01 UTC
Verified:

Verified with:
- Satellite 6.13.0 snap 9
- satellite-installer-6.13.0.4-1.el8sat.noarch

Test steps:
- set wrong satellite fqdn
- run satellite-installer

Observations:
- If output of `hostname --fqdn` and `facter fqdn` commands are different then satellite-installer gives the following message:


# satellite-installer 
2023-02-02 02:15:44 [NOTICE] [root] Loading installer configuration. This will take some time.
2023-02-02 02:15:48 [NOTICE] [root] Running installer with log based terminal output at level NOTICE.
2023-02-02 02:15:48 [NOTICE] [root] Use -l to set the terminal output log level to ERROR, WARN, NOTICE, INFO, or DEBUG. See --full-help for definitions.
Unable to resolve forward DNS for Sat_host
Output of 'facter fqdn' (Sat_host.example.com) is different from 'hostname -f' (Sat_host)

Make sure above command gives the same output. If needed, change the hostname permanently via the
'hostname' or 'hostnamectl set-hostname' command
and editing the appropriate configuration file.
(e.g. on Red Hat systems /etc/sysconfig/network,
on Debian based systems /etc/hostname).

If 'hostname -f' still returns an unexpected result, check /etc/hosts and put
the hostname entry in the correct order, for example:

  1.2.3.4 hostname.example.com hostname

Comment 12 errata-xmlrpc 2023-05-03 13:20:33 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 (Important: Satellite 6.13 Release), 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-2023:2097