RouterOS monitoring: mktxp exporter for rb5009-a/b + crs309, retire ER-X SNMP probe #139
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
lab/iac#139
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of #43.
Problem
Since the ER-X swap there is no working router monitoring.
flux-clusters/clusters/mini/monitoring/resources/scrapes/router-scrape.yaml(and theportablecopy) still probe10.15.1.1with theubnt_routerSNMP module. That address is now the RB5009 VRRP address, the routeros roots configure no SNMP, and RouterOS lacks most of the UCD-SNMP tables that module walks. Not yet checked in VictoriaMetrics whether the probe returns errors or partial data.Proposal
Deploy akpw/mktxp (RouterOS API exporter, Python, GPL-2) on mini, one entry per device: rb5009-a, rb5009-b, crs309. Scrape all three individually (not the VRRP address, which hides which router answered).
Router side (iac, routeros roots):
monitoringuser per device (policyread,apionly;api-sslservice, address-restricted to mini's addresses). Mind the 7.25 findings:service=on groups is a no-op, the policy set is the gate.api-sslbound to the OpenBao www-ssl leaf (ADR-0009), so the exporter verifies with the lab root CA (ssl_ca_file), nossl_certificate_verify=False.secret/routeros-secrets, ESO-synced as one secret per device, mounted as mktxp'scredentials_fileYAML (keeps secrets out ofmktxp.conf).Cluster side (flux-clusters):
clusters/mini/monitoring, image pinned.ubnt_routerVMProbe (mini + portable) and the SNMP module once the new scrape has data.Collectors worth turning on
firewallwith matching-only off: by default mktxp drops rules with 0 bytes (datasource/firewall_ds.py), so "catch-all drop stopped counting" or "rule never fires" can't be alerted on. Series are labelled by comment, so our[tf:<key>]comments become stable rule identities (#67 convention).bgp+routing_stats: session state to the Cilium peers, plus advertised-prefix counts per peer (count-onlyon/routing/bgp/advertisements). For #125, alert if advertised count to a Cilium peer is ever non-zero.netwatch: the rollback fuse's probes (#74), and VRRP failover visibility for #128.health,monitor(SFP DDM where the optics report it),poe,interface,public_ip(PPPoE IP changes on failover),dhcp(leases live on the VRRP master only: scrape both, join on MAC),certificate(www-ssl leaf expiry as a backstop to the renewal path),routerboard+package(firmware/upgrade pending, feeds #71).Done when
Pattern review that led here:
docs/routeros/notes/2026-11-17-mktxp-patterns.md§7 (PR #134).Cluster scaffold: lab/clusters#1715 (draft). Merge only after the router side exists: monitoring user, api-ssl bound to the OpenBao leaf, *_MONITORING_PASSWORD keys in secret/routeros-secrets. mktxp 2.1.0 hard-codes firewall matching-only (zero-byte rules emit no series), so the 'catch-all drop counter flat' alert needs an upstream option or a patch.
Live 2026-11-17. mktxp on mini scrapes rb5009-a, rb5009-b and crs309 over api-ssl with verified TLS (vmagent job mini-mktxp up, ~2100 samples). Router side: iac#143 (two-slot users monitoring-a/-b, read,api only, from 10.44.0.0/16; Terraform writes OpenBao, then the router, then active; ADR-0011). Provider fork 1.99.1004 (password_wo). Cluster side: clusters#1715 (exporter, old ER-X SNMP probe removed), #1717, #1720, #1721. Rollout: router objects suspended, openbao-config applied the policies first, then rb5009-b, rb5009-a, crs309 one at a time; no fuse left armed. Remaining for done-when: alerts and dashboards; firewall zero-byte rules still emit no series (mktxp 2.1.0 hard-codes matching-only).
Monitoring is live (see the previous comment). Alerts and dashboard continue in lab/clusters#; zero-byte firewall rules in lab/iac#.