Bug 1379036

Summary: hostname -f check schould be done later
Product: Red Hat OpenStack Reporter: Fred van Zwieten <fvzwieten>
Component: documentationAssignee: Dan Macpherson <dmacpher>
Status: CLOSED CURRENTRELEASE QA Contact: RHOS Documentation Team <rhos-docs>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 9.0 (Mitaka)CC: dmacpher, srevivo
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-03-19 11:05:31 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:

Description Fred van Zwieten 2016-09-24 07:34:29 UTC
Description of problem:
wrong sequence of commands and checks in 4.3

Version-Release number of selected component (if applicable):
Director Installation and Usage, par 4.3 Setting the hostname for the system

How reproducible:
Installed RHEL7.2 from ISO and gave it a fqdn in anaconda - network. Then, the command "hostname" works, but "hostname -f" not. After doing the hostnamectl commands in 4.3 "hostname -f" still does not work. Only after adding the fqdn to /etc/hosts as explained in the last bit of 4.3 "hostname -f" works.

Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
This is hugely confusing for a first time admin. Suggest to specify the /etc/hosts modification bits first and all the other stuff after that.

Comment 1 Dan Macpherson 2018-03-19 11:05:31 UTC
Scoping old bug.

So the "hostname -f" command in this case is meant to check if the FQDN hostname is set. If it results in an error, that means the full hostname isn't set. So it acts as a test.

The wording has now been clarified: "f either commands do not report the correct hostname or report an error, use hostnamectl to set a hostname:"

https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/12/html-single/director_installation_and_usage/#sect-Setting_the_Hostname_for_the_System

Closing this BZ, but if further changes are required please let us know.