From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:0.9.2) Gecko/20010802 Description of problem: On a fresh install of RH 7.2, dhcp was enabled. No hostname (or any other network related field) was set. I can ssh to machines on the net just fine, however, "ping `hostname`" doesn't work! fetchmail fails saying it can't "gethostbyname for xxx," where xxx is the hostname set by dhcp. (If it helps, xxx is _not_ fully qualified... it is xxx, rather than xxx.twcny.rr.com, which would be the fully qualified name.) Also, gdm doesn't start at boot even though I requested a graphical login screen. In addition to that, when starting a GNOME session using startx, GNOME reports that the hostname can't be resolved, so some things won't work correctly. (I don't remember GNOME's error message off of the top of my head... I'm at a different workstation right now.) Also, /etc/hosts isn't being updated with the new hostname & ip address. (This seems to be the root of the problem.) The summary is, RH 7.2 doesn't work out of the box with my cable modem connection. (It's not going to be a big fix, and I can probably hack around it for my own machine, but I'd like to know the right way to do it, and I figured you guys would want to know to update the dhcp scripts or the installer to make things work without any effort by the end user. :) Thanks for looking into this! John p.s. The rest of 7.2 looks very smooth. :) Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1. Plug the box into my dhcp cable modem network. 2. Install RH 7.2, and let dhcp set all network info 3. Try to start a GNOME session, ping `hostname`, or run fetchmail. Additional info:
I am having exactly the same problem, and everything worked fine with redhat 7.0 and 7.1, so its a bit weird. I would be glad to know of the proper fix. For the time being i am just setting hostname manually.
In the file /etc/sysconfig/network-scripts/ifup, I commented out the line: DHCPCDARGS="${DHCPCDARGS} -H". This stops dhcpcd from setting the hostname. The initscripts then use some other method to set the hostname, which I assume was what happened before redhat 7.2. In my case this fix works perfectly.
One of the scripts involved by "/etc/init.d/network start" rewrites /etc/resolv.conf setting "domain" and "search" and "nameserver". If your ISP dhcpd did it wrong (e.g. mine sets my IP to resolve as "xxxxx.abo.wanadoo.fr" but sets my "domain" (and "search") as "wanadoo.fr". So several services such as "lpd", "gdm", "fetchmail"(?) will not start. The fix could be not to rewrite the "search" parameter at least: Most sysadmins do know what to search!
I do believe this is fixed in the latest initscripts/dhcpcd - please try them out of rawhide (may need to rebuild).
I am having the same problem with Redhat v7.2. I have been on two separate cable ISPs, and both ISPs had the same problem (Roadrunner and Cox). I also get that error on Gnome startup, and can't ping my hostname. I could fix the problem (temporarily) by going into the "Network configuration wizard" and removing some of the entries on the DNS tab and rebooting. It doesn't seem to work anymore, though. My domain name is: ipXXX-XXX-XXX-XXX.ri.ri.cox.net My hostname changes on occasion and so does my ip, so I can't add that to /etc/hosts without having to change it each time. where the XXX represents numbers. I also have problems with X server saying unknown host on startup and proftpd saying it can't find the domain name for a particular ip. Here is a thread where some talking has gone on about the issue: http://www.linuxquestions.org/questions/showthread.php?s=&threadid=16880&perpage=15&pagenumber=1 It also contains some information about my setup (my name is netdemon on it and my posts start on the second page). Unfortunately, no one could help me there. From what I found from searching the web, this problem is very widespread for people without routers on many distributions: http://groups.google.com/groups?hl=en&lr=&ie=UTF8&oe=UTF8&th=528bc591343e9697&rnum=2 http://groups.google.com/groups?hl=en&lr=&ie=UTF8&oe=UTF8&th=dbb9dd9b45e036cb&rnum=5 http://groups.google.com/groups?hl=en&lr=&ie=UTF8&oe=UTF8&th=5699ac1655b14d87&rnum=15 http://groups.google.com/groups?hl=en&lr=&ie=UTF8&oe=UTF8&th=b8ccd642000ecc8d&rnum=19 http://pub14.ezboard.com/fnutzboardfrm17.showMessage?topicID=43.topic&index=2 http://www.geocrawler.com/mail/msg.php3?msg_id=4896730&list=263 No one was able to help me in irc.openprojects.org #redhat. Please come up with a solution. This is really aggravating :-(
mwalton: What you did seemed to solve my problem. Do you think that the command "dhcpcd -H" has a bug? I don't really understand dhcp that well, so I wouldn't know the answer to that question.I have seen this happen to people on even BSD, so I assume that it is a problem with certain ISPs that might be somewhat new due to changes in the way the ISPs operate (or maybe a regression in the code).
sopwith: If the problem seems to be the dhcpcd utilities on all Unix systems, what do you mean by initscripts/dhcpcd? I might be wrong (which I problably am), but the problem seems to appear in /sbin/dhcpcd -H
I'm on 7.2 here, and connected to comcast.net 1:06am {21} pcp01487252pcs:/var/log># cat /etc/sysconfig/networking/devices/ifcfg-eth0 DEVICE=eth0 ONBOOT=yes BOOTPROTO=dhcp DHCP_HOSTNAME=cn2473162-a both originally and currently, setting the DHCP_HOSTNAME in this file caused me to have the correct hostname .. originally it was cn2473162-a, but currently comcast changed how its dhcp works, and now no longer needs the client-id set, other than that it does need to have *something* there (could be a random string of chars like ahsjdgajgd) currently I get : 12:55am {20} pcp01487252pcs:/var/log># hostname pcp01487252pcs and that varies over time ultimately since I am on dynamic IP. I also have echo "1" > /proc/sys/net/ipv4/ip_dynaddr set in /etc/rc.d/rc.local I can't think of anything else I changed. nothing in /etc/hosts gets changed by this. my /etc/resolv.conf looks like this: domain limstn01.de.comcast.net nameserver 68.82.0.6 nameserver 68.82.0.5 search limstn01.de.comcast.net I can't recall whether I set that manually or whether the system configured that on its own at boot time. it just works. the problem may be with your cable providers. not sure. This worked on an old 486 DX-2/66 with ancient ISA RealTek 8019a card, and currently with ne2k-pci-driver and 8139too-driver using PCI cards in the new Duron 1.1Ghz box.