Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

On our DHCP server, the lease time is currently set to infinite.

I want to switch it over to 8 days, but from what i understand the clients do not do a DHCP renew if they have infinite lease.

Will a machine do the whole DHCP handshake even if it has an infinite lease?

share|improve this question

3 Answers 3

up vote 2 down vote accepted

When computer boots up, it does the whole DHCP handshake. And when half the lease time expires, the DHCP client requests for renewing the ip address. And at the end of the lease time, it requests again and if fails, it restarts the entire DHCP cycle and sees if any new servers respond to its DHCP request.

And if the lease time is infinite, and if the DHCP client does not go down, it does not have to renew, but if it has gone down for some time and booted up, it restarts the DHCP handshake.

So, to answer your question, yes, it does the whole DHCP handshake with the server to get ip address after booting.

share|improve this answer
    
Thanks for the reply..i'll make the change and post back what i find out... –  Bruno Mar 2 '12 at 17:25

I don't agree with the accepted answer.

A DHCP client that has an ip address for which the lease has not yet expired or is not in the renewal phase does not go through the DORA process upon reboot. The DHCP client will request to continue using it's currently leased ip address. Furthermore, a DHCP client attempting to renew it's currently leased ip address does not go through the DORA process. If that's what you and Mallik are referring to when you mention "DHCP handshake", then that's wrong.

Although I've never seen the scenario you describe I'm assuming that the DHCP client would get the new ip address lease time upon reboot when it recieves the ACK from the server to it's request to continue using the currently leased ip address.

For a client that doesn't currently have a an ip address the DHCP process is as such:

D = Discover O = Offer R = Request A = Acknowledge

For a client that currently has a valid ip address for which the lease has not yet expired the process is as such:

R = Request (to continue using the currently leased ip address) A = Acknowledge

share|improve this answer
    
I would say that depends on the client. If the OS is started first, before IP is setup and the client does cache its DHCP-lease on disk, and the client is configured to use that cache, then you are right. –  Nils Mar 2 '12 at 21:50
    
Most (nearly all?) clients will perform a release as part of their interface downing routine. So rebooting or downing the interface should work. Unless infinite is a special case, I've never actually seen it used. –  Scott Pack Mar 4 '12 at 13:24
    
Windows clients don't release their ip address on a reboot or a power off. Furthermore, If they did what would be the purpose of the lease time, whether it was 1 minute or 1 year? –  joeqwerty Mar 4 '12 at 14:36

Booting the computer will to a DHCP refresh. If you don't want to reboot, you can bounce the network interface, or explicitly ask the PC to refresh.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.