RE: NM 0.6.5 and dhcp behavior



I think I may have found an existing bug as well.  Here is the scenario I
saw:

1. Wired Connection Activate on bootup and DHCP address obtained properly.
2. Renewal continued successfully for some period of time.
3. Renewal failed and did not obtain new IP.
4. Original IP still assigned to eth0.
5. Next day original IP given out by the DHCP server to a different PC and
IP address collisions result.

I assume this is incorrect behavior and when the renewal failed the IP
should have been withdrawn.  I also don't know if this is a NM bug or a dhcp
bug.

Here is the relevant log:

Jan 21 23:25:58 gem240 dhclient: DHCPREQUEST on eth0 to 192.168.2.55 port 67
Jan 21 23:25:58 gem240 dhclient: DHCPACK from 192.168.2.55
Jan 21 23:25:58 gem240 NetworkManager: <info>  DHCP daemon state is now 3
(renew) for interface eth0 
Jan 21 23:25:58 gem240 dhclient: bound to 192.168.2.240 -- renewal in 145
seconds.
Jan 21 23:28:23 gem240 dhclient: DHCPREQUEST on eth0 to 192.168.2.55 port 67
Jan 21 23:29:03 gem240 last message repeated 5 times
Jan 21 23:30:05 gem240 last message repeated 5 times
Jan 21 23:30:19 gem240 dhclient: DHCPREQUEST on eth0 to 192.168.2.55 port 67
Jan 21 23:30:26 gem240 dhclient: DHCPREQUEST on eth0 to 255.255.255.255 port
67
Jan 21 23:30:43 gem240 last message repeated 2 times
Jan 21 23:30:59 gem240 NetworkManager: <info>  DHCP daemon state is now 10
(unknown) for interface eth0 
Jan 21 23:30:59 gem240 NetworkManager: <info>  DHCP daemon state is now 1
(starting) for interface eth0 
Jan 21 23:30:59 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 3
Jan 21 23:31:02 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 5
Jan 21 23:31:07 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 5
Jan 21 23:31:12 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 10
Jan 21 23:31:22 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 11
Jan 21 23:31:33 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 15
Jan 21 23:31:48 gem240 dhclient: DHCPDISCOVER on eth0 to 255.255.255.255
port 67 interval 12
Jan 21 23:32:00 gem240 dhclient: No DHCPOFFERS received.
Jan 21 23:32:00 gem240 dhcdbd: Unrequested down ?:3
Jan 21 23:32:00 gem240 NetworkManager: <info>  DHCP daemon state is now 14
(normal exit) for interface eth0

-----Original Message-----
From: Dan Williams [mailto:dcbw redhat com] 
Sent: Wednesday, January 23, 2008 12:11 PM
To: Philip A. Culver
Cc: networkmanager-list gnome org
Subject: RE: NM 0.6.5 and dhcp behavior

On Wed, 2008-01-23 at 12:03 -0500, Philip A. Culver wrote:
> I am creating an account and will file the RFE.
> 
> I might have to add this behavior to 0.6.5.  If I do I will post a patch
> when I am done.
> 
> Thanks for the info!

The approach I'd recommend is:

1) Let NM get an autoip address.  The original use-case for this was
plugging two laptops together, having it Just Work, and being able to
run gnome-user-share or whatever and share files back and forth.

2) Periodically (say, every 2 or 5 minutes) try another DHCP attempt,
and if that's successful, remove the autoip address and start using the
DHCP-returned configuration.  You could even try a backoff algorithm and
try more often at the start, but less often as time goes on.  You don't
want to spam a network that might be on the other side of the cable.

Dan

> -- Phil
> 
> -----Original Message-----
> From: Dan Williams [mailto:dcbw redhat com] 
> Sent: Wednesday, January 23, 2008 11:54 AM
> To: Philip A. Culver
> Cc: networkmanager-list gnome org
> Subject: Re: NM 0.6.5 and dhcp behavior
> 
> On Wed, 2008-01-23 at 11:00 -0500, Philip A. Culver wrote:
> > Hello,
> > 
> >  
> > 
> > What is NetworkManager's behavior if it can't get a IP address from
> > the DHCP server.   I see it seems to assign an auto IP 169...   Will 
> 
> Correct.  It will assign an IPv4 autoip address.
> 
> > keep talking to the DHCP server and try to get an IP?
> 
> No.  That might be a nice thing to try though.  Can you file an RFE on
> bugzilla.gnome.org for it?  If you don't have an account there then I'll
> file it I guess.
> 
> Dan
> 
> 
> 
> _______________________________________________
> NetworkManager-list mailing list
> NetworkManager-list gnome org
> http://mail.gnome.org/mailman/listinfo/networkmanager-list



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]