From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20041111 Firefox/1.0 Description of problem: /etc/resolv.conf is not updated during device startup and subsequent dhcp configuration. the user must edit /etc/resolv.conf and add the ip address for the local dns server for every new network connected. this problem is more likely to affect laptop users who roam between networks. Version-Release number of selected component (if applicable): 3.0.1 release 11 How reproducible: Always Steps to Reproduce: 1. configure eth0 to startup on boot 2. reboot on different network 3. note that eth0 starts up successfully 4. ping www.example.com fails because dns is not configured for the new network 5. check /etc/resolv.conf. indeed the file has not been updated. 6. note multiple instances of dhclient running Actual Results: /etc/resolv.conf was not updated by /sbin/dhclient-script. dns lookup failed because dns entries in /etc/resolv.conf are not pertinent or current to the local area network. Expected Results: /sbin/dhclient-script should generate a new /etc/resolv.conf upon network device startup and dhcp configuration. dns lookup should resolve successfully after updating /etc/resolv.conf for the local area network. Additional info: possibly related - dhclient is running multiple instances. see below: [will@mary ~]$ ps auxww|grep dhclient root 1406 0.0 0.1 2788 1028 ? S<s 16:16 0:00 /sbin/dhclient -1 -q -cf /etc/dhclient-eth0.conf -lf /var/lib/dhcp/dhclient-eth0.leases -pf /var/run/dhclient-eth0.pid eth0 root 1766 0.0 0.1 3788 1032 ? S<s 16:16 0:00 /sbin/dhclient -1 -q -cf /etc/dhclient-eth0.conf -lf /var/lib/dhcp/dhclient-eth0.leases -pf /var/run/dhclient-eth0.pid eth0 root 2320 0.0 0.1 2640 1024 ? Ss 16:16 0:00 /sbin/dhclient -1 -q -cf /etc/dhclient-eth0.conf -lf /var/lib/dhcp/dhclient-eth0.leases -pf /var/run/dhclient-eth0.pid eth0 root 2616 0.0 0.1 3096 1020 ? Ss 16:16 0:00 /sbin/dhclient -1 -q -cf /etc/dhclient-eth0.conf -lf /var/lib/dhcp/dhclient-eth0.leases -pf /var/run/dhclient-eth0.pid eth0 will 4337 0.0 0.0 5120 652 pts/1 R+ 16:41 0:00 grep dhclient i upgraded the distribution in question from fc2 to fc3 recently. i did not edit /etc/resolv.conf after the changeover. therefore, the contents therein have not changed regardless of the local area network address or dns. Workaround: edit /etc/resolv.conf manually for every new network.
I am not able to reproduce this problem. Please supply further information: 1. Please append your /etc/sysconfig/network-scripts/ifcfg-eth0 file to this bug. Is the PEERDNS variable set in ifcfg-eth0 ? 2. Are multiple dhclient instances run every time after rebooting ? 3. Do you use 'system-config-network' (neat) and have network profiles defined ? If so, there should be only one alias for eth0 - try moving the /etc/sysconfig/networking/profiles/ directory and rebooting - does the problem still occur? 4. Do you use NetworkManager ? If so, disable it, and the problem should go away. 5. Is your DHCP server supplying a DNS server ? You can check this by doing the following: # ifconfig eth0 down # pkill dhclient # ifconfig eth0 0.0.0.0 up # dhclient eth0 | tee /tmp/dhclient.out Please append the /tmp/dhclient.out file to this bug.
Created attachment 107297 [details] /etc/sysconfig/network-scripts/ifcfg-eth0
thanks for your prompt reply. answers to your questions below: 1. created ifcfg-eth0 attachment 2 [details]. yes. multiple instances of dhclient startup on every boot. 3. yes. i have multiple network profiles defined: [will@mary default]$ pwd /etc/sysconfig/networking/profiles/default [will@mary default]$ ls -l total 28 -rw-r--r-- 2 root root 119 Nov 22 14:55 hosts -rw-r--r-- 3 root root 164 Nov 22 14:55 ifcfg-eth0 -rw-r--r-- 3 root root 310 Nov 22 14:55 ifcfg-eth1 -rw-r--r-- 3 root root 142 Nov 22 14:55 ifcfg-Home -rw------- 3 root root 5 Nov 22 14:55 keys-eth1 -rw------- 3 root root 19 Nov 22 14:55 keys-Home -rw-r--r-- 1 root root 0 Nov 22 14:55 network -rw-r--r-- 2 root root 141 Nov 22 14:55 resolv.conf - eth0 is the hardwire 10/100BaseT ethernet device in question - eth1 is a profile for my wireless card which btw, locks up the machine when i insert it into the pcmcia slot. see bug # - Home is a profile that i setup after i filed this bug in order to test ipsec... which doesn't seem to work either. i'll file a bug on this one later. i haven't tried moving /etc/sysconfig/networking/profiles yet. i'll have to reboot and report back. 4. i'm not using networkmanager. 5. here's the output from those commands: --snip-- [will@mary network-scripts]$ cat /etc/resolv.conf ; generated by /sbin/dhclient-script search mccammonenterprises.com nameserver 192.168.13.12 nameserver 192.168.58.251 nameserver 129.71.1.1 [will@mary network-scripts]$ sudo ifdown eth0 [will@mary network-scripts]$ sudo pkill dhclient [will@mary network-scripts]$ sudo ifconfig eth0 0.0.0.0 up [will@mary network-scripts]$ sudo dhclient eth0 | tee /tmp/dhclient.out Internet Systems Consortium DHCP Client V3.0.1 Copyright 2004 Internet Systems Consortium. All rights reserved. For info, please visit http://www.isc.org/products/DHCP sit0: unknown hardware address type 776 sit0: unknown hardware address type 776 Listening on LPF/eth0/08:00:1f:b1:02:40 Sending on LPF/eth0/08:00:1f:b1:02:40 Sending on Socket/fallback DHCPREQUEST on eth0 to 255.255.255.255 port 67 DHCPACK from 192.168.13.254 bound to 192.168.13.50 -- renewal in 10116 seconds. [will@mary default]$ cat /etc/resolv.conf ; generated by /sbin/dhclient-script search mccammonenterprises.com nameserver 192.168.13.12 nameserver 192.168.58.251 nameserver 129.71.1.1 -- snip -- /tmp/dhclient.out is empty: [will@mary network-scripts]$ ls -l /tmp/dhclient.out -rw-rw-r-- 1 will will 0 Nov 23 08:58 /tmp/dhclient.out
mea culpa. sorry. problem solved. i did not have PEERDNS set as you indicated. new ifcfg-eth0 below: [will@mary network-scripts]$ more ifcfg-eth0 # Realtek|RTL-8139/8139C/8139C+ DEVICE=eth0 BOOTPROTO=dhcp HWADDR=08:00:1F:B1:02:40 ONBOOT=yes TYPE=Ethernet USERCTL=yes PEERDNS=yes IPV6INIT=yes DHCP_HOSTNAME=mary