/go/uptime checks, once, every site and server in your list and tells you which ones do not answer. It: Every admin action in GoAdmio has a matching /go/ command, so anything you can click you can also script.
Quick start
# 1. List what to monitor, one entry per line
printf '%s\n' "https://example.com" "203.0.113.10" | sudo tee /var/go/etc/uptime
# 2. Run the checks
/go/uptime
Examples
# Run all checks once
/go/uptime
# Add a site to the list
echo "https://example.com" | sudo tee -a /var/go/etc/uptime
# Example crontab entry: every 5 minutes, never two runs at once
*/5 * * * * flock -n /var/lock/go-uptime.lock /go/uptime >/dev/null 2>&1
# Test one website by hand, the way the command does (1 or more = up)
curl -sL "https://example.com/index.php" | grep -c "</html>"
# Test one server by hand
nc -z 203.0.113.10 22 && echo open
Output
| Line | Meaning |
|---|---|
[<n>] Web Server is up: <url>... |
The website answered. |
[<n>] Web Server is down: <url>... |
Five attempts failed. An alert was sent. |
[<n>] Monitor is up: <host>... |
The server accepted a connection on port 22. |
[<n>] Monitor is down: <host>... |
Five attempts failed. An alert was sent. |
<entry>: Test Again <1-5> |
An attempt failed and another will follow after 12 seconds. |
<n> is the entry’s line number in the list.
[1] Web Server is up: https://example.com...
https://shop.example.net: Test Again 1
[2] Web Server is up: https://shop.example.net...
203.0.113.10: Test Again 1
203.0.113.10: Test Again 2
203.0.113.10: Test Again 3
203.0.113.10: Test Again 4
203.0.113.10: Test Again 5
[3] Monitor is down: 203.0.113.10...
The sample above is illustrative.
See the full reference at /go/uptime and the GoAdmio command index.
GoAdmio is free and open source, with no license fees and no account limits. Read the GoAdmio docs, or see why it is a free cPanel alternative at goadmio.com.
