Bug 135495 - Diskless client hostname incorrectly set: ends with a dot
Diskless client hostname incorrectly set: ends with a dot
Status: CLOSED RAWHIDE
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: redhat-config-netboot (Show other bugs)
3.0
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Walsh
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2004-10-12 21:59 EDT by Graham Leggett
Modified: 2007-11-30 17:07 EST (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-10-20 10:34:04 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Graham Leggett 2004-10-12 21:59:57 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3)
Gecko/20040925

Description of problem:
In the disklessrc script, some text cutting magic is used to extract
the hostname from the IP address of the machine, as reported using the
"host" command.

The problem is that the result of the cutting process produces a
hostname terminated with a dot, instead of just a hostname, like so:

hostname.example.com.
                    ^--- extra dot

This causes problems with Gnome, which complains that the hostname of
the machine is not found.


Version-Release number of selected component (if applicable):
system-config-netboot-0.1.7-1

How reproducible:
Always

Steps to Reproduce:
xxx

Additional info:
Comment 1 Daniel Walsh 2004-10-19 11:27:50 EDT
I am not seeing this here.  Could you give me an example of the IP
address that this happens with.  IE 

> host 209.132.177.50  |  sed 's/.* \(.*\)./\1/'
www.redhat.com
Comment 2 Graham Leggett 2004-10-19 12:19:47 EDT
When you run "host" manually, it does this:

[root@gatekeeper root]# host 192.168.200.200
200.200.168.192.in-addr.arpa domain name pointer violet.fma.co.za.

It seems text chopping magic leaves the dot on the end of the sentence
intact.

The host app version is as follows:

[root@gatekeeper root]# which host
/usr/bin/host
[root@gatekeeper root]# rpm -q -f /usr/bin/host
bind-utils-9.2.4-EL3_10

In my version of "disklessrc" the hostname is extracted in the
following line:

hostname `host $IP | cut -f 5 -d ' '`

Is this from an older version of netboot, perhaps?
Comment 3 Daniel Walsh 2004-10-19 13:23:03 EDT
Yup.

ftp://people.redhat.com/dwalsh/netboot has the latest.  Will be in U4

However this code is not in the greatest of shape.  :^(

Dan

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