feat(unbound): add prometheus exporter, dashboard, fix socket buffer sysctl

This commit is contained in:
Clément Désiles
2026-09-06 23:44:05 +02:00
parent 304a3fae12
commit ed5d0c68f1
11 changed files with 290 additions and 3 deletions
+25
View File
@@ -1,3 +1,28 @@
# Metrics (Prometheus)
Set `unbound_exporter_enabled: true` in inventory/host_vars. This enables
`remote-control` (no TLS, loopback only) and deploys `prometheus-unbound-exporter`
(Arch Linux only), which scrapes `unbound-control stats_noreset` on
`127.0.0.1:9167`.
Verify:
```sh
curl -s 127.0.0.1:9167/metrics | grep '^unbound_up'
```
Add a scrape job in `prometheus_scrape_configs`:
```yaml
- job_name: 'unbound'
static_configs:
- targets: ['localhost:9167']
```
Key QoS metrics: cache hit ratio (`unbound_cache_hit_rate` or
`num.cachehits`/`num.cachemiss`), recursion latency (`num.query.time.avg/median`),
requestlist backlog, and `num.answer.rcode.SERVFAIL` failure rate.
# Testing
## DNS leaks