E
E
Evgeny Serdyukov2017-05-24 14:36:47
ubuntu
Evgeny Serdyukov, 2017-05-24 14:36:47

A cron script that would check the site loading every minute, and if the site does not open by timeout, then execute the command?

How to properly write a cron script to check if the site is down. And if the site hangs, i.e. the page does not load by timeout, then execute a specific command, for example, reboot. I want to check every minute.
Ubuntu Server 16.04 system.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
Erelecano Oioraen, 2017-05-24
@Erelecano

man cron
man curl
man bash
man sudo
And, yes, there are ready-made monitoring systems for such purposes, including those capable of executing commands when a trigger is triggered, there is no need to give birth to a mixture of a hedgehog with a snake and a bicycle.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question