This is required for networks setups where dhcpd uses DDNS to register LAN clients in the local domain. This functionality is supported by initscripts by setting the DHCP_HOSTNAME parameter in the ifcfg-XYZ file.
Would it be sufficient to send your current machine hostname to the DHCP server? I'd planned on just sending the configured hostname (as long as it wasn't localhost.localdomain or localhost of course). It's exceedingly unlikely that you'd use a different assigned hostname than the one you'd send to the DHCP server for DDNS.
(In reply to comment #1) > Would it be sufficient to send your current machine hostname to the DHCP > server? I'd planned on just sending the configured hostname (as long as it > wasn't localhost.localdomain or localhost of course). It's exceedingly > unlikely that you'd use a different assigned hostname than the one you'd send > to the DHCP server for DDNS. Yeah, that would be great. One less manual customization to do on most enterprise clients :-)
This bug has been triaged. -- Fedora Bugzappers volunteer triage team https://fedoraproject.org/wiki/BugZappers
This bug appears to have been reported against 'rawhide' during the Fedora 11 development cycle. Changing version to '11'. More information and reason for this action is here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping
See also https://bugzilla.redhat.com/show_bug.cgi?id=508981 which this bug should probably block on, since the NM server (though not the applet) already understands a NM_SETTING_IP4_CONFIG_DHCP_HOSTNAME which results in a "send host-name" in the dhcp config file.
*** Bug 510253 has been marked as a duplicate of this bug. ***
*** Bug 540887 has been marked as a duplicate of this bug. ***
This message is a reminder that Fedora 12 is nearing its end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 12. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '12'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 12's end of life. Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 12 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug to the applicable version. If you are unable to change the version, please add a comment here and someone will do it for you. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping
Still an issue in F14
The feature has actually been implemented for a while already. DHCP_HOSTNAME= from ifcfg files is respected and when present, NM will send the value to the DHCP server. See these bugs for more info: bug 469336 - detailed description how to enable sending hostname to DHCP bug 590096 - describing a workaround - editing dhclient conf file bug 596242 - patch for nm-connection-editor to be able to handle the feature in the GUI (specifying a name or telling NM to use the persistent hostname) The only deficiency is that "send-dhcp-hostname" property is set to "FALSE" by default. So, without adding DHCP_HOSTNAME to ifcfg file or adding "dhcp-hostname" via gconf-editor, the hostame won't be sent to DHCP. This patch may be convenient: diff --git a/libnm-util/nm-setting-ip4-config.c b/libnm-util/nm-setting-ip4-config.c index 186e41e..ec8de7c 100644 --- a/libnm-util/nm-setting-ip4-config.c +++ b/libnm-util/nm-setting-ip4-config.c @@ -950,7 +950,7 @@ nm_setting_ip4_config_class_init (NMSettingIP4ConfigClass *setting_class) "the 'dhcp-hostname' property is empty and this " "property is TRUE, the current persistent hostname " "of the computer is sent.", - FALSE, + TRUE, G_PARAM_READWRITE | G_PARAM_CONSTRUCT | NM_SETTING_PARAM_SERIALIZE)); /** It turns the feature *on* by default. The value sent would be: - DHCP_HOSTNAME (or dhcp-hostame) if present - else the persistent hostname (HOSTNAME in case of RH configuration) - otherwise no hostname will be sent.
The issue I'm referring to, is that when a machine is initially setup, I know of no convenient way to get DHCP_HOSTNAME set _besides_ manually editing ifcfg files. That requires much too high a level of expertise: to know which files to edit, make sure to edit them in a manner that preserves hard-links.
What is it going to take to have the change in Comment 10 actually make its way into NetworkManager? Or, alternatively, have some easy way of having the persistent hostname be sent on all DHCP interactions (that don't have something else specified)? I've gotten used to adding the "magic" /etc/dhclient-eth0.conf and /etc/dhclient-wlan0.conf files, but just spent a while figuring out what went wrong on a new box. The problem was that the box had eth1. :-(
I just edit /etc/sysconfig/network-scripts/ifcfg-etho adding DHCP_HOSTNAME=xxxyyy being VERY careful to preserve hardlinks (emacs with backup-by-copying-when-linked t)
The ifcfg route is quite similar to the dhclient route. Both require editing a file for each piece of hardware. As you say, it would be better to have a much easier way of sending the host name in DHCP interactions (ideally one with no user input). The patch in Comment 10 appears to be a way of doing this. My question remains is how to get this bug fix (or maybe it is an enhancement) into NetworkManager. Perhaps the best route would be to start a thread in the NetworkManager mailing list.
Fedora 12 changed to end-of-life (EOL) status on 2010-12-02. Fedora 12 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. Thank you for reporting this bug and we are sorry it could not be fixed.
Reopened to change the default behaviour on sending hostname to DHCP server.
The following commit contains the patch from comment 10: 9f28308460ea5ab55db9b59690bf95fcd096c1bb (master) 9b61ec7c58e8106c28d01b33ad0b263aefb1f347 (NM_0_8) So, when a hostname is configured, it is sent to DHCP server by default.
NetworkManager-0.8.3.995-1.fc14 has been submitted as an update for Fedora 14. https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.995-1.fc14
NetworkManager-0.8.3.995-1.fc13 has been submitted as an update for Fedora 13. https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.995-1.fc13
NetworkManager-0.8.3.995-1.fc14 has been pushed to the Fedora 14 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update NetworkManager'. You can provide feedback for this update here: https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.995-1.fc14
*** Bug 676208 has been marked as a duplicate of this bug. ***
Package NetworkManager-0.8.3.996-1.fc14: * should fix your issue, * was pushed to the Fedora 14 updates-testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing NetworkManager-0.8.3.996-1.fc14' as soon as you are able to, then reboot. Please go to the following url: https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.996-1.fc14 then log in and leave karma (feedback).
Package NetworkManager-0.8.3.996-1.fc13: * should fix your issue, * was pushed to the Fedora 13 updates-testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing NetworkManager-0.8.3.996-1.fc13' as soon as you are able to, then reboot. Please go to the following url: https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.996-1.fc13 then log in and leave karma (feedback).
NetworkManager-0.8.3.996-1.fc14 has been pushed to the Fedora 14 stable repository. If problems still persist, please make note of it in this bug report.
Package NetworkManager-0.8.3.997-1.fc13: * should fix your issue, * was pushed to the Fedora 13 updates-testing repository, * should be available at your local mirror within two days. Update it with: # su -c 'yum update --enablerepo=updates-testing NetworkManager-0.8.3.997-1.fc13' as soon as you are able to, then reboot. Please go to the following url: https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.997-1.fc13 then log in and leave karma (feedback).
Can we please get this into F15? rpm -q NetworkManager NetworkManager-0.8.2-8.git20101117.fc15.x86_64 sudo yum --enablerepo=updates-testing update NetworkManager [sudo] password for nbecker: Loaded plugins: langpacks, presto, refresh-packagekit Adding en_US to language list Setting up Update Process No Packages marked for Update
NetworkManager-0.8.3.998-2.fc13 has been submitted as an update for Fedora 13. https://admin.fedoraproject.org/updates/NetworkManager-0.8.3.998-2.fc13
NetworkManager-0.8.3.998-2.fc13 has been pushed to the Fedora 13 stable repository. If problems still persist, please make note of it in this bug report.