Quote:
Originally Posted by compurandom
You'd think that, and you might think that restarting both the router and the device would make both forget the address. But either one can retain associations, and when a device renews its address, it can re-request the old one even if the router's dhcp server has forgotten and the device has been rebooted.
|
True, anything that acts as a DHCP client can chose to store the lease across restarts. And ask for it when they restart. Whether they get it is another thing. But, they also shouldn't assume they still own the address. But, I'm sure there are devices that do assume this.
Having a look at my Aura ONE, it is storing the leases (in "/var/db/dhcpcd-eth0-*.lease" with one file per WiFi network). When connecting, it is reading this and sending a request. But, it doesn't look like it will keep using the address if it doesn't get a response that it can.
Quote:
At that point, it's up to the dhcp server to decide if it will reissue the old address or give the new address. A good dhcp server would attempt to ping the old address before reissuing it. Sometimes the only way to force the address to change is to ban the dhcp server from passing it out somehow.
|
Pinging an address isn't a particularly good method to decide if an address is in use. Or, more accurately, that an address is
not in use. Far to many server/routers/devices won't respond. And the main DHCP servers I deal with wouldn't actually be able to see the devices they are issuing addresses for. The requests are being proxied through a router.