Monitoring a small server without a dashboard habit

You do not need twenty graphs. You need three questions answered automatically.

Daniel RenInfrastructure
· · 2 min read

Monitoring tools love dashboards, and dashboards love attention. For a small server, most of that attention is wasted. What you really want is to be told — rarely and clearly — when something needs you.

Three questions

  1. Is it reachable from the outside?
  2. Is the disk going to fill up this week?
  3. Did last night's backup finish?

A tiny script run by cron can answer all three and send a message only when an answer changes. Everything else can wait for the occasional look at the logs.

# warn when the root filesystem is more than 85% full
use=$(df --output=pcent / | tail -1 | tr -dc 0-9)
[ "$use" -gt 85 ] && echo "disk at ${use}%" | mail -s "disk" you@example.org
Daniel RenInfrastructure at Bet on Future

Looks after small servers and writes down everything that broke along the way.