Skip to content
Thomas Mangin edited this page May 29, 2026 · 3 revisions

Pre-Alpha. This page describes behavior that may change.

Ze can act as a Linux MPLS label-switching router (LSR). BGP labeled-unicast routes (RFC 8277) received from peers are programmed into the kernel MPLS FIB as label-push entries via netlink lwtunnel, so Ze forwards labeled traffic without VPP.

Kernel MPLS forwarding

Labeled-unicast next-hops become label-push entries in the Linux MPLS FIB. Labels are validated as 20-bit values, and the label stack is limited to 16 entries deep. The dataplane is owned by a single producer: fib-kernel. Other control-plane components (BGP labeled-unicast, LDP, RSVP-TE) emit push/swap/pop forwarding entries on the mpls-fib event bus, and fib-kernel programs them into the kernel (IP route plus label for push, AF_MPLS routes for swap/pop). This keeps fib-kernel the single kernel-FIB owner.

Enabling MPLS

MPLS label processing is per-interface. Enable it on each interface that should accept labeled packets:

interface {
    ethernet eth0 {
        unit 0 {
            mpls {
                enable true
            }
        }
    }
}

This sets net.mpls.conf.eth0.input=1. The global label-table size is governed by the net.mpls.platform_labels sysctl (configure it via the sysctl {} block; it defaults to off, which disables MPLS entirely).

The Linux kernel must have the mpls_router and mpls_iptunnel modules loaded. ze doctor warns (doctor-mpls-unavailable) when they are missing.

Inspecting the forwarding table

ze show mpls forwarding              # all installed MPLS entries
ze show mpls forwarding --limit 500  # cap the response size

Each row reports the incoming label (in-label), the operation (swap or pop), any outgoing out-labels, the next-hop, and the egress device. The data is read directly from the kernel AF_MPLS routing table.

Metrics

Metric Meaning
ze_fibkernel_mpls_routes_installed Current MPLS labeled-route count.
ze_fibkernel_mpls_installs_total MPLS routes successfully programmed.

Label distribution

Two label-distribution protocols are available (both experimental):

  • LDP (RFC 5036) for IGP-shortest-path label distribution.
  • RSVP-TE (RFC 3209) for traffic-engineered explicit-path LSPs with bandwidth reservation. See RSVP-TE.

LDP

LDP implements UDP multicast Hello discovery, a TCP session FSM, and a label information base of FEC-to-label bindings.

ldp {
    lsr-id 10.0.0.1
    transport-address 10.0.0.1
    interfaces eth0
    interfaces eth1
}
Field Meaning
lsr-id This router's LSR identifier (IPv4 address format).
transport-address Address advertised for the LDP TCP session.
interfaces One entry per interface on which LDP Hello discovery runs (repeat the leaf for each interface).
hello-interval / hello-hold-time / keepalive-time Optional soft-state timers (defaults 5s / 15s / 60s).

Inspect LDP state with show ldp neighbor (session state, transport address) and show ldp binding (FEC-to-label bindings). A label binding learned from a neighbor programs an ingress push entry in the kernel MPLS FIB toward that neighbor.

Status

End-to-end and FRR interop validation on a live kernel is still pending. Use for evaluation, not production forwarding.

See also

  • RSVP-TE for traffic-engineered explicit-path LSPs.
  • FIB for the route-installation pipeline.
  • Kernel FIB for the netlink backend that owns the kernel FIB.
  • Labeled Unicast for the BGP family that feeds MPLS labels.
  • VPP Data Plane for MPLS forwarding on the VPP dataplane.
  • sysctl for tuning net.mpls.*.

Adapted from main/docs/guide/mpls.md.

Home

About

First Steps

Configuration

Operation

Interfaces

Plugins

Plugin Development

Chaos Testing

Blueprints

Development

Reference

Clone this wiki locally