Introduction
While the Ubiquiti Unifi interface provides a great overview of your network, it lacks the deep, long-term metric retention and granular visualization capabilities of a dedicated monitoring stack. To bridge this gap, I integrated Unpoller (formerly UniFi-Poller) into my Home Lab’s Prometheus and Grafana ecosystem.
The Architecture
Unpoller acts as a data bridge. It polls the Unifi Controller’s API and exports the data in a format that Prometheus can easily ingest.
1. Secure Credential Management
Since my Home Lab configuration is managed via GitOps, security is paramount. I used Bitnami SealedSecrets to store my Unifi read-only credentials. This allows me to commit the encrypted secret to my public repository safely.
2. Deployment and Service Discovery
I deployed Unpoller as a lightweight container in my monitoring namespace. To automate the metrics collection, I used a ServiceMonitor resource:
1
2
3
4
5
6
7
8
9
10
11
12
13
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: unpoller
labels:
release: grafana-prometheus-monitoring
spec:
selector:
matchLabels:
app: unpoller
endpoints:
- port: metrics
interval: 30s
By adding the release label, the Prometheus Operator automatically discovers the new target and begins scraping.
The Results
With Unpoller running, I now have access to:
- Per-client bandwidth usage over months, not just hours.
- Detailed USG telemetry, including CPU load, memory, and WAN latency.
- Port-level stats for all my Unifi switches.
All of this data is visualized in Grafana (using the excellent Dashboard ID 11310), giving me a single pane of glass for both my Kubernetes cluster and my physical network infrastructure.
Conclusion
Unpoller is a must-have for any Unifi user running a Prometheus stack. It turns your network into a measurable, observable component of your lab, allowing for better troubleshooting and capacity planning.