For AI agents: this documentation is indexed for you in llms.txt, and all of it in /llms.txt. Every page is also available as markdown: append .md to its address.

You are reading User Plane Gateway 2.16, an older release. The newest release is 3.2. Go to 3.2

BGP support

User Plane Gateway (UPG) uses the BIRD2Opens in a new tab BGP daemon in a sidecar container to support Border Gateway Protocol (BGP). User Equipment IPs (UE-IPs) are exported and can be announced through BGP to edge gateways.

The UPG pod with BGP support includes an init container and several main containers:

  • Main container upg-vpp
  • BGP daemon container tool-bird2
  • BGP metrics exporter container tool-bird-exporter

UPG uses the VPP Linux Control Plane (LCP) pluginOpens in a new tab. This plugin allows VPP to integrate with applications that use the Linux kernel network stack. In the BGP support use case, the BGP daemon inserts routes learnt from BGP peering to the VPP routing table. The other direction is also possible: UE-IPs are exported and can be announced through BGP to edge gateways.

Sample BGP configuration

The following diagram shows the UPG deployment with the BGP support:

BGP support integration diagram
BGP support integration diagram

In the basic PGW example, the BGP daemon is connected to the SGI interface. The LCP interface is directly attached to SGI, and the BGP daemon peers with CGW on the right.

The full UPG configuration with enabled BGP is available hereOpens a file. Follow the instructions in the sections below to configure BGP.

Configure networking

First, configure networking. Make sure to provide the following values:

  • instances.{name}.networking.sgi.interface - name of the interface to connect the BGP daemon to
  • instances.{name}.networking.sgi.ipv4.addresses - SGI interface IPs used in the BGP configuration

See the example of networking configuration:

yaml

Enable BGP

Use this section of the UPG Helm chart to enable BGP deployment:

yaml

Setting bgp.enabled to true enables BGP support. This adds the bird2 and bird-exporter sidecar containers to the UPG deployment and connects them using the /run/bird shared volume. In bgp.netnsPath, you can specify a common Linux network namespace. The network namespace and bgp.table are passed to UPG-VPP to configure UE IPs publishing. The bgp.interface is used to create the LCP interface connected to the VPPInterface. In this example, sgi corresponds to instances.{name}.networking.sgi.interface.

You can set images for the containers related to the BPG functionality:

yaml

Define the UPGConfig representation

The Helm chart values defined in the bgp section are mapped to the UPGConfig Custom Resource in spec.ueip.export:

yaml

Use debug CLI

Note

Configuration applied through UPGConfig overrides the CLI configuration.

You can configure the UE IPs export at runtime using VPPCTL commands. See the command example to enable the UE IPs route exposure:

bash

Use this command to deactivate the UE IP export:

bash

Configure BGP

Provide the BGP daemon configuration in instances.{name}.bgp.config as a BIRD2 configuration file. The configuration is exposed as a ConfigMap and attached to the UPG deployment. The UPG image includes a script that checks for configuration updates and restarts the BGP daemon if any changes are detected.

Add the following BGP configuration to the UPG instance:

yaml

Sample BIRD2 configuration:

text

Setup verification

Check the number of containers

The UPG pod with BGP support includes three containers:

  • Main FPP container (upg-vpp)
  • Container with a running BIRD process (tool-bird2)
  • Container that exposes metrics in the Prometheus format (tool-bird-exporter)

Check the number of containers to verify if BGP is up and running.

Check UE IP exposure

To check if UPG is configured to publish UE IPs, use a VPPCTL command show upf ueip export as-ns-route.

See the output example:

text

You can check the UPG's tool-bird2 container logs where the exported UE IPs are listed. See the sample log message:

text

To check the list of exported UE IPs, use the Linux command ip route in the tool-bird2 container:

bash
bash

Table number (213) must match the bgp.table configured above.

Sample output:

bash

Check the applied BGP configuration

To check if BGP configuration and peering is active, run this command in the upg-vpp container of the UPG pod:

bash

Table number (213) must match the bgp.table configured above.

See the output example:

text

To check BGP peering on the tool-bird2 container, use the birdc diagnostic tool to get the state:

  • See the BGP routes exchanges between peers:
bash
  • Show the local protocols and BGP peering state
bash
  • See the detailed information about BGP:
bash

See the output example:

bash