cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
12395
Views
0
Helpful
3
Replies

DHCP how to use "ip dhcp binding cleanup interval" command

jose cortes
Level 1
Level 1

Hi everybody,

My ISP is using its router as the DHCP Server. Before, the branch office, has only one LAN segment and one IP segment indeed. Now the LAN is segmented into VLANs and the DHCP was fragmented into different pools.

Above all the VLANs there is one thar is the GUEST VLAN and the user rotation level for this vlan is the highest compared with the rest of the vlans. The guests come to the office connect to a WLAN attached to the GUEST VLAN and they get an IP. Once the Guest users exits the WLAN domain and has no connection the IP that this user got before is not release by DHCP until the Lease period expire (for my case 8 days) and the pool run out of IPs in about half day.

I request the ISP that reduce the lease time for this Pool to about 4 hours, but the ISP says it could affect the router performance. I was looking information for this command "ip dhcp binding cleanup interval [seconds]" but there is no reference about on cisco.com or the IOS command Guides.

I guess this command release all the bindings according to the interval configured wether the lease is 4 hours or 4 days, so my problem will be solve. I need you to check with you the experts how does this command actually works.

Jose Manuel Cortes Hurtado

3 Replies 3

schooram
Level 1
Level 1
hello jose,

Your understanding of the command "ip dhcp binding cleanup interval 600"
is correct. This command will remove the expired bindings after lease
time. The start of the cleanup interval value is normally set within
<10-600 seconds>

This  feature is IOS release and platform dependent.

Best Regards,

Sandeep

hi Sandeep,

I have this question: The will this command remover the Bindings BEFORE the lease time expires??

i.e:

I get connected to the WLAN and the DHCP server (router) give me the IP:192.168.0.23/24 and the DHCP is configured to lease the IPs for 8 days. The command in discusion (ip dhcp binding cleanup interval 300) is configured too.

If I remain on the WLAN for only 2 hours, and then I get disconnected, the IP 192.168.0.23/24 will be released from the Binding Table because of the ip dhcp binding cleanup interval 300 and another computer will take it, and If I return to the WLAN will I be assigned to another IP address, a new one?

(Notice that in the example above the Lease time has not expired yet, in fact there is a lease time of 7 days and 22 hours until the Lease Expires.)

Thanks and Regards.

Jose

Hi Jose,

This command will not remove the bindings before its expiration.

-Basically, DHCP keeps a cycle of 'x' seconds in order to check for expired bindings['x' being configured by the "ip dhcp binding cleanup inter" cmd]

-So when a lease expires, it is not automatically removed by DHCP right after the expiration time.

-Only during the next cleanup cycle, DHCP will remove  the expired bindings. The cleanup cycle is being configured by the above mentioned command.

If I remain on the WLAN for only 2 hours, and then I get disconnected, the IP 192.168.0.23/24 will be released from the Binding Table because of the ip dhcp binding cleanup interval 300 and another computer will take it, and If I return to the WLAN will I be assigned to another IP address, a new one?

(Notice that in the example above the Lease time has not expired yet, in fact there is a lease time of 7 days and 22 hours until the Lease Expires.)

- This would really depend on whether the PC releases the IP before getting disconnected.If the DHCP release message is sent the binding should

be removed from the table allowing another device to use the IP. Otherwise until the lease time expires the binding is present.

Regards,

Subramaniya Karthic.R