A simple watchdog service for ASUS Merlin firmware.
The script checks pings against the default gateway received from your ISP.
If a ping times out, it attempts to ping the default gateway 5 more times. If no response is received from the default gateway after 5 times, it kills the dhcpc service and forces a reconnect of the WAN interface.
- Login to the router configuration page
- In the
Administration --> Systemmenu, enableSSHand theEnable JFFS custom scripts and configsoptions.
- Upload the
services-startandmerlinwatchdog.shto/jffs/scripts - In the SSH terminal, run:
chmod a+x /jffs/scripts/merlinwatchdog.sh /jffs/scripts/services-start; /jffs/scripts/services-start - You're done!
This script is based on https://github.com/elislusarczyk/merlin-wan-watchdog with adaptations.

