Skip to content

collector/netclass: add master and VRF info metrics - #3765

Open
bewing wants to merge 2 commits into
prometheus:masterfrom
bewing:feat/network_info/vrf
Open

collector/netclass: add master and VRF info metrics#3765
bewing wants to merge 2 commits into
prometheus:masterfrom
bewing:feat/network_info/vrf

Conversation

@bewing

@bewing bewing commented Jul 30, 2026

Copy link
Copy Markdown

The netlink netclass path already receives IFLA_MASTER and IFLA_LINKINFO in the RTM_GETLINK dump it makes, but exposed neither the master device nor its kind, so there is no way to tell which VRF an interface is in.

Add node_network_master_info, labelled with the direct master and the master's kind as reported by IFLA_INFO_SLAVE_KIND, covering VRF membership as well as bridge ports and bond members.

Also add node_network_vrf_info to publish the routing table ID of VRF devices. rtnetlink has no vrf driver, so IFLA_VRF_TABLE is decoded from the raw IFLA_INFO_DATA payload.

@bewing
bewing force-pushed the feat/network_info/vrf branch from c029467 to 007589d Compare July 30, 2026 15:00
bewing added 2 commits July 30, 2026 10:31
The netlink netclass path already receives IFLA_MASTER and IFLA_LINKINFO
in the RTM_GETLINK dump it makes, but exposed neither the master device
nor its kind, so there is no way to tell which VRF an interface is in.

Add node_network_master_info, labelled with the direct master and the
master's kind as reported by IFLA_INFO_SLAVE_KIND, covering VRF
membership as well as bridge ports and bond members.

Also add node_network_vrf_info to publish the routing table ID of VRF
devices. rtnetlink has no vrf driver, so IFLA_VRF_TABLE is decoded from
the raw IFLA_INFO_DATA payload.

Signed-off-by: Brandon Ewing <brandon.ewing@warningg.com>
Signed-off-by: Brandon Ewing <brandon.ewing@warningg.com>
@bewing
bewing force-pushed the feat/network_info/vrf branch from 007589d to a665b51 Compare July 30, 2026 15:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant