update snmp exporter

This commit is contained in:
2026-05-18 22:32:13 -05:00
parent a7f77514d6
commit 39b7b91f45

View File

@@ -2,17 +2,8 @@
# SNMP Exporter # SNMP Exporter
# Scrapes UniFi network devices via SNMP v2c. # Scrapes UniFi network devices via SNMP v2c.
# Uses multi-target pattern — Prometheus passes device IP as a param. # Uses multi-target pattern — Prometheus passes device IP as a param.
# # Config format: v0.26.0+ (auth-split format)
# Devices:
# - world-drive (UDM Pro) 192.168.1.1
# - usw-pro-agg (USW-Pro-Agg) 192.168.1.123
# - usw-pro-max-24 (USW-Pro-Max-24) 192.168.1.226
# - usw-lite-16-poe (USW-Lite-16) 192.168.1.136
# - ups-tower (UPS-Tower) 192.168.1.233
# ------------------------------------------------------------------------------ # ------------------------------------------------------------------------------
# SNMP exporter config — if_mib module with community from secret
# Uses an init container to inject the community string at runtime
apiVersion: v1 apiVersion: v1
kind: ConfigMap kind: ConfigMap
metadata: metadata:
@@ -27,8 +18,13 @@ data:
modules: modules:
if_mib: if_mib:
walk: walk:
- interfaces - 1.3.6.1.2.1.2.2.1.1 # ifIndex
auth: mk_labs_v2c - 1.3.6.1.2.1.2.2.1.2 # ifDescr
- 1.3.6.1.2.1.2.2.1.8 # ifOperStatus
- 1.3.6.1.2.1.2.2.1.10 # ifInOctets
- 1.3.6.1.2.1.2.2.1.16 # ifOutOctets
- 1.3.6.1.2.1.2.2.1.14 # ifInErrors
- 1.3.6.1.2.1.2.2.1.20 # ifOutErrors
metrics: metrics:
- name: ifIndex - name: ifIndex
oid: 1.3.6.1.2.1.2.2.1.1 oid: 1.3.6.1.2.1.2.2.1.1