"No broadcast interfaces found - exiting" despite presence of eth0.
olivier.lahaye at cea.fr
Mon Mar 18 16:11:44 UTC 2013
I'm facing a wired problem using dhclient.
I'm creating a specific initrd from scratch (for systemimager deployment software), and I've built dhcp-4.2.4-P2
My initrd is using kernel 3.7.5 and udev-182. I've not used systemd and Networkmanager either.
When booting, all the hardware is correctly detected, but dhclient fails with the error: "No broadcast interface found - exiting.".
This is strange because if I type "dhclient eth0", it works.
If I type ifconfig eth0 inet 0.0.0.0; ifconfig eth0 down
and If I setup a buggy address like ifconfig eth0 inet 192.168.1.1
then dhclient without parameter can discover the interface a get an ip from the server......
More over, if I look at /sys/class/net/eth0/flags, it is 1002 (or 1003 if up), thus it is a BROADCAST able interface.
If I copy the binay of dhclient to a "normal" host, it correctly detects the broadcast interfaces. So I'm sure that the problems does not comes from the dhclient code, but from the environment it is running in.
I can't setup a debug environment into my initrd (gdb+code +...) and it's very hard to debug.
Looking into common/discover.c, I see no reason why my interface could be ignored.
- Maybe a filesystem is not mounted and the socket fails to be created and thus no interface are listed? If yes, what mountpoint of path could be missing?
I have (all rw):
/var/run (link to /run)
- Or maybe a bad option is setup in my kernel? If yes which one?
- Or maybe a bad option in udevd compilation? a missing script?
- my /sbin/dhclient-script seems correct and my /etc/dhcp/dhclient-exit-hoots is also correct as I can retreive all parameters when issuing "dhclient eth0".
Any ideas what could prevent dhclient to ignore eth0 if not specified on the command line and if ip is set to 0.0.0.0?
Many thanks for any advices
PS: I'm running inside a vmware client and the dhcpd on the host is not running (I'm using a dhcpd from centos on another vm). The dhcpd is correctly set up as dhclient eth0 on the client works. It's only when I don't specify the interface and when the ip is 0.0.0.0 that the dhclient fails to discover interfaces.....
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the dhcp-users