Automatically cable reboot modem when Internet is down

I have the same setup and the same problem. It’s quite fresh for me because the past two days Comcast has been a total piece of crap, going in and out all day. My setup works like this:

  • Created a Ping sensor to check the internet
  • When it goes down for more than 5 minutes (indicating an outage) then it enables a “restart” automation that will turn off the smart plug the modem is connected to for 30 seconds and then power it back on again
  • The automation restarts the modem up to 6 times, with a repeat for every 5 minutes (so 30 minutes total) to see if it comes up. Each time it does that it increments a Helper with how many restarts have been attempted.
  • If it’s still down then the 5 minute restart automation is disabled and the 15 minute restart automation begins, again incrementing the helper up to 16 times.
  • If it’s still down then the 15 minute automaton is disabled and a 30 minute automation runs until it comes up again
  • When it comes up the helper is set back to zero (I call it Comcast Restart Count), all restart automations are disabled and it is back to normal
  • During each step I use persistent notifications so I know what is happening and at what frequency

I used to just restart the modem in perpetuity but I would sometimes get into strange issues where the modem might take more than 5 minutes to come back up and just get restarted again, resulting in never having my Internet back until I stopped the madness. This new system has been rock solid for me. The biggest reason I wanted such an elaborate system is because I’m often out of town in my RV and cannot afford to have the Internet down at the house.

1 Like