Home Lab: Self-Hosted Monitoring Dashboard on Raspberry Pi 5¶
A self-hosted home lab is only as good as its monitoring system. When running multiple services like Nextcloud, Pi-hole, Home Assistant, or media servers, you need to know immediately when a service goes down or when your hardware is under stress.
This guide walks you through building a unified monitoring dashboard on a Raspberry Pi 5 using a modern stack: - Netdata: For real-time, low-overhead system and hardware metrics. - Uptime Kuma: For uptime monitoring of your services with a beautiful status page and instant notifications. - Prometheus & Grafana: For long-term historical metrics visualization.
We will deploy the entire stack containerized using Docker Compose and configure it for optimal performance on Raspberry Pi.
Architecture Overview¶
Step 1: Directory Structure and Prerequisites¶
First, ensure you have Docker and Docker Compose installed on your Raspberry Pi OS Bookworm. If you don't, run:
Create a dedicated directory structure for your monitoring stack configuration and data storage:
Step 2: Configure Prometheus¶
Prometheus needs a configuration file defining how often to scrape metrics and from which targets (in this case, Netdata).
Create the configuration file:
Add the following Prometheus configuration:
Step 3: Create the Docker Compose Stack¶
This single Docker Compose file will launch Netdata (with host metrics access), Prometheus, Grafana, and Uptime Kuma.
Create the file:
Add the following configuration:
Step 4: Deploying and Optimizing for Raspberry Pi¶
Start the stack:
Raspberry Pi 5 Optimization Notes:¶
- Disk Write Wear Reduction: Prometheus writes historical metric chunks to the disk. By setting
--storage.tsdb.retention.time=15d, we limit the size of database operations to avoid wearing out SD cards. If you run this long-term, booting from an NVMe SSD is highly recommended. - Docker Socket Mapping: Netdata is mapped to the host's
/var/run/docker.sock. This allows Netdata to automatically monitor CPU, memory, and network utilization for every other container running on your Raspberry Pi. - lm-sensors: We passed
NETDATA_EXTRA_DEB_PACKAGES=lm-sensorsto Netdata, allowing it to collect Raspberry Pi 5 board temperatures natively.
Step 5: Dashboard Configuration¶
1. Real-Time Resource Auditing (Netdata)¶
Open your browser and navigate to http://<your-pi-ip>:19999.
Netdata provides an incredibly detailed, zero-configuration dashboard showcasing:
- Real-time CPU core frequencies and temperatures.
- Network throughput across physical interfaces and Docker virtual bridges.
- Raw Disk read/write IOPS and swap usage.
2. Service Monitoring & Status Pages (Uptime Kuma)¶
Open your browser and navigate to http://<your-pi-ip>:3001.
1. Create your admin account.
2. Click Add New Monitor.
3. Choose monitor types:
- HTTP(s): Verify Web UI services (e.g. http://localhost:80 for your web server).
- Ping: Monitor router or other local network device latency.
- TCP Port: Verify if dockerized apps are alive (e.g., port 8123 for Home Assistant).
4. Go to Setup Notification and link it to Telegram, Discord Webhooks, Pushover, or email to receive instant alerts if services crash.
5. Create a public Status Page to visually list the uptime statistics of all your homelab apps.
3. Historical Visualizations (Grafana)¶
Open your browser and navigate to http://<your-pi-ip>:3000.
1. Log in with user admin and password admin (update the password immediately).
2. Go to Connections -> Data Sources -> Add data source -> Select Prometheus.
3. Set the Connection URL to: http://prometheus:9090 and click Save & Test.
4. To import a pre-configured system dashboard, hover over the + icon -> Import.
5. Input Dashboard ID 11159 (Netdata Linux System Overview) or 1860 (Node Exporter Full) to pull a beautiful pre-configured dashboard immediately from the Grafana community registry.
Troubleshooting & Maintenance¶
Check Container Statuses¶
View Logs for specific service (e.g. Prometheus)¶
Upgrading the Stack¶
To keep your tools secure and up-to-date, pull new images and restart the containers periodically:
By leveraging this unified monitoring system, you now have complete observability over your Raspberry Pi 5 homelab, securing maximum uptime for all your self-hosted apps.