Bug 706073 - hostname no longer being set to dhcp hostname
Summary: hostname no longer being set to dhcp hostname
Alias: None
Product: Fedora
Classification: Fedora
Component: NetworkManager
Version: 19
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Dan Williams
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2011-05-19 12:36 UTC by Jeff Layton
Modified: 2014-06-18 07:41 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2013-04-05 17:44:49 UTC

Attachments (Terms of Use)
tail end of /var/log/messages (52.65 KB, text/plain)
2011-05-25 17:46 UTC, Jeff Layton
no flags Details

Description Jeff Layton 2011-05-19 12:36:01 UTC
Opening as an initscripts bug but I the problem may be elsewhere. Please reassign as you see fit. I suspect that this may be related to the fact that NetworkManager is now managing the network interfaces and not /etc/init.d/network.

In earlier versions of Fedora and in RHEL, when I get an address on a machine with dhcp, the initscripts set the hostname on the machine to the unqualified result of a reverse lookup of that address.

I recently did a rawhide install and now this no longer works. The hostname remains stuck at either "localhost.localdomain" or "(none)" if I comment out the HOSTNAME variable in /etc/sysconfig/network.

The host has:


Comment 1 Bill Nottingham 2011-05-19 13:57:52 UTC
http://blogs.gnome.org/dcbw/2010/12/16/good-touch-bad-touch-etchosts/ *may* be relevant here.

Comment 2 Dan Williams 2011-05-25 17:29:50 UTC
Can you provide some logs from /var/log/messages showing the issue?  That would help figure out what's going on.

Comment 3 Jeff Layton 2011-05-25 17:46:37 UTC
Created attachment 500894 [details]
tail end of /var/log/messages

Here's the tail end of /var/log/messages. This is with NetworkManager enabled and "network" disabled (both via chkconfig).

Earlier today, I disabled NetworkManager and enabled "network" and the hostname got set correctly on reboot. So this might not be a regression as much as a piece of unimplemented functionality in NM.

Comment 4 Fedora End Of Life 2013-04-03 18:31:39 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:

Comment 5 Dan Williams 2013-04-05 17:44:49 UTC
So it looks like in your configuration, the DHCP server isn't actually sending a hostname back to the client.  I'll assume then that the hostname is supposed to be created from the reverse-lookup of the client's IP address, which used to have a bug.  We've fixed that in F17+.  Please test and see if it now works, if not, re-open the bug and we can try to explicitly request a hostname from the DHCP server.

Comment 6 Jeff Layton 2013-04-05 18:18:02 UTC
I believe it does work now (and has for some time).

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