WAN DHCP Lease Status

Started by DanMc85, February 22, 2018, 07:04:08 PM

Previous topic - Next topic
Is there a spot that shows the date and time a WAN DHCP release is up and will renew?  I looked in the interfaces -> Overview section of the dashboard but didn't see anything.

Thanks

February 23, 2018, 09:13:15 AM #1 Last Edit: February 23, 2018, 10:00:46 AM by seamus
Your WAN interface is the client. As I understand the DHCP process, the client must know when his lease expires as it's the client's responsibility to reach out to the server before lease expiration, and request a renewal. But as the lease expiration time isn't shown in the WAN interface page, I don't think this is something that's provided in the GUI. But it's gotta' be in the system somewhere -  I'd hazard a guess that it's in the dhclient.leases database.

And FWIW, there is an "Advanced" tab for DHCP Client configuration under the Interfaces->WAN menu, but it doesn't seem to offer an answer to your question. You might want to have a look at it though - may give you some ideas.

February 23, 2018, 12:24:44 PM #2 Last Edit: February 23, 2018, 12:28:41 PM by marjohn56
It's handled by dhclient, providing you're not using pppoe, in which case it's handled by that.

If it's handled by dhclient, then the only place you'll see it is in the dhcpd logs, look for dhclient entries as shown here.

This is from my sub ( test ) router which gets its address from the primary router. You can see the renewal time is 3600 seconds, and sure enough, it renews 1 hour later.

OPNsense 25.7a - Qotom Q355G4 - ISP - Squirrel 1Gbps.

Team Rebellion Member