0

I have a computer running windows 10 that does some operations for me remotely, but for some reason it randomly disconnects, and the only solution I have found is to restart the computer. Re-establishing the connection doesn't work most of the times. Is there a way for me to restart my this computer automatically whenever it disconnects from the internet?

0

2 Answers 2

0
ping 8.8.8.8 | find "TTL=" || shutdown /r /f /t 0

Put this into Task Scheduler (or save as .BAT-file and shedule it), and set it to execute, for example, each minute.

0

You can perform a task using task scheduler upon disconnect. You can set this as a trigger. This way you can execute this without any checks.

The command to execute is Shutdown, the parameters are /r /f /t 0.

Do note, if you normally disconnect the pc, it will also reboot the machine.

Not the answer you're looking for? Browse other questions tagged .