Segment Routing IGP Prefix SID

Segment Routing divides a network into several segments and assign a segment ID to each segment. A Segment is an instruction that a node executes on the incoming packet; Forward packet according to the shortest path, Forward packet through a specific interface, deliver packet to a given application or service etc. A Segment Identifier (SID) identifies a Segment. And the format of a SID depends on the implementation; MPLS Label or IPv6 Address. In this post I will try to define Segment IDs which will be distributed by IGP.

SRGB and SRLB

Segment Routing Global Block (SRGB) is the set of global segments in the SR domain. If a node participates in multiple SR domains, there is one SRGB for each SR domain. In SR-MPLS, SRGB is a local property of a node and identifies the set of local labels reserved for global segments. In SR-MPLS, using identical SRGBs on all nodes within the SR domain is strongly recommended. SR Local Block (SRLB) is local property of an SR node. In SR-MPLS, SRLB is a set of local labels reserved for local segments.

IGP Prefix Segment Identifer

IGP Prefix Segment Identifer (Prefix-SID) is a Global Segment, advertised by ISIS or OSPF and associated with a prefix, commonly with a loopback ip address. The operator assigns a domain wide unique Prefix-SID to prefixes in the domain. The domain wide uniqueness is a property. In the MPLS Data Plane, Prefix-SIDs are allocated from Segment Routing Global Block (SRGB).

Prefix-SID Distribution

Let’s how will Prefix-SIDs will be distributed and forwarding table will be populated with a simple topology.

  1. According to simple topology if we assume we used same SRGB for all nodes and defined Prefix-SID as 16004 for the Loopback0 address of Node-G, Node-G will insert Index value and SRGB range into its LSDB and flood it to the network. But of course IGP should be enabled to disribute SIDs.
  1. Node-E, after running SPF algorithm, will install 10.1.1.4/32 prefix into its routing table with a next hop of Node-G. And it will calculate Prefix-SID of 10.1.1.4/32 from the SRGB+Index value sent from its next-hop and install it to its SR forwarding table.
Incoming Active Segment: 16004 (Own Prefix-SID)

Operation: Next (PHP is enable by default)

Egress Interface: The interface towards to next-hop
  1. Node-C, after running SPF algorithm, will install 10.1.1.4/32 prefix into its routing table with a next hop of Node-E. And It will also calculate the prefix-SID and install it SR forwarding table.
Incoming Active Segment: 16004 (Own Prefix-SID)

Operation: Continue (Keep 16004)

Egress Interface: The interface towards to next-hop
  1. Node-A, after running SPF algorithm, will install 10.1.1.4/32 prefix into its routing table with a next hop of Node-E. It will also calculate the prefix-SID and install it SR forwarding table.
Incoming Active Segment: NULL

Operation: PUSH

Egress Interface: The interface towards to next-hop

Prefix-SID in Data Plane

If we push traffic which is going towards Node-G, into SR tunnel;

  1. Node-A will push 16004 MPLS label
  2. Node-C will continue with 16004
  3. Node-E will POP the 16004 (Next operation)
  4. Node-G will handle the traffic according to its routing table.

About: fabricplane