dhcp server giving out new IPs on reboot

Simon Hobson dhcp1 at thehobsons.co.uk
Wed Feb 29 21:52:36 UTC 2012


Gregory Machin wrote:

>I have a legacy dhcpd 3.0.1 server.

That's more than a tad old !

>Users complain that when they reboot machines they get a new ip each 
>time .. Some of these machines are rebooted 5 times a day as part of 
>testing. This seems to happen once the lease range if full or almost 
>full , is this normal behavior ? I see no errors in the log files.

it may be. If your range is getting quite full, then it's possible 
you are hitting a situation where you reboot a load of machines, 
there aren't any free leases, and so old ones are re-allocated. The 
machine that had the lease 1/2 hour ago now cannot have it's old 
address so it gets one that had been used for another machine. And so 
it goes on.

It will be especially bad if you are multibooting with different 
client IDs*, as may be the case when machines have a net boot 
facility turned on. In this case, the netboot client will need an 
address and it won't match an existing one - because it's long enough 
since the machine last booted that it's lease is long since expired 
and reused. So it definitely reuses another old lease and so triggers 
the round of A gets B's old lease, B gets C's old lease, C gets ....

You really need to have enough spare leases to satisfy all the 
clients at once - and that may mean 2 or even 3 addresses per 
physical machine is you are using PXE (or even have it turned on on 
the clients).


* If client supplies a client ID then that is used as the primary 
key. If no client ID is supplied, then the fallback is to use the MAC 
address. If a client boots with different client IDs, or boots with 
and without one, then it is classed as different clients by the 
server.

-- 
Simon Hobson

Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.


More information about the dhcp-users mailing list