On the client system, edit the /etc/default/dhcpagent file as root.
Find the keyword REQUEST_HOSTNAME in the /etc/default/dhcpagent file and modify it as follows:
REQUEST_HOSTNAME=yes |
If there is a comment sign (#) in front of the keyword, remove the #. If the keyword is not present, insert it.
Edit the /etc/hostname.interface file on the client system and add the following line:
inet hostname
where hostname is the name you want the client to use.
As root, type the following commands to have the client perform a full DHCP negotiation upon rebooting:
# pkill dhcpagent # rm /etc/dhcp/interface.dhc # reboot |
The DHCP server makes sure that the host name is not in use by another system on the network before the server assigns it to the client. Depending how it is configured, the DHCP server may update name services with the client's host name.