udhcpd initial lease
Denys Vlasenko
vda.linux at googlemail.com
Sat Nov 27 21:46:23 UTC 2010
On Friday 26 November 2010 23:04, Dan Fandrich wrote:
> On Sat, Nov 27, 2010 at 08:48:09AM +1100, Grahame Jordan wrote:
> > In this case only one client ever connects to the USB port.
> > Otherwise what else can you do? Maybe accept the requested lease if
> > it is not already taken?
>
> Yes, exactly. If the server is going to provide an address anyway
> (eventually) and the suggested one is valid, why not give the client what
> it wants?
That's what we do:
When we receive DISCOVER packet, we retrieve "requested IP",
put it into the lease table for 60 seconds,
put it into packet.yiaddr and send the reply.
When we later get REQUEST packet, we find "requested IP"
in lease table and therefore ACK this REQUEST.
This is how it supposed to work.
We need to understand why it doesn't work.
tcpdump output would be very useful to see.
--
vda
More information about the busybox
mailing list