Dhcp.leases manually edit

Simon dhcp1 at thehobsons.co.uk
Sat Mar 12 16:41:11 UTC 2022


JT ISC <jtisc88 at gmail.com> wrote:

> However, I have been wondering if you can stop dhcpd service and add in a new lease the very end of the dhcpd.leases file using the correct format for lease start and end times as well as the MAC address.  Then start the dhcpd service again and the dhcpd server update the lease that you just manually created with any new updated information.

Yes, it’s something I’ve done when I’ve had special requirements - e.g. creating a new reserved lease for a device.

From memory you might not even need times - it’s sufficient to create a skeleton entry with the IP address, the MAC address or Client-ID the device will use, and in my case, the “reserved” flag. When the client contacts the server, the server will fill everything else in as required.

Simon



More information about the dhcp-users mailing list