Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 613734 - o-c-hostname fails to set hostname
o-c-hostname fails to set hostname
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: ovirt-node (Show other bugs)
6.0
All Linux
low Severity medium
: rc
: ---
Assigned To: Joey Boggs
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-07-12 13:56 EDT by Mike Burns
Modified: 2010-11-11 09:53 EST (History)
5 users (show)

See Also:
Fixed In Version: ovirt-node-1.9.3-4.gitf53c39c.el6
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-11-11 09:53:25 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
patch (743 bytes, patch)
2010-07-12 15:50 EDT, Joey Boggs
no flags Details | Diff

  None (edit)
Description Mike Burns 2010-07-12 13:56:35 EDT
Description of problem:
Running Configure Hostname from the firstboot menu results in a message of "Invalid Hostname" if anything other than an empty string is entered of entry.

Tried:

 host1.example.com
 host1
 host
 1.1.1.1


Version-Release number of selected component (if applicable):
6.0

How reproducible:
Always

Steps to Reproduce:
1.Choose configure hostname from firstboot menu
2.enter anything other than empty string
3.
  
Actual results:
Invalid Hostname

Expected results:
Sets hostname if valid

Additional info:

Looking at o-c-hostname, it seems that the condition doesn't work anymore:

    if [[ $host =~ "^([a-zA-Z0-9._-]+)$" ]]; then
        result=$?
    fi
Comment 3 Joey Boggs 2010-07-12 15:50:02 EDT
Created attachment 431252 [details]
patch
Comment 5 XinSun 2010-08-24 05:22:39 EDT
Check this bug on rhevh6.0-2.3 snapshot12, do follow test steps:

1. In firstboot menu, choose option 3 to set hostname
2. Input:
        host1.example.com
        host1
        host
        1.1.1.1
then all hostname are set successfully.

Please see details:

Choose an option: 
1) Configure storage partitions	   8) Register Host to RHN
2) Configure authentication	   9) Enable SNMP Agent
3) Set the hostname		  10) Configure the host for RHEV
4) iSCSI Initiator setup	  11) View logs
5) Networking setup		  12) Install locally and reboot
6) Logging setup		  13) Support Menu
7) Kdump Configuration
Choose an option:3

Hostname Configuration

What is the hostname for this node? host1.example.com

Hostname has been set

Red Hat Enterprise Virtualization Hypervisor release 6.0 (12.el6)


 Hypervisor Configuration Menu

1) Configure storage partitions	   8) Register Host to RHN
2) Configure authentication	   9) Enable SNMP Agent
3) Set the hostname		  10) Configure the host for RHEV
4) iSCSI Initiator setup	  11) View logs
5) Networking setup		  12) Install locally and reboot
6) Logging setup		  13) Support Menu
7) Kdump Configuration
Choose an option: 13
This menu is for troubleshooting with support representatives. Do not use these options without guidance from support. Enter the support menu ([Y]es or [N]o)? y
Support Menu

1) Shell			     3) Uninstall an existing Hypervisor
2) Continue boot		     4) Exit support menu
Choose an option: 1

[root@host1 /]# hostname
host1.example.com

So change this bug's status to verified.
Comment 6 releng-rhel@redhat.com 2010-11-11 09:53:25 EST
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

Note You need to log in before you can comment on or make changes to this bug.