This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
retain_dhcp_lease_info_after_a_reboot [2023/05/24 02:29] – hogwild | retain_dhcp_lease_info_after_a_reboot [2023/08/09 15:39] – [Method 2: Copying the lease database to permanent storage at halt time] -clarify Method 2 uses both sets of lines hogwild | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Retain DHCP Lease Information after a Reboot ====== | ====== Retain DHCP Lease Information after a Reboot ====== | ||
- | By default, dnsmasq stores DHCP lease information | + | By default, dnsmasq stores DHCP lease data in (volatile) |
- | There are currently two options to resolve | + | There are currently two common methods for dealing with this. |
- | - Navigate to [[: | ||
- | - <code -> | ||
- | dhcp-leasefile=/ | ||
- | </ | ||
- | Use a path relative to your own system. | + | ===== Method 1: Store the lease database on permanent storage ===== |
- | The idea is essentially | + | The first method does not use scripting. The goal of the first method |
\\ | \\ | ||
- | 2) A different approach is to keep the lease database in its default location and copy it to permanent storage at " | + | - Under Advanced, go to the [[advanced-dhcpdns|DHCP/ |
+ | dhcp-leasefile=/ | ||
+ | </ | ||
+ | - Use a path relative to your own system. | ||
+ | - Using permanent storage means client devices won't lose connectivity if the router reboots. Because the lease database is not stored in RAM, a reboot won't erase it. This can be useful, for example, when devices are connected to a switch. Moreover, clients won't display in the [[status-devices|Device List]] as having an active lease until their current lease expires, and they' | ||
+ | - You will notice that the example points to a USB device labelled " | ||
+ | |||
+ | |||
+ | ===== Method 2: Copying the lease database to permanent storage at halt time ===== | ||
+ | |||
+ | \\ The second | ||
- | Administration/ | + | \\ \\ For example, in the Init field in the [[admin-scripts|Scripts]] menu, enter:\\ |
<code -> | <code -> | ||
Line 31: | Line 37: | ||
</ | </ | ||
- | Administration/Scripts/Halt\\ | + | \\ |
+ | |||
+ | \\ | ||
+ | |||
+ | in the //Halt// field In the [[admin-scripts|Scripts]] menu, enter:\\ | ||
<code -> | <code -> | ||
Line 37: | Line 47: | ||
</ | </ | ||
- | This method | + | \\ |
+ | |||
+ | \\ | ||
+ | |||
+ | Method | ||
+ | |||
+ | \\ | ||
+ | |||
+ | \\ | ||