Is there a way to perform a DHCP Release/Renew under certain circumstances on WAN?
-
I have a Dual-WAN failover currently set up as follows:
WAN 1 - 2.5 Gbps Synchronous fibre as my main link
WAN 2 - 1 Gbps/100Mbps Cable modem as failover.A few weeks ago my fibre ISP did a firmware update on my modem in the middle of the night. It's set to bridge mode. When it came back up, it first went into a "default" 192.168 router mode, it then switched to transparent/bridge mode. pfSense latched onto the 192.168.1.1 address first and went on happy with it, but of course, pinging the test target and failing. The DHCP lease from my ISP is rather large and would take days to "repair itself."
I'd like to figure out if I could set up a script to effectively check if WAN 1 receives an IANA unroutable address via DHCP release/renew the IP address. Say check every 10 minutes or so. Or even blast me on Pushover, etc. via the other link.
The system performed as it should, but I missed the alerts and was somewhat surprised that it had occurred. No complaints from the "users" during the failover, so in that case it was a success!
-
@bcinbc Interfaces/WAN. Look for "reject leases from" setting. Put in the IS P's routers address and it won't receive an address from them anymore.
-
@jarhead Thank you!
This should do the trick!
I don't recall seeing this feature! Likely at the time, I was poring over the features, I probably went, "I've never seen that happen before, so why would it be important?"
I've just done the typical, "192.168.0.1,192.168.0.254,192.168.1.1,192.168.1.254" Those are the only two ranges I've seen this modem do.
Also, the blocking of private networks is on anyways. It would be helpful to auto-enable the entire range to respond to DHCP if you have this on and have it throw an error. Perhaps have it highlighted in the gateway listing? Why should you get an address in the private network range if you've blocked them?
How many people enable this and pull their hair out for hours (usually the new users I see on YT doing initial videos inside their lab) trying to figure out why it doesn't work?
-
@bcinbc No need for the entire range. It blocks dhcp servers, so the range would already be blocked.
-
@jarhead I didn't do a range, I couldn't remember if it assigns 1 or 254 as the router, so I just did both, for each subnet I've seen.
You are correct, I did use the word "range", but I meant to "cover those two ranges for possible router addresses". Sorry for the confusion.