Manually delete/remove a DHCP lease?

Hello, Is it possible to manually delete/remove a DHCP lease without rebooting the device?

This specifically pertains to passthrough mode where we have a RUT assigning the static public IP to our downstream client/device. It would be nice if we could disconnect the ethernet cable between the LAN port on the RUT and the downstream client/device, remotely (via web interface or RMS) remove the DHCP lease, then connect our laptop to RUT LAN port and have the public IP assigned (without having to first reboot the device to clear the existing lease). Likewise, this would save having to reboot RUT again when we reconnect the main downstream client/device (in order for it to get the static public IP).

Thank you.


To delete the existing DHCP leases from the device, the file /tmp/dhcp.leases can be altered or deleted. Afterward, a restart of the network will most likely be needed. This can be done by using the command /etc/init.d/network restart.
More information can be found here: [OpenWrt Wiki] DNS and DHCP configuration /etc/config/dhcp

Best regards,

I’ll give this a try. Thank you

1 Like

This topic was automatically closed after 15 days. New replies are no longer allowed.