DHCP recognizes LAN only minutes after plugging cable

Bug #59926 reported by Jörg Höhle
6
Affects Status Importance Assigned to Milestone
dhcp3 (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Hi,
[This is about Dapper - Launchpad confuses me so much]
The logfiles below show that it took 4 minutes to DHCP to eventually enable my network connection after the kernel immediately recognized my plugging in the cable.

Sep 8 10:00:37 localhost kernel: [4294911.988000] eth0: link up, 100Mbps, full-duplex, lpa 0xC3E1
Sep 8 10:04:18 localhost dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
Sep 8 10:04:24 localhost dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
Sep 8 10:04:24 localhost dhclient: DHCPOFFER from 10.*.*.*
Sep 8 10:04:24 localhost dhclient: DHCPREQUEST on eth0 to 255.255.255.255 port 67
Sep 8 10:04:31 localhost dhclient: DHCPREQUEST on eth0 to 255.255.255.255 port 67
Sep 8 10:04:31 localhost dhclient: DHCPACK from 10.*.*.*
Sep 8 10:04:32 localhost dhclient: bound to 10.*.*.* -- renewal in 19461 seconds.

What I'd expect from a machine is to immediately recognize the new connection (kernel detects it on 10:00:37) and perform appropriate actions, e.g. start DHCP or whatever. Is anything wrong with this expectation (e.g. skip over intermittent failures)?

The observed behaviour is very user unfriendly, and so far I have found no way to speed it up (e.g. the manpage does not document anything like kill -USR1/HUP to have the dhcpclient daemon start a new cycle right now).

Ideally, the system would start different actions depending on what it snoops from the network (e.g. does traffic indicate a 192.168.*, or
DSL, or 10.* network?).

Currently, dhcp wakes up every 7 minutes, so the delay could even be longer. However, reducing this pause does not seem like a good answer. It looks like its integration into the system needs be reconsidered.

It seems to me like DHCP should not sit idle on the eth0 (and superfluously my WLAN eth1 which I have switched off) and better integrate into ifup/ifdown. (In Breezy, Hoary etc. DHCP was not even started for eth1, but that's another story.)

Is there anything I should configure differently in Dapper to have DHCP behave nicely and promptly?

Regards,
 Jörg Höhle

Tags: dapper
Revision history for this message
Bryan Quigley (bryanquigley) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you? Can you try with latest Ubuntu release? Thanks in advance.

Revision history for this message
Bryan Quigley (bryanquigley) wrote :

Network Manager should have fixed this in a newer release.

Changed in dhcp3:
status: New → Fix Released
Revision history for this message
Jörg Höhle (joerg-cyril-hoehle) wrote :
Download full text (3.3 KiB)

I now have access to Ubuntu Gutsy 7.10 which I boot from an USB HD. There is no improvement, as the following log snippets show.
I plugged the eth0 cable at 12:15 which was recognized within 2 seconds by avahi. DHCP only reacted 6 minutes later.
In nm-applet, I've disabled roaming (I'm not aware that the admins here support it, and set DHCP on eth0 instead).

Feb 1 12:10:10 jchlaptop dhclient: No working leases in persistent database - sleeping.
Feb 1 12:14:45 jchlaptop dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
Feb 1 12:14:51 jchlaptop dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 10
Feb 1 12:15:01 jchlaptop dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
Feb 1 12:15:10 jchlaptop dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
Feb 1 12:15:16 jchlaptop dhclient: No DHCPOFFERS received.
Feb 1 12:15:16 jchlaptop dhclient: No working leases in persistent database - sleeping.
Feb 1 12:15:20 jchlaptop kernel: [32959.104000] eth0: link up, 100Mbps, full-duplex, lpa 0xC3E1
Feb 1 12:15:20 jchlaptop kernel: [32959.112000] ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
Feb 1 12:15:22 jchlaptop avahi-daemon[5400]: Registering new address record for fe80::20b:5dff:fe79:914b on eth0.*.
Feb 1 12:15:31 jchlaptop kernel: [32969.408000] eth0: no IPv6 routers present
Feb 1 12:17:01 jchlaptop /USR/SBIN/CRON[11299]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly)
Feb 1 12:21:50 jchlaptop dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 7
Feb 1 12:21:50 jchlaptop dhclient: DHCPOFFER from 10.32...
Feb 1 12:21:50 jchlaptop dhclient: DHCPREQUEST on eth0 to 255.255.255.255 port 67
Feb 1 12:21:50 jchlaptop dhclient: DHCPACK from 10.32...
Feb 1 12:21:50 jchlaptop avahi-autoipd(eth0)[9087]: Got SIGTERM, quitting.
Feb 1 12:21:50 jchlaptop avahi-autoipd(eth0)[9087]: Callout STOP, address 169.254.5.236 on interface eth0
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Withdrawing address record for 169.254.5.236 on eth0.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Leaving mDNS multicast group on interface eth0.IPv4 with address 169.254.5.236.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Interface eth0.IPv4 no longer relevant for mDNS.
Feb 1 12:21:50 jchlaptop avahi-autoipd(eth0)[9088]: client: RTNETLINK answers: No such process
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Joining mDNS multicast group on interface eth0.IPv4 with address 10.32...
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: New relevant interface eth0.IPv4 for mDNS.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Registering new address record for 10.32... on eth0.IPv4.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Withdrawing address record for 10.32... on eth0.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Leaving mDNS multicast group on interface eth0.IPv4 with address 10.32...
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Interface eth0.IPv4 no longer relevant for mDNS.
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: Joining mDNS multicast group on interface eth0.IPv4 with address 10.32...
Feb 1 12:21:50 jchlaptop avahi-daemon[5400]: New relevant interface eth0.IPv4 ...

Read more...

Revision history for this message
Bryan Quigley (bryanquigley) wrote :

Can you replicate this with the liveCD?
Does it work if roaming is turned on?
Does this seem to affect a particular network card?
What is the DHCP server?
Thank you.

Changed in dhcp3:
status: Fix Released → Incomplete
Revision history for this message
wolfger (wolfger) wrote :

Over 3 months with no response. We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in dhcp3:
status: Incomplete → Invalid
Revision history for this message
Jörg Höhle (joerg-cyril-hoehle) wrote :

Sorry, I've had some intermittent hardware failure and was otherwise busy.
I've switched to Hardy now, and there the system behaves as the user expects.
I believe this comes from the switch to dhcdbd, i.e. DBus is driving DHCP and immediately started/stopped each time a particular interfaces goes up or down. In previous distributions, dhclient lived completely on its own, sleeping for long time before bothering to check whether something had changed in between.

Thus on one hand, you can treat the problem as fixed.
On the other hand, Dapper is still a supported platform, where the problem exists. But I don't know what the Ubuntu development guidelines say about fixing problems in an old distribution.

For Dapper:
>Does it work if roaming is turned on?
I'm not aware of any roaming with Dapper.
>Does this seem to affect a particular network card?
No, because the new hardware behaves the same when booting Dapper.
>What is the DHCP server?
I found no mention of it in /var/log/ or the lease file. How to tell?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.