Bug 1333034

Summary: Hostname set in Anaconda while installing is not applied on installed host
Product: [oVirt] ovirt-node Reporter: Sandro Bonazzola <sbonazzo>
Component: Installation & UpdateAssignee: Ryan Barry <rbarry>
Status: CLOSED CURRENTRELEASE QA Contact: Wei Wang <weiwang>
Severity: high Docs Contact:
Priority: urgent    
Version: masterCC: bugs, cshao, dfediuck, fdeutsch, rbarry, sbonazzo, weiwang, ycui
Target Milestone: ovirt-4.0.0-rc2Flags: rule-engine: ovirt-4.0.0+
rule-engine: planning_ack+
dfediuck: devel_ack+
ycui: testing_ack+
Target Release: 4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ovirt-node-ng-installer-ovirt-4.0-snapshot-2016061416.iso Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-07-05 07:39:17 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Node RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1329957    
Attachments:
Description Flags
anaconda logs
none
log file
none
ks_file
none
kickstart file none

Description Sandro Bonazzola 2016-05-04 14:35:27 UTC
Created attachment 1153899 [details]
anaconda logs

Installed NGN on a VM, set node.home as hostname in anaconda.
At reboot hostname is localhost.

Comment 1 Fabian Deutsch 2016-05-04 15:09:55 UTC
Sandro, could you please provide the NGN iso you used for installation and the kickstart?

Comment 2 Fabian Deutsch 2016-05-06 09:21:57 UTC
I see:

04:06:06,246 DEBUG anaconda: updating hostname localhost.localdomain

Let#s see what Wei has to say.

Comment 3 Yaniv Lavi 2016-05-09 10:53:15 UTC
Moving to first RC, since things should not be targeted to second one at this point.

Comment 4 Wei Wang 2016-05-12 07:49:35 UTC
Issue can not be reproduced using below builds  

Version:
ovirt-node-ng-installer-ovirt-3.6-2016051108.iso
ovirt-node-ng-installer-ovirt-3.6-2016050400.iso
ovirt-node-ng-installer-ovirt-3.6-2016050100.iso

Steps:
1. Install vm with kickstart file in attachment.
   key command:
   network --device=ens3 --bootproto=dhcp --hostname="node.home"

2. After reboot, check the hostname
   #hostname -f


Result:
The hostname still display as "node", after reboot.


Sandro, could you please provide the NGN iso you used and the kickstart?

Comment 5 Wei Wang 2016-05-12 07:50:28 UTC
Created attachment 1156493 [details]
log file

Comment 6 Wei Wang 2016-05-12 07:51:30 UTC
Created attachment 1156494 [details]
ks_file

Comment 7 Fabian Deutsch 2016-05-12 08:46:50 UTC
Please note, anaconda is strict about hostnames,

A name is just a hostname without a dot (node).
A FQDN can not be used as the hostname (node.home).

Comment 8 Wei Wang 2016-06-16 06:03:17 UTC
Test Version:
ovirt-node-ng-installer-ovirt-4.0-snapshot-2016061419.iso
imgbased-0.7.0-0.201606081307gitfb92e93.el7.centos.noarch

Test Steps:
1. Install machine with kickstart file in attachment.
   key command:
   network --device=enp0s25 --bootproto=dhcp --hostname="node.home"

2. After login with root account, check the hostname
   #hostname
   #cat /etc/hostname

Result:
hostname display as "node.home".

So the bug cannot be reproduced, I will change the status to VERIFIED.

Comment 9 Wei Wang 2016-06-16 06:04:13 UTC
Created attachment 1168565 [details]
kickstart file

Comment 10 Sandro Bonazzola 2016-07-05 07:39:17 UTC
oVirt 4.0.0 has been released, closing current release.