Consider the network diagram of
Figure 1 and the IP addresses and IGP segment allocations of
Figure 2. Assume that the network is running IS-IS with SR extensions [
RFC 8667], and all links have the same metric. The following examples can be constructed.
+--------+
/ \
R0-----R1-----R2----------R3-----R8
| \ / |
| +--R4--+ |
| |
+-----R5-----+
+-----------------------------------------------------------+
| IP addresses allocated by the operator: |
| 192.0.2.1/32 as a loopback of R1 |
| 192.0.2.2/32 as a loopback of R2 |
| 192.0.2.3/32 as a loopback of R3 |
| 192.0.2.4/32 as a loopback of R4 |
| 192.0.2.5/32 as a loopback of R5 |
| 192.0.2.8/32 as a loopback of R8 |
| 198.51.100.9/32 as an anycast loopback of R4 |
| 198.51.100.9/32 as an anycast loopback of R5 |
| |
| SRGB defined by the operator as [1000,5000] |
| |
| Global IGP SID indices allocated by the operator: |
| 1 allocated to 192.0.2.1/32 |
| 2 allocated to 192.0.2.2/32 |
| 3 allocated to 192.0.2.3/32 |
| 4 allocated to 192.0.2.4/32 |
| 8 allocated to 192.0.2.8/32 |
| 1009 allocated to 198.51.100.9/32 |
| |
| Local IGP SID allocated dynamically by R2 |
| for its "north" adjacency to R3: 9001 |
| for its "east" adjacency to R3 : 9002 |
| for its "south" adjacency to R3: 9003 |
| for its only adjacency to R4 : 9004 |
| for its only adjacency to R1 : 9005 |
+-----------------------------------------------------------+
Suppose R1 wants to send IPv4 packet P1 to R8. In this case, R1 needs to apply the PUSH operation to the IPv4 packet.
Remember that the SID index "8" is a global IGP segment attached to the IP prefix 192.0.2.8/32. Its semantic is global within the IGP domain: any router forwards a packet received with active segment 8 to the next hop along the ECMP-aware shortest path to the related prefix.
R2 is the next hop along the shortest path towards R8. By applying the steps in
Section 2.8, the outgoing label downloaded to R1's FIB corresponding to the global SID index "8" is 1008 because the SRGB of R2 = [1000,5000] as shown in
Figure 2.
Because the packet is IPv4, R1 applies the PUSH operation using the label value 1008 as specified in
Section 2.10.1. The resulting MPLS header will have the "S" bit [
RFC 3032] set because it is followed directly by an IPv4 packet.
The packet arrives at router R2. Because top label 1008 corresponds to the IGP SID index "8", which is the Prefix-SID attached to the prefix 192.0.2.8/32 owned by Node R8, the instruction associated with the SID is "forward the packet using one of the ECMP interfaces or next hops along the shortest path(s) towards R8". Because R2 is not the penultimate hop, R2 applies the CONTINUE operation to the packet and sends it to R3 using one of the two links connected to R3 with top label 1008 as specified in
Section 2.10.1.
R3 receives the packet with top label 1008. Because top label 1008 corresponds to the IGP SID index "8", which is the Prefix-SID attached to the prefix 192.0.2.8/32 owned by Node R8, the instruction associated with the SID is "send the packet using one of the ECMP interfaces and next hops along the shortest path towards R8". Because R3 is the penultimate hop, we assume that R3 performs penultimate hop popping, which corresponds to the NEXT operation; the packet is then sent to R8. The NEXT operation results in popping the outer label and sending the packet as a pure IPv4 packet to R8.
In conclusion, the path followed by P1 is R1-R2--R3-R8. The ECMP awareness ensures that the traffic is load-shared between any ECMP path; in this case, it's the two links between R2 and R3.
This section outlines several examples to illustrate the handling of label collision described in
Section 2.5.
For the examples in this section, we assume that Node A has the following:
-
OSPF default admin distance for implementation=50
-
IS-IS default admin distance for implementation=60
The following example illustrates incoming label collision resolution for the same FEC type using MCC administrative distance.
FEC1:
Node A receives an OSPF Prefix-SID Advertisement from Node B for 198.51.100.5/32 with index=5. Assuming that OSPF SRGB on Node A = [1000,1999], the incoming label is 1005.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.105/32 with index=5. Assuming that IS-IS SRGB on Node A = [1000,1999], the incoming label is 1005.
FEC1 and FEC2 both use dynamic SID assignment. Since neither of the FECs are of type 'SR Policy', we use the default admin distances of 50 and 60 to break the tie. So FEC1 wins.
The following example Illustrates incoming label collision resolution for different FEC types using the MCC administrative distance.
FEC1:
Node A receives an OSPF Prefix-SID Advertisement from Node B for 198.51.100.6/32 with index=6. Assuming that OSPF SRGB on Node A = [1000,1999], the incoming label on Node A corresponding to 198.51.100.6/32 is 1006.
FEC2:
IS-IS on Node A assigns label 1006 to the globally significant Adj-SID (i.e., when advertised, the L-Flag is clear in the Adj-SID sub-TLV as described in [
RFC 8667]). Hence, the incoming label corresponding to this Adj-SID is 1006. Assume Node A allocates this Adj-SID dynamically, and it may differ across router reboots.
FEC1 and FEC2 both use dynamic SID assignment. Since neither of the FECs are of type 'SR Policy', we use the default admin distances of 50 and 60 to break the tie. So FEC1 wins.
The following example illustrates incoming label collision resolution based on preferring static over dynamic SID assignment.
FEC1:
OSPF on Node A receives a Prefix-SID Advertisement from Node B for 198.51.100.7/32 with index=7. Assuming that the OSPF SRGB on Node A = [1000,1999], the incoming label corresponding to 198.51.100.7/32 is 1007.
FEC2:
The operator on Node A configures IS-IS on Node A to assign label 1007 to the globally significant Adj-SID (i.e., when advertised, the L-Flag is clear in the Adj-SID sub-TLV as described in [
RFC 8667]).
Node A assigns this Adj-SID explicitly via configuration, so the Adj-SID survives router reboots.
FEC1 uses dynamic SID assignment, while FEC2 uses explicit SID assignment. So FEC2 wins.
The following example illustrates incoming label collision resolution using FEC type default administrative distance.
FEC1:
OSPF on Node A receives a Prefix-SID Advertisement from Node B for 198.51.100.8/32 with index=8. Assuming that OSPF SRGB on Node A = [1000,1999], the incoming label corresponding to 198.51.100.8/32 is 1008.
FEC2:
Suppose the SR Policy Advertisement from the controller to Node A for the policy identified by (Endpoint = 192.0.2.208, color = 100) that consists of SID-List=<S1, S2> assigns the globally significant Binding-SID label 1008.
From the point of view of Node A, FEC1 and FEC2 both use dynamic SID assignment. Based on the default administrative distance outlined in
Section 2.5.1, the Binding SID has a higher administrative distance than the Prefix-SID; hence, FEC1 wins.
The following example illustrates incoming label collision resolution based on FEC type preference.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.110/32 with index=10. Assuming that the IS-IS SRGB on Node A = [1000,1999], the incoming label corresponding to 203.0.113.110/32 is 1010.
FEC2:
IS-IS on Node A assigns label 1010 to the globally significant Adj-SID (i.e., when advertised, the L-Flag is clear in the Adj-SID sub-TLV as described in [
RFC 8667]).
Node A allocates this Adj-SID dynamically, and it may differ across router reboots. Hence, both FEC1 and FEC2 both use dynamic SID assignment.
Since both FECs are from the same MCC, they have the same default admin distance. So we compare the FEC type codepoints. FEC1 has FEC type codepoint=120, while FEC2 has FEC type codepoint=130. Therefore, FEC1 wins.
The following example illustrates incoming label collision resolution based on address family preference.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.111/32 with index=11. Assuming that the IS-IS SRGB on Node A = [1000,1999], the incoming label on Node A for 203.0.113.111/32 is 1011.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 2001:DB8:1000::11/128 with index=11. Assuming that the IS-IS SRGB on Node A = [1000,1999], the incoming label on Node A for 2001:DB8:1000::11/128 is 1011.
FEC1 and FEC2 both use dynamic SID assignment. Since both FECs are from the same MCC, they have the same default admin distance. So we compare the FEC type codepoints. Both FECs have FEC type codepoint=120. So we compare the address family. Since IPv4 is preferred over IPv6, FEC1 wins.
The following example illustrates incoming label collision resolution based on prefix length.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.112/32 with index=12. Assuming that IS-IS SRGB on Node A = [1000,1999], the incoming label for 203.0.113.112/32 on Node A is 1012.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.128/30 with index=12. Assuming that the IS-IS SRGB on Node A = [1000,1999], the incoming label for 203.0.113.128/30 on Node A is 1012.
FEC1 and FEC2 both use dynamic SID assignment. Since both FECs are from the same MCC, they have the same default admin distance. So we compare the FEC type codepoints. Both FECs have FEC type codepoint=120. So we compare the address family. Both are a part of the IPv4 address family, so we compare the prefix length. FEC1 has prefix length=32, and FEC2 has prefix length=30, so FEC2 wins.
The following example illustrates incoming label collision resolution based on the numerical value of the FECs.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.113/32 with index=13. Assuming that IS-IS SRGB on Node A = [1000,1999], the incoming label for 203.0.113.113/32 on Node A is 1013.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.213/32 with index=13. Assuming that IS-IS SRGB on Node A = [1000,1999], the incoming label for 203.0.113.213/32 on Node A is 1013.
FEC1 and FEC2 both use dynamic SID assignment. Since both FECs are from the same MCC, they have the same default admin distance. So we compare the FEC type codepoints. Both FECs have FEC type codepoint=120. So we compare the address family. Both are a part of the IPv4 address family, so we compare the prefix length. Prefix lengths are the same, so we compare the prefix. FEC1 has the lower prefix, so FEC1 wins.
The following example illustrates incoming label collision resolution based on the Routing Instance ID.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.114/32 with index=14. Assume that this IS-IS instance on Node A has Routing Instance ID = 1000 and SRGB = [1000,1999]. Hence, the incoming label for 203.0.113.114/32 on Node A is 1014.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.114/32 with index=14. Assume that this is another instance of IS-IS on Node A but Routing Instance ID = 2000 is different and SRGB = [1000,1999] is the same. Hence, the incoming label for 203.0.113.114/32 on Node A is 1014.
These two FECs match all the way through the prefix length and prefix. So the Routing Instance ID breaks the tie, and FEC1 wins.
The following example illustrates incoming label collision resolution based on the topology ID.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.115/32 with index=15. Assume that this IS-IS instance on Node A has Routing Instance ID = 1000. Assume that the prefix advertisement of 203.0.113.115/32 was received in the IS-IS Multi-topology advertisement with ID = 50. If the IS-IS SRGB for this routing instance on Node A = [1000,1999], then the incoming label of 203.0.113.115/32 for topology 50 on Node A is 1015.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.115/32 with index=15. Assume that it has the same Routing Instance ID = 1000, but 203.0.113.115/32 was advertised with IS-IS Multi-topology ID = 40, which is different. If the IS-IS SRGB on Node A = [1000,1999], then the incoming label of 203.0.113.115/32 for topology 40 on Node A is also 1015.
Since these two FECs match all the way through the prefix length, prefix, and Routing Instance ID, we compare the IS-IS Multi-topology ID, so FEC2 wins.
The following example illustrates incoming label collision for resolution based on the algorithm ID.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.116/32 with index=16. Assume that IS-IS on Node A has Routing Instance ID = 1000. Assume that Node B advertised 203.0.113.116/32 with IS-IS Multi-topology ID = 50 and SR algorithm = 0. Assume that the IS-IS SRGB on Node A = [1000,1999]. Hence, the incoming label corresponding to this advertisement of 203.0.113.116/32 is 1016.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.116/32 with index=16. Assume that it is the same IS-IS instance on Node A with Routing Instance ID = 1000. Also assume that Node C advertised 203.0.113.116/32 with IS-IS Multi-topology ID = 50 but with SR algorithm = 22. Since it is the same routing instance, the SRGB on Node A = [1000,1999]. Hence, the incoming label corresponding to this advertisement of 203.0.113.116/32 by Node C is also 1016.
Since these two FECs match all the way through in terms of the prefix length, prefix, Routing Instance ID, and Multi-topology ID, we compare the SR algorithm IDs, so FEC1 wins.
The following example illustrates incoming label collision resolution based on the FEC numerical value, independent of how the SID is assigned to the colliding FECs.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.117/32 with index=17. Assume that the IS-IS SRGB on Node A = [1000,1999]; thus, the incoming label is 1017.
FEC2:
Suppose there is an IS-IS Mapping Server Advertisement (SID / Label Binding TLV) from Node D that has range = 100 and prefix = 203.0.113.1/32. Suppose this Mapping Server Advertisement generates 100 mappings, one of which maps 203.0.113.17/32 to index=17. Assuming that it is the same IS-IS instance, the SRGB = [1000,1999] and hence the incoming label for 1017.
Even though FEC1 comes from a normal Prefix-SID Advertisement and FEC2 is generated from a Mapping Server Advertisement, it is not used as a tiebreaking parameter. Both FECs use dynamic SID assignment, are from the same MCC, and have the same FEC type codepoint=120. Their prefix lengths are the same as well. FEC2 wins based on its lower numerical prefix value, since 203.0.113.17 is less than 203.0.113.117.
The following example illustrates incoming label collision resolution based on address family preference.
FEC1:
SR Policy Advertisement from the controller to Node A. Endpoint address=2001:DB8:3000::100, color=100, SID-List=<S1, S2>, and the Binding-SID label=1020.
FEC2:
SR Policy Advertisement from controller to Node A. Endpoint address=192.0.2.60, color=100, SID-List=<S3, S4>, and the Binding-SID label=1020.
The FEC tiebreakers match, and they have the same FEC type codepoint=140. Thus, FEC2 wins based on the IPv4 address family being preferred over IPv6.
The following example illustrates incoming label resolution based on the numerical value of the policy endpoint.
FEC1:
SR Policy Advertisement from the controller to Node A. Endpoint address=192.0.2.70, color=100, SID-List=<S1, S2>, and Binding-SID label=1021.
FEC2:
SR Policy Advertisement from the controller to Node A. Endpoint address=192.0.2.71, color=100, SID-List=<S3, S4>, and Binding-SID label=1021.
The FEC tiebreakers match, and they have the same address family. Thus, FEC1 wins by having the lower numerical endpoint address value.
This section presents examples to illustrate the effect of incoming label collision on the selection of the outgoing label as described in
Section 2.6.
The following example illustrates the effect of incoming label resolution on the outgoing label.
FEC1:
IS-IS on Node A receives a Prefix-SID Advertisement from Node B for 203.0.113.122/32 with index=22. Assuming that the IS-IS SRGB on Node A = [1000,1999], the corresponding incoming label is 1022.
FEC2:
IS-IS on Node A receives a Prefix-SID Advertisement from Node C for 203.0.113.222/32 with index=22. Assuming that the IS-IS SRGB on Node A = [1000,1999], the corresponding incoming label is 1022.
FEC1 wins based on the lowest numerical prefix value. This means that Node A installs a transit MPLS forwarding entry to swap incoming label 1022 with outgoing label N and to use outgoing interface I. N is determined by the index associated with FEC1 (index=22) and the SRGB advertised by the next-hop node on the shortest path to reach 203.0.113.122/32.
Node A will generally also install an imposition MPLS forwarding entry corresponding to FEC1 for incoming prefix=203.0.113.122/32 pushing outgoing label N, and using outgoing interface I.
The rule in
Section 2.6 means Node A
MUST NOT install an ingress MPLS forwarding entry corresponding to FEC2 (the losing FEC, which would be for prefix 203.0.113.222/32).
The following example illustrates the effect of incoming label collision resolution on outgoing label programming on Node A.
FEC1:
SR Policy Advertisement from the controller to Node A. Endpoint address=192.0.2.80, color=100, SID-List=<S1, S2>, and Binding-SID label=1023.
FEC2:
SR Policy Advertisement from controller to Node A. Endpoint address=192.0.2.81, color=100, SID-List=<S3, S4>, and Binding-SID label=1023.
FEC1 wins by having the lower numerical endpoint address value. This means that Node A installs a transit MPLS forwarding entry to swap incoming label=1023 with outgoing labels, and the outgoing interface is determined by the SID-List for FEC1.
In this example, we assume that Node A receives two BGP/VPN routes:
-
R1 with VPN label=V1, BGP next hop = 192.0.2.80, and color=100
-
R2 with VPN label=V2, BGP next hop = 192.0.2.81, and color=100
We also assume that Node A has a BGP policy that matches color=100 and allows its usage as Service Level Agreement (SLA) steering information. In this case, Node A will install a VPN route with label stack = <S1,S2,V1> (corresponding to FEC1).
The rule described in
Section 2.6 means that Node A
MUST NOT install a VPN route with label stack = <S3,S4,V1> (corresponding to FEC2.)