From 503f3142f8e7d93c099f171a352d166af4935735 Mon Sep 17 00:00:00 2001 From: Ritika Chopra Date: Wed, 18 Mar 2026 11:29:59 -0700 Subject: T8382: DOC: Add details for VPP Prometheus Exporter under Monitoring --- docs/configuration/service/monitoring.md | 97 ++++++++++++++++++++++++++++++++ 1 file changed, 97 insertions(+) (limited to 'docs/configuration/service') diff --git a/docs/configuration/service/monitoring.md b/docs/configuration/service/monitoring.md index 49604918..b005bec4 100644 --- a/docs/configuration/service/monitoring.md +++ b/docs/configuration/service/monitoring.md @@ -561,6 +561,7 @@ run the following standalone Prometheus exporters: - Node Exporter - FRR Exporter +- VPP Exporter - Blackbox Exporter ### Node Exporter @@ -804,6 +805,101 @@ Example: set service monitoring prometheus frr-exporter collector detailed-routes ``` +### VPP Exporter + +Prometheus [vpp_exporter] is the `vpp_prometheus_export` utility shipped with +upstream {abbr}`VPP (Vector Packet Processing)`. Unlike the other exporters +in this section it is not a standalone project — it is built from the FD.io +VPP source tree. It connects to VPP's shared-memory stats segment via the +socket at `/run/vpp/stats.sock` and re-exposes the selected counters as a +Prometheus `/metrics` HTTP endpoint, using the v2 metric format. + +The exporter runs as a systemd service that is bound to the `vpp.service` +unit (`BindsTo` / `PartOf`): it cannot start until VPP is running, restarts +automatically when VPP restarts, and stops when VPP is stopped. It coexists +with `node-exporter`, which scrapes kernel/host metrics independently. + +VyOS does not provide a `listen-address` option for the VPP exporter. The +listen address is determined by the upstream VPP exporter. VyOS configures +only the port and optional VRF. + +VPP must already be configured under `set vpp ...` before the exporter can +be configured. Otherwise, the commit fails. + +Likewise, VPP cannot be removed while the exporter remains configured. +Remove `vpp-exporter` first. Otherwise, the commit fails. + +The set of exported counters is controlled by {cfgcmd}`stat-group`, which +selects one or more predefined top-level groups from the VPP stats +segment. If no group is selected, VyOS exports a default set covering +`interfaces`, `err`, `buffer-pools`, `system`, `workers` and `memory` (the +`nodes` group is excluded from the default — see the per-node-counters +note below). Explicitly selecting any group replaces this default set. + +```{cfgcmd} set service monitoring prometheus vpp-exporter port \ + +Configure the TCP port that the VPP exporter listens on for Prometheus +scrape requests. The default is `9482`. + +The selected port must be available in the configured VRF. A service +using the port in the target VRF prevents the configuration from being +committed. +``` + +```{cfgcmd} set service monitoring prometheus vpp-exporter stat-group \ + +Export one or more predefined VPP stat groups: + +| Group | Stats segment coverage | +| -------------- | --------------------------------------- | +| `interfaces` | All interface counters (`^/interfaces`) | +| `err` | All error counters (`^/err`) | +| `buffer-pools` | All buffer pool counters (`^/buffer-pools`) | +| `system` | A fixed set of system counters (see below) | +| `workers` | All worker counters (`^/workers`) | +| `nodes` | All node counters (`^/nodes`) | +| `memory` | Memory counters (`^/mem`) | +| `nat44` | A fixed set of NAT44 counters (see below) | +| `acl` | Per-ACL match counters (`^/acl/.*/matches`) | + +`system` exports: heartbeat, last-stats-clear, boottime, vector-rate +(overall and per-worker), loops-per-worker, num-worker-threads, +last-update, and input-rate. + +`nat44` exports: total-sessions (per NAT44 instance), max-cfg-sessions, +in2out/out2in fastpath, in2out/out2in slowpath, and hairpinning. + +This command can be repeated to export several groups. An unrecognized +group value is rejected at set time. +``` + +```{cfgcmd} set service monitoring prometheus vpp-exporter vrf \ + +Run the exporter inside the named {abbr}`VRF (Virtual Routing and Forwarding)` +instance, so that scrape traffic is routed via the VRF's routing table. +The service is started under `ip vrf exec `. +``` + +If `nodes` stats are selected via `stat-group nodes`, enable per-node +counters in VPP — without this, VPP does not maintain node-level +counters and the scrape returns empty values for that namespace. +Committing `stat-group nodes` without per-node counters enabled does not +fail the commit, but VyOS prints a one-time warning recommending that +the setting be enabled. + +```{cfgcmd} set vpp settings resource-allocation memory stats per-node-counters +``` + +Removing the VPP exporter does not change the `per-node-counters` +setting — it is left as configured. + +Example — export buffer-pool and system counters: + +```none +set service monitoring prometheus vpp-exporter stat-group buffer-pools +set service monitoring prometheus vpp-exporter stat-group system +``` + ### Blackbox Exporter Prometheus [blackbox_exporter] probes network endpoints and exposes the @@ -965,3 +1061,4 @@ set service monitoring prometheus blackbox-exporter modules icmp name ping6 time [prometheus-client]: [splunk]: [telegraf]: +[vpp_exporter]: -- cgit v1.2.3 From 0d920beef7e9360e54c5de1c4d70f5ceb0463f63 Mon Sep 17 00:00:00 2001 From: Ritika Chopra Date: Wed, 4 Nov 2026 23:00:43 -0700 Subject: T8382: DOC: fix lint errors in monitoring.md --- docs/configuration/service/monitoring.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'docs/configuration/service') diff --git a/docs/configuration/service/monitoring.md b/docs/configuration/service/monitoring.md index b005bec4..9d83e818 100644 --- a/docs/configuration/service/monitoring.md +++ b/docs/configuration/service/monitoring.md @@ -85,7 +85,8 @@ set service monitoring telegraf vrf mgmt ### Agent Configuration -This section covers configuration commands which affect the overall agent behaviour. +This section covers configuration commands which affect the overall +agent behavior. ```{cfgcmd} set service monitoring telegraf agent collection-jitter \ @@ -1052,6 +1053,8 @@ set service monitoring prometheus blackbox-exporter modules icmp name ping6 ip-p set service monitoring prometheus blackbox-exporter modules icmp name ping6 timeout 3 ``` +% stop_vyoslinter + [azure-data-explorer]: [blackbox_exporter]: [frr_exporter]: @@ -1062,3 +1065,5 @@ set service monitoring prometheus blackbox-exporter modules icmp name ping6 time [splunk]: [telegraf]: [vpp_exporter]: + +% start_vyoslinter -- cgit v1.2.3