Ping to trigger either DHCP renew or interface restart

Hi Everyone,

In advance I apologize if this is a duplicate topic - Unfortunately, I wasn't really sure how to articulate the feature I'm looking for and as such wasn't really sure what to search for.

I'm in Australia using the NBN with HFC (cable), I use OpenWRT OpenWrt 21.02.1 in a x86 libvirt VM. To use this NBN link, I only need request an address with DHCP and then I can use that address to route public traffic. That address will be usable for anything between 3 hours and a month. In an unpredictable time frame the cable modem will stop routing traffic (see no return traffic) and it will sit there until I restart the interface (which I imagine is just bouncing the interface and requesting a new address on the way back up). Once again my connection will continue to route traffic as desired.

I was wondering if anyone knew of a service/plugin/feature I can use to automate this - using some kind of probe or passive monitor to determine if the interface is not routing traffic and then attempt to renew the address?

Best Regards,
David Balnaves

DHCP should nominally renew the lease without issue, but yes, if you are having problems with that, you probably need a mechanism to bounce the port.

Check out Watchcat which is a watchdog that can trigger actions based on things like an upstream network failure.

1 Like

Hi psherman,

Thanks for this excellent response, this was EXACTLY what I was looking for. It's really great that it is integrated with luci too!

Don't suppose you know of a IPv6 solution too? The NBN uses DHCPv6 to obtain a prefix but not a specific address.

Glad I could help. I can't help on IPv6, but maybe others on the forum will have some ideas.

1 Like

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.