I just found a bug in Red Hat/Mandrake 6.x's network scripts for DHCP
clients. Here is how you fix it:
Edit /sbin/ifup (it's a shell script) and go to line 89. It should look
like this:
if /sbin/dhcpcd -i $DEVICE -h $HOSTNAME ; then
Change it to this:
if /sbin/dhcpcd -i $DEVICE -h ${HOSTNAME%%.*} ; then
Now for the bug itself: when requesting an IP address via DHCP, the
client is expected to tell the server it's hostname. The above line
however, will tell the server it's fully qualified domain name, which
conflicts with the behaviour of Windows clients: they specify only the
first part of the hostname. The modified line above mimics the Windows
behaviour by stripping out the dot and everything after it.
This difference in behaviour is normally not an issue. It came up
because I was trying to get my DNS updated from dhcpd.leases, and my
Linux desktop was the only one that was sending in a broken hostname.
--
Kiran Jonnalagadda
http://lunateks.com
baby.sh: while true; do echo "^G^G^G^G^G"; sed -e 's/food/poop/'; sync;
sync; sleep 15; done
To subscribe / unsubscribe goto the site www.ilug-bom.org ., click on the mailing list
button and fill the appropriate information
and submit. For any other queries contact the ML maintener