2018-06-08 02:33:45 +00:00
# Monitoring
Track resource utilization over time.
2018-10-19 21:55:06 +00:00
**BE MINDFUL OF RUNNING THIS. IT CAN CAUSE PROBLEMS WITH DISK IOPS AND RAM USAGE. BEST ONLY USED IF NEEDED OR YOU'RE TROUBLESHOOTING. If you would like to monitor CPU temperatures, we recommend installing [ArmbianMonitor ](armbianmonitor.md ).**
2018-06-08 02:33:45 +00:00
## cadvisor
[cadvisor (link) ](https://github.com/google/cadvisor ) has been recommended for monitoring Docker container resource usage. Could be useful.
Untested by the Author.
## Munin
Simple, efficient, old school, well supported. Start here.
Further reading : [http://munin-monitoring.org/ ](http://munin-monitoring.org/ )
### Install
``` bash
apt update
apt install munin munin-node \
munin-plugins-core munin-plugins-extra \
libcgi-fast-perl
systemctl enable munin-node
2018-09-17 23:12:53 +00:00
systemctl restart munin-node
2018-06-08 02:33:45 +00:00
```
### Serving Output Via Caddy
``` bash
cat > /etc/caddy/services/munin.conf < < EOF
# Munin - Static web resources
2019-01-15 20:38:28 +00:00
domain.tld/static {
tls user@domain.tld
2018-06-08 02:33:45 +00:00
redir 301 {
if {scheme} is http
/ https://domain.tld{uri}
}
root /etc/munin/static
}
# Munin - main site/cgi's
2019-01-15 20:38:28 +00:00
domain.tld {
tls user@domain.tld
2018-06-08 02:33:45 +00:00
redir 301 {
if {scheme} is http
/ https://domain.tld{uri}
}
log /var/log/caddy/test.kemonine.info.log
# Setup CGI rendering scripts
cgi /munin-cgi/munin-cgi-graph /usr/lib/munin/cgi/munin-cgi-graph
cgi /munin-cgi/munin-cgi-html /usr/lib/munin/cgi/munin-cgi-html
# Set path to generated HTML via cron/systemd processes
root /var/cache/munin/www
}
EOF
```