What's new

YazDHCP WebGUI "DHCP Lease" Input Field Changes

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!


Senior Member
I've ported over some of the shell script & JavaScript code that I initially wrote for YazFi to YazDHCP so that its WebGUI input field for "DHCP Lease" is more user-friendly (for some context/background see this thread here).

This is a summary of the new changes:

1) Maximum DHCP Lease Time is 90 days (minimum lease is the same as before: 2 minutes).

2) You can now enter the "DHCP Lease" value in seconds (e.g. 86400s), minutes (e.g. 720m), hours (e.g. 24h), days (e.g. 10d), or weeks (e.g. 2w). Only positive integer values are allowed so "24.5h" or "2.5d" are *not* valid input. If none of the valid suffixes is given (s, m, h, d, w), the default unit is seconds, so this new change is backward compatible with previously valid settings.

3) Simple mechanism to set an "infinite" DHCP Lease Time value by allowing a single upper-case letter 'I' or a single digit ZERO '0' entry in the WebGUI to indicate that the user wants to set an "infinite" lease time.

Here are example screenshots:

NVRAM setting is then updated accordingly (always in seconds):

I will submit a GitHub PR to @JackYaz so he can review the code changes & merge them into the Develop branch if he agrees with the modifications.


  • RT-AC86U_YazDHCP_WebGUI_LeaseTime.jpg
    98.8 KB · Views: 39
@JackYaz has merged my latest changes into the YazDHCP "1.0.5" Develop branch.

If you want to switch from the current "1.0.4" Master branch to the new "1.0.5" Develop branch type the following commands in a CLI terminal window:
/jffs/scripts/YazDHCP develop
/jffs/scripts/YazDHCP startup


Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!