- Table of Contents
-
- 09-Segment Routing Configuration Guide
- 00-Preface
- 01-SR-MPLS configuration
- 02-SR-MPLS TE policy configuration
- 03-SRv6 configuration
- 04-SRv6 TE policy configuration
- 05-SRv6 VPN overview
- 06-IP L3VPN over SRv6 configuration
- 07-EVPN L3VPN over SRv6 configuration
- 08-Public network IP over SRv6 configuration
- 09-SRv6 OAM configuration
- 10-EVPN VPLS over SRv6 configuration
- 11-EVPN VPWS over SRv6 configuration
- Related Documents
-
Title | Size | Download |
---|---|---|
01-SR-MPLS configuration | 1.18 MB |
Contents
Traffic steering to an SR-MPLS tunnel
Dynamic SID allocation through an IGP
Dynamic SID allocation through BGP
SID allocation through BGP EPE
Label forwarding entry installation based on SIDs
Microloop avoidance after a network failure
Microloop avoidance after a failure recovery
IP traffic forwarding over SRLSPs tasks at a glance
MPLS TE traffic forwarding over static SRLSPs tasks at a glance
MPLS TE traffic forwarding over explicit paths tasks at a glance
MPLS TE traffic forwarding over PCE-calculated SRLSPs tasks at a glance
Prerequisites for configuring static segments
Configuring a static adjacency segment
Configuring a static prefix segment
Configuring IGP-based SID advertisement
IGP-based SID advertisement tasks at a glance
Prerequisites for configuring IGP-based SID advertisement
Configuring the IGP to support SR-MPLS
Enabling SR-MPLS adjacency label allocation for the IGP
Enabling SR-MPLS adjacency SID allocation for aggregation group member interfaces
Assigning adjacency SIDs to aggregation group member interfaces
Enabling prefix SID conflict checking
Configuring BGP-based SID advertisement
BGP-based SID advertisement tasks at a glance
Prerequisites for configuring BGP-based SID advertisement
Configuring BGP to support MPLS SR
Configuring BGP EPE-based SID allocation
Configuring a BGP EPE peer set
Configuring the SRLSP establishment triggering policy
Configuring the device to prefer SRLSPs in traffic forwarding
Configuring an MPLS TE tunnel over a static SRLSP
Binding a static SRLSP to an MPLS TE tunnel interface
Configuring the static SRLSP switchback delay time
Configuring an MPLS TE tunnel over an explicit-path SRLSP
Configuring an explicit path for the MPLS TE tunnel
Configuring an MPLS TE tunnel over the explicit path
Configuring an MPLS TE tunnel over a PCE-calculated SRLSP
Configuring an MPLS TE tunnel interface to use PCE to calculate the SRLSP
Configuring IGP SR and LDP interworking
Restrictions and guidelines for IGP SR and LDP interworking
Prerequisites for SR-MPLS and LDP internetworking
Enabling advertisement of locally configured prefix-SID mappings
Configuring prefix-SID mappings
Enabling reception of advertised prefix-SID mappings
Restrictions and guidelines for TI-LFA FRR
Disabling an interface from participating in TI-LFA calculation
Configuring microloop avoidance
Configuring tunnel BFD for all SRLSPs
Verifying and maintaining SR-MPLS
Displaying SR label block information
Displaying BGP SR configuration and status information
Displaying IS-IS SR configuration and status information
Displaying OSPF SR configuration and status information
Displaying SRLSP configuration and status information
SR-MPLS configuration examples
Example: Configuring SR-MPLS based on static segments
Example: Configuring SR-MPLS based on ISIS-advertised SIDs
Example: Configuring SR-MPLS based on OSPF-advertised SIDs
Example: Configuring an SR-based MPLS TE tunnel over an explicit path
Example: Configuring an MPLS TE tunnel over a PCE-calculated SRLSP
Example: Configuring SR-MPLS inter-AS option B
Example: Configuring SR-MPLS inter-AS option C (I)
Example: Configuring SR-MPLS inter-AS option C (II)
Example: Configuring SR-MPLS inter-AS option C (III)
Example: Configuring SR-MPLS to LDP (IS-IS)
Example: Configuring SR-MPLS to LDP (OSPF)
Example: Configuring SR-MPLS over LDP
Example: Configuring IS-IS TI-LFA FRR
Configuring SR-MPLS
About SR-MPLS
Segment Routing (SR) is a source routing technology. The source node selects a path for the packets, and then encodes the path in the packet header as an ordered list of segments. Each segment is identified by a label called a segment identifier (SID). The SR nodes along the path forward the packets based on the SIDs in the packets. Only the source node needs to maintain the path status.
SR can operate with MPLS. In an MPLS network, SR uses MPLS labels as SIDs to forward packets on an LSP.
SR-MPLS characteristics
SR-MPLS has the following characteristics:
· SR-MPLS forwards packets based on the existing MPLS infrastructure. No infrastructure modifications are needed to implement SR on an MPLS network. For more information about the MPLS infrastructure, see MPLS basics configuration in MPLS Configuration Guide.
· SR-MPLS expands and optimizes existing IGPs and BGP and uses the IGPs and BGP to distribute labels.
· SR-MPLS implements network features such as MPLS TE in a simpler way, eliminating issues such as heavy and complicated routing protocol deployment.
Basic concepts
· SR node—A node enabled with the SR-MPLS feature. The ingress node (source node) adds labels to packets. The transit nodes forward packets based on labels. The egress node (endpoint node) removes labels and forwards packets to the destination networks. SR nodes form an SR domain.
· Segment—An instruction an SR node executes on the incoming packet.
· SID—Segment ID, which is MPLS label in SR-MPLS.
· Segment type—The following types of segments are available:
¡ Prefix segment—SIDs are assigned to nodes based on destination address prefix. The nodes create prefix-specific forwarding entries.
¡ Adjacency segment—SIDs are assigned to nodes based on adjacency.
· SRLSP—Segment routing label switched path, an LSP along which SR uses MPLS labels as SIDs to forward packets.
· SRGB—Segment routing global block, a range of global labels dedicated for SR-MPLS prefix SIDs. Different nodes can have different SRGBs. The minimum label value of an SRGB label range is referred to as the base value of the SRGB.
· SRLB—Segment routing local block, a range of local labels dedicated for SR-MPLS adjacency SIDs. All nodes share the same SRLB. The minimum label value of the SRLB label range is referred to as the base value of the SRLB.
How SR-MPLS works
SR-MPLS involves the following steps:
1. Label allocation for all nodes and links along the packet forwarding paths.
The following methods are available:
¡ Static segment configuration
¡ Dynamic SID allocation through an IGP
2. Label forwarding entry installation based on SIDs. All SR-MPLS devices in the SR domain use the allocated labels to create label forwarding entries.
3. SRLSP setup. You can manually configure SRLSPs, or use an IGP, BGP, or a controller to dynamically create SRLSPs.
When the ingress node of an SRLSP receives a packet, it adds labels to the packet and forwards the packet to the egress node through the SRLSP. After receiving a packet from the SRLSP, the egress node removes the label and forwards the packet based on the routing table.
You can bind a higher layer application (for example, MPLS TE) to an SRLSP to forward traffic of the application through the SRLSP.
Traffic steering to an SR-MPLS tunnel
SR-MPLS tunnels include SR-MPLS BE tunnels and SR-MPLS TE tunnels.
After an SR-MPLS BE or SR-MPLS TE tunnel is established, traffic cannot be forwarded automatically through the tunnel. You can use the following methods to steer traffic to an SR-MPLS BE or SR-MPLS TE tunnel:
Static route
The static route method is a simple, direct method for steering traffic to an SR-MPLS TE tunnel.
This method configures a static route destined for the destination address through the tunnel interface and allows the static route to recurse to LSP tunnels established by SR-MPLS TE. For more information about static route recursion to LSP tunnels, see static route configuration in Layer 3—IP Routing Configuration Guide.
Tunnel policy
When traffic of a VPN is forwarded through a tunnel, the traffic is forwarded through an LDP LSP tunnel by default. To direct the traffic to an SR-MPLS BE or SR-MPLS TE tunnel, you can apply a tunnel policy or tunnel selector to the VPN.
Based on the service requirements, you can configure one of the following types of tunnel policy to direct traffic of a VPN to an SR-MPLS BE or SR-MPLS TE tunnel:
· Tunnel binding—Bind a destination IP address to a tunnel in a tunnel policy. After the tunnel policy is applied to a VPN, the VPN traffic to the destination IP address will be forwarded by the bound tunnel.
· Preferred tunnel—Specify an SR-MPLS TE tunnel as a preferred tunnel in a tunnel policy. After the tunnel policy is applied to a VPN, the VPN traffic will be forwarded by the preferred tunnel. This method explicitly specifies a tunnel for a VPN, facilitating traffic planning.
· Load sharing—Specify the tunnel types (SR-MPLS BE or SR-MPLS TE tunnels) and selection order and the number of tunnels for load sharing in a tunnel policy.
For more information about tunnel policies, see MPLS Configuration Guide.
PBR
The policy-based routing (PBR) method defines a PBR policy to specify the output interface for packets that match an ACL as an SR-MPLS TE tunnel interface, and then applies the PBR policy to the incoming interface of packets. In this way, traffic is redirected to the SR-MPLS TE tunnel.
The PBR method can match the packets to be forwarded by a tunnel interface by packet destination IP address, source IP address, and protocol type. Compared with the static route method, the PBR method is more flexible but its configuration is more complicated. For more information about PBR, see policy-based routing configuration in Layer 3—IP Routing Configuration Guide.
Automatic route advertisement
Automatic route advertisement distributes the SR-MPLS TE tunnel to the IGP (OSPF or IS-IS), so the SR-MPLS TE tunnel can participate in IGP routing calculation.
Automatic route advertisement can be implemented by using the following methods:
· IGP shortcut—Also known as AutoRoute Announce. It considers the SR-MPLS TE tunnel as a link that directly connects the tunnel ingress node (source node) and the egress node (endpoint node). Only the ingress node uses the SR-MPLS TE tunnel during IGP route calculation.
· Forwarding adjacency—Considers the SR-MPLS TE tunnel as a link that directly connects the tunnel ingress node and the egress node, and advertises the link to the network through an IGP. Every node in the network uses the SR-MPLS TE tunnel during IGP route calculation.
As shown in Figure 1, an SR-MPLS TE tunnel exists from Device D to Device C. IGP shortcut enables only the ingress node Device D to use the SR-MPLS TE tunnel in the IGP route calculation. Device A cannot use this tunnel to reach Device C. With forwarding adjacency enabled, Device A can learn this SR-MPLS TE tunnel and transfer traffic to Device C by forwarding the traffic to Device D.
Figure 1 IGP shortcut and forwarding adjacency
Static segment configuration
Static SR-MPLS provides the following methods for configuring static segments for a destination:
· Prefix segment method—Manually configure the incoming label, outgoing label, and next hop for the destination address prefix on each SR node.
· Adjacency segment method—Manually configure the incoming label and next hop for the adjacency to the neighbor on each SR node.
Dynamic SID allocation through an IGP
SR-MPLS expands IGP protocols such as IS-IS and OSPF to advertise SIDs in IGP protocol packets. SR-MPLS provides the following methods for dynamically allocating and advertising SIDs:
· Prefix SID.
· Adjacency SID.
Prefix SID
After you configure an SID for the loopback address on each SR node, the SIDs uniquely identify the SR nodes. All SR nodes in the SR domain use an IGP to advertise their own prefix SIDs. After receiving advertised prefix SIDs, each SR node calculates the prefix SIDs to the advertisers.
The prefix SID advertisement can be one of the following types:
· Absolute value advertisement—Each SR node advertises the prefix SID absolute value and the SRGB.
· Index value advertisement—Each SR node advertises the prefix SID index and the SRGB.
Each SR node is assigned a globally unique index value for the node's prefix. The prefix SID an SR node allocates to a prefix equals the SRGB base of the SR node plus the index for that prefix.
|
NOTE: The device supports only the index value advertisement in the current software release. |
Adjacency SID
SR nodes use an IGP to advertise SIDs allocated to the IGP adjacencies (that is, the links to its IGP neighbors). The SIDs are used to identify the links.
The adjacency SIDs can be allocated automatically or manually.
· Automatic adjacency SID allocation—SR nodes allocate labels in SRLBs to the IGP adjacencies as SIDs.
· Manual adjacency SID allocation—You can assign adjacency SID by using absolute values or index values. If you use index values, the adjacency SID of a link is the base value of the SRLB plus the index value for the link.
Dynamic SID allocation through BGP
SR-MPLS expands BGP to advertise prefix SIDs in BGP protocol packets. BGP uses routing policies to assign SIDs to prefixes when redistributing routes. The SIDs uniquely identify the SR nodes. All SR nodes in the SR domain use BGP to advertise their own prefix SIDs, including the SIDs and SID index values. From received advertisement packets, each SR node derives the prefix SIDs for the advertisers.
BGP prefix SIDs can be exchanged between BGP peers only through IPv4 unicast routes.
Dynamic SID allocation through BGP applies to MPLS VPN inter-AS option C networks.
SID allocation through BGP EPE
The BGP Egress Peer Engineering (BGP EPE) feature assigns labels to BGP peers to steer traffic across ASs to specific BGP neighbors or links.
After you configure BGP EPE on a device, the device assigns SIDs to connected BGP peers or peer groups to identify the BGP neighbors or links. These SIDs are called BGP peering SIDs or BGP peering segments.
BGP peering segments or SIDs fall into the following types:
· Peer Node Segment (Peer Node SID)—Node type, typically assigned to a BGP neighbor that has used a directly connected interface to establish a BGP session with the device.
· Peer Adjacency Segment (Peer Adjacency SID)—Adjacency type, typically assigned to a BGP neighbor that uses a loopback interface to establish a BGP session with the device.
· Peer Set Segment (Peer Set SID)—Set type, typically assigned to links when multiple equal cost multi-path (ECMP) paths exist between the device and a BGP neighbor.
SIDs that BGP EPE assigns are locally significant. These SIDs are not advertised to other devices and are not affected by route types exchanged between BGP peers.
SID allocation through BGP EPE is typically used for MPLS VPN inter-AS option B.
Label forwarding entry installation based on SIDs
Label forwarding entry installation based on IGP prefix SIDs
Label forwarding entries based on prefix SIDs can be static or dynamic.
· Static label forwarding entries—The device creates local label forwarding entries based on manually configured incoming labels, outgoing labels, and next hops.
· Dynamic label forwarding entries—The device uses the IGP to flood in the SR domain the local SRGB and the index of the prefix SID for the local loopback interface. Based on the flooded information, the other devices in the domain calculates their local label forwarding entries by using the following rules:
¡ Incoming label = Local SRGB base value + Index
¡ Outgoing label = SRGB base value of the next hop + Index
Figure 2 Creating label forwarding entries based on IGP prefix SIDs
Figure 2 shows how dynamic label forwarding entries are created. After you assign index value 201 to loopback address 1.1.1.1/32 on Device C, Device C uses an IGP packet to advertise the index value and its local SRGB. Then, the devices calculate incoming and outgoing labels according to the previously mentioned label calculation rules.
· Devices C calculates its incoming label, which is 16201.
· Device B calculates its incoming label and outgoing label and creates a label forwarding entry. The incoming label is 16201. The outgoing label is 16201. The next hop is Device C.
· Device A calculates its incoming label and outgoing label and creates a label forwarding entry. The incoming label is 16201. The outgoing label is 16201. The next hop is Device B.
Label forwarding entry installation based on BGP prefix SIDs
The device redistributes routes to BGP and assigns prefix SIDs to redistributed routes based on routing policies. Then, the device uses BGP to flood in the SR domain the prefix SIDs and the indexes of the prefix SIDs. Based on the flooded information, the other devices in the domain calculates their local label forwarding entries by using the following rules:
· Incoming label = Local SRGB base value + Index
· Outgoing label = Received SID
Figure 3 Creating label forwarding entries based on BGP prefix SIDs
Figure 3 shows how label forwarding entries are created. After you assign index value 201 to loopback address 1.1.1.1/32 on Device D, Device D redistributes the route of the address and assigns it an SID (16201 in this example). Then, the device uses a BGP packet to advertise the SID and index value. The devices in the SR domain calculate incoming and outgoing labels according to the previously mentioned label calculation rules and create label forwarding entries.
· Devices D calculates its incoming label, which is 16201.
· Device C calculates its incoming label and outgoing label and creates a label forwarding entry. The incoming label is 16201. The outgoing label is 16201. The next hop is Device D.
· Device B calculates its incoming label and outgoing label and creates a label forwarding entry. The incoming label is 16201. The outgoing label is 16201. The next hop is Device C.
· Device A calculates its incoming label and outgoing label and creates a label forwarding entry. The incoming label is 16201. The outgoing label is 16201. The next hop is Device B.
Label forwarding entry installation based on BGP EPE
Configure BGP EPE on border routers to assign SIDs to specific peers or peer groups.
Figure 4 Creating label forwarding entries by using BGP EPE
As shown in Figure 4, you can configure BGP EPE on Device B to assign BGP peering SIDs to EBGP neighbors Device C and Device D. BGP peering SIDs are locally significant and are not advertised to neighbors.
Label forwarding entry installation based on adjacency SIDs
When using adjacency SIDs, each device allocates a static or dynamic incoming label to the link to its neighbor. The label has local significance. Multiple devices can use the same adjacency SID.
Figure 5 Creating label forwarding entries based on adjacency SIDs
As shown in Figure 5, the devices are running the same IGP. After IGP adjacencies are established between the devices, Device A, Device B, and Device C allocates labels and creates label forwarding entries as follows:
· Device A allocates label 203 to the link to its neighbor Device B.
· Device B allocates label 202 to the link to its neighbor Device C.
· Device C allocates label 201 to the link to its neighbor Device D.
· Device A creates a label forwarding entry with incoming label 203 and next hop Device B.
· Device B creates a label forwarding entry with incoming label 202 and next hop Device C.
· Device C creates a label forwarding entry with incoming label 201 and next hop Device D.
SRLSP setup
You can use the following methods to create SRLSPs:
· Manually configure an SRLSP.
To configure an SRLSP, you must specify the label stack for packets to be forwarded along the SRLSP on the ingress node. Each label in the stack corresponds to a prefix SID or adjacency SID. The system can look for the outgoing label and next hop based on the prefix SID or adjacency SID.
· Configure SR nodes to use BGP or an IGP to dynamically establish an SRLSP.
SR nodes follow these steps to establish SRLSPs:
a. Use BGP or an IGP to collect prefix SID information from the SR-MPLS network.
b. Calculate the shortest paths to other SR nodes based on the collected prefix SID information and the BGP or IGP network topology.
c. Establish SRLSPs based on the shortest paths.
· Configure a controller to deploy SRLSP configuration to the device so the device creates SRLSPs.
For more information about controller configuration, see the user guide for the controller.
Packet forwarding in SR-MPLS
Based on the SID allocation method, SR-MPLS uses one of the following packet forwarding methods:
· Prefix SID-based packet forwarding—The ingress node encapsulates the prefix SID for the egress node to a packet. The transit nodes forward the packet based on label forwarding entries.
· Adjacency SID-based packet forwarding—The ingress node encapsulates the label stack that contains the adjacency SIDs of all links along the forwarding path to a packet. Each transit node uses the top label in the label stack to determine the next hop and pops the top label before forwarding the packet to the next hop.
· Prefix and adjacency SID-based packet forwarding—The nodes use prefix SID-based packet forwarding in combination with adjacency-based packet forwarding.
Prefix SID-based packet forwarding within the same AS
Figure 6 shows how a packet is forwarded along the SRLSP from Device A to Device E based on prefix SIDs. In this example, the outgoing label for the packet is 16201 on Device A.
1. Ingress node Device A searches for a forwarding entry for label 16201, adds outgoing label 16201 to the packet and sends the packet to the next hop (Device B).
2. When transit node Device B receives the packet, it searches for a label forwarding entry that matches the label in the packet. Then, Device B uses the outgoing label of the matched entry (16201) to replace the label in the packet and forwards the packet to the next hop (Device C).
3. Transit nodes Device C and Device D process the packet in the same way Device B does.
4. When egress node Device E receives the packet, it removes the label and forwards the packet by IP address.
Figure 6 Prefix SID-based packet forwarding within the same AS
Prefix SID-based packet forwarding across ASs
Figure 7 shows how a packet is forwarded along the SRLSP from Device A to Device D based on prefix SIDs. In this example, the outgoing label for the packet is 16201 on Device A.
1. Ingress node Device A searches for a forwarding entry for label 16201, adds outgoing label 16201 to the packet, and sends the packet to the next hop (Device B).
2. When transit node Device B receives the packet, it searches for a label forwarding entry that matches the label in the packet (16201). Then, Device B uses the outgoing label of the matched entry (16201) to replace the label in the packet and forwards the packet to the next hop (Device C).
3. Transit nodes Device C processes the packet in the same way Device B does.
4. When egress node Device D receives the packet, it removes the label and forwards the packet by IP address.
Figure 7 Prefix SID-based packet forwarding across ASs
BGP EPE-based packet forwarding across ASs
As shown in Figure 8, you can configure BGP EPE and an SRLSP used for the MPLS TE tunnel on Device B to steer packets to travel through Device C or Device D to Device E. In this example, packets travel from Device A through Device B and Device D to Device E. Device B uses BGP EPE to assign SID 6000 to Device D. A static SRLSP is established between Device B and Device D for the MPLS TE tunnel and Device B also assigns SID 6000 to the SRLSP.
1. Within AS 100, source node Device A adds label 16204 to the packet according to the SRLSP, and sends the packet to Device B.
2. When Device B receives the packet, it searches for a label forwarding entry and finds that it should forward the packet through the MPLS TE tunnel. Then, Device B removes label 16204 from the packet, and forwards the packet through the MPLS TE tunnel to Device D.
3. Within AS 200, Device D searches for a label forwarding entry based on the SRLSP, adds label 16201 to the packet, and sends the packet to Device E.
4. When egress node Device E receives the packet, it removes label 16201 and forwards the packet by IP address.
Figure 8 BGP EPE-based packet forwarding across ASs
Adjacency SID-based packet forwarding
Figure 9 shows how a packet is forwarded along the SRLSP from Device A to Device E based on adjacency SIDs. In this example, the label stack for the packet is configured as (200, 201, 202, and 203) on Device A.
1. Ingress node Device A searches for a forwarding entry for the top label (200) to determine the next hop. Then, Device A adds label stack (201, 202, and 203) to the packet, and forwards the packet to the next hop (Device B).
2. When transit node Device B receives the packet, it searches for a forwarding entry for the top label (201) to determine the next hop. Then, Device B removes the top label from the stack and forwards the packet to the next hop (Device C).
3. When transit node Device C receives the packet, it searches for a forwarding entry for the top label (202) to determine the next hop. Then, Device C removes the top label from the stack and forwards the packet to the next hop (Device D).
4. When transit node Device D receives the packet, it searches for a forwarding entry for the label (203) to determine the next hop. Then, Device D removes the label stack from the packet and forwards the packet to the next hop (Device E).
5. When egress node Device E receives the packet, it forwards the packet by IP address.
Figure 9 Adjacency SID-based packet forwarding
Prefix and adjacency SID-based packet forwarding
Figure 10 shows how a packet is forwarded along the SRLSP from Device A to Device E based on prefix SIDs and adjacency SIDs. In this example, the index value for the prefix SID of Device C is 1. The prefix SIDs for Device A, Device B, and Device C are all 16001. The Adjacency SIDs that Device C and Device D allocate to the adjacencies are 16 and 17, respectively. On Device A, the label stack for the packet is (16001, 16, 17).
1. Ingress node Device A searches for a forwarding entry for label 16001 to determine the outgoing label (16001) and next hop (Device B). Device A adds label stack (16001, 16, 17) to the packet and sends the packet to the next hop (Device B).
2. When transit node Device B receives the packet, it searches for a label forwarding entry that matches the top label in the label stack (16001). Then, Device B uses the outgoing label of the matched entry (16001) to replace the top label and forwards the packet to the next hop (Device C).
3. When transit node Device C receives the packet, it removes the top label 16001 and searches for a forwarding entry for the next label (16) to determine the next hop. Then, Device C removes label 16 from the stack and forwards the packet to the next hop (Device D).
4. When transit node Device D receives the packet, it searches for a forwarding entry for the label (17) to determine the next hop. Then, Device D removes the label stack from the packet and forwards the packet to the next hop (Device E).
5. When egress node Device E receives the packet, it forwards the packet by IP address.
Figure 10 Prefix and adjacency SID-based packet forwarding
MPLS SR and LDP interworking
IGP SR and LDP interworking enables SR-MPLS networks that use an IGP for SID advertisement to communicate and cooperate with MPLS LDP networks.
IGP SR and LDP interworking supports the following modes:
· SR to LDP—Maps prefixes on an LDP network to SR-MPLS SIDs to forward traffic from an SR-MPLS network to an MPLS LDP network.
· LDP to SR—Uses an IGP protocol to advertise SIDs and associates SIDs with LDP labels to forward traffic from an MPLS LDP network to an SR-MPLS network.
· SR over LDP—Enables SR-MPLS networks to communicate through an LDP network.
SR to LDP
The SR to LDP mode defines the following roles:
· Segment Routing Mapping Server (SRMS)—Advertises prefix-SID mappings on behalf of SR-incapable devices (LDP devices). You must configure prefix-SID mappings on the SRMS.
· Segment Routing Mapping Client (SRMC)—Receives prefix-SID mappings advertised by the SRMS and creates SR-MPLS label forwarding entries.
As shown in Figure 11, Device A and Device B are running SR-MPLS, and Device B, Device C, and Device D are running LDP. After Device D assigns a label for destination address 3.3.3.3/32, Device B and Device C each install an LDP label forwarding entry.
The following steps establish a mapping between the SRLSP and the LDP LSP:
1. Device B acts as an SRMS. It assigns SID index value 201 to the IP address of loopback interface 0 on Device D (3.3.3.3/32), and then advertises an IP prefix-SID mapping TLV to Device A.
2. Device A acts as an SRMC. After receiving the advertised mapping TLV, it creates an SR-MPLS label forwarding entry.
A mapping is established between the SRLSP and the LDP LSP.
Figure 11 SR to LDP packet forwarding
If Device A uses an SRLSP to send a packet to Device D, the packet is forwarded as follows:
1. Ingress node Device A adds label 16201 to the packet and then sends the packet to transit node Device B.
2. When transit node Device B receives the packet, it searches for a label forwarding entry that matches incoming label 16201. Because the entry does not have an outgoing label, Device B searches for a valid LDP outgoing label for destination address 3.3.3.3/32. Then, Device B adds the LDP label (20) to the packet as the SR outgoing label and forwards the packet to the next hop (Device C).
3. When transit node Device C receives the packet, it searches for an LDP label forwarding entry for incoming label 20. Then, it removes the label from the packet and forwards the packet to egress node Device D.
4. The egress node forwards the packet by IP address.
LDP to SR
As shown in Figure 12, Device C and Device D are running SR-MPLS, and Device A, Device B, and Device C are running LDP. Each device running LDP assigns a label to destination address 3.3.3.3/32 and then installs an LDP label forwarding entry.
The following steps establish an association between the SR-MPLS label and the LDP label:
1. After you assign SID index value 201 to the IP address of loopback interface 0 on Device D (3.3.3.3/32), Device D sends an IGP protocol packet to advertise the index value and the local SRGB.
2. After receiving the packet, Device C creates an SR-MPLS label forwarding entry.
The SR-MPLS label and the LDP label are associated on Device C.
Figure 12 LDP to SR packet forwarding
A packet from Device A to Device D is forwarded as follows:
1. Ingress node Device A adds an LDP label (20) to the packet and forwards the packets to the next hop (Device B).
2. Device B searches for an LDP label forwarding entry, uses 30 as the outgoing label, and forwards the packet to the next hop (Device C).
3. Device C searches for an LDP label forwarding entry for incoming label 30 and finds no outgoing label. Because valid SR-MPLS outgoing label 16201 exists for the destination address 3.3.3.3.32, Device C uses the label (16201) as the outgoing label and forwards the packet to Device D.
4. Egress node Device D deletes label 16201 from the packet and forwards the packet by IP address.
SR over LDP
For SR-MPLS networks to communicate across an LDP network, the SR/LDP border devices must be able to connect the SR LSP and the LDP LSP as follows:
· SR-MPLS to LDP interworking—The border device installs SR-to-LDP label forwarding entries. For a packet from the SR-MPLS network to the LDP network, the SR-MPLS label forwarding entry on the border device does not have an outgoing label. The border device uses the outgoing label of the LDP label forwarding entry for the same destination address as the outgoing label of the packet.
· LDP to SR-MPLS interworking—The border device installs LDP-to-SR label forwarding entries. For a packet from the LDP network to the SR-MPLS network, the LDP forwarding entry on the border device does not have an outgoing label. The border device must use the outgoing label of the SR-MPLS forwarding entry for the same destination address as the outgoing label of the packet.
As shown in Figure 13, Device A, Device B, Device D, and Device E are running SR-MPLS. After you assign index value 201 to loopback interface address 3.3.3.3/32 on Device E, Device E will advertise the index value and the local SRGB. After Device A, Device B, and Device D receive the message, they will install their respective SR-MPLS label forwarding entries. Device B, Device C, and Device D are running LDP. They allocate labels to destination address 3.3.3.3/32 to generate the LDP label forwarding entries.
A packet that Device A sends to Device E will be forwarded as follows:
1. Ingress node Device A encapsulates label 16201 to the packet and forwards the packet to transit node Device B.
2. Transit node Device B searches for an SR-MPLS label forwarding entry for incoming label 16201 and finds that the entry does not have an outgoing label. Because an LDP label forwarding entry with outgoing label 20 exists for the destination address (3.3.3.3/32), Device B encapsulates outgoing label 20 in the packet. Then Device B sends the packet to transit node Device C.
3. Device C forwards the packet to Device D based on its LDP label forwarding entries. The outgoing label is 30.
4. Device D searches for an LDP label forwarding entry for incoming label 30 and finds that the entry does not have an outgoing label. Because an SR-MPLS label forwarding entry with outgoing label 16201 exists for the destination address (3.3.3.3/32), Device B encapsulates outgoing label 16201 in the packet. Then Device D sends the packet to egress node Device E.
5. Egress node Device E deletes the incoming label and forwards the packet by IP address.
TI-LFA FRR
Topology-Independent Loop-Free Alternate Fast Re-Route (TI-LFA FRR) provides link and node protection. When a link or node fails, TI-LFA FRR switches the traffic to the backup path to ensure continuous data forwarding.
TI-LFA FRR advantages
SR-based TI-LFA FRR has the following advantages:
· It satisfies the basic requirements for IP FRR fast convergence.
· Traffic protection is not affected by the network environment.
· The algorithm is not too complicated.
· It uses the converged route as the backup path. All devices have finished route convergence before the forward process begins.
TI-LFA FRR concepts
· P space—Use the source node of the protected link as the root to establish a shortest path tree. All nodes that are reachable from the source node without passing the protected link form the P space. Nodes in the P space are called P nodes.
· Extended P space—Use the source node of the protected link and its neighbors as the roots to establish shortest path trees. All nodes that are reachable from the source node or one of its neighbors without passing the protected link form the extended P space. The P space is a subset of the extended P space.
· Q space—Use the destination node of the protected link as the root to establish a reverse shortest path tree. All nodes that are reachable from the root node without passing the protected link form the Q space. Nodes in the Q space are called Q nodes.
· TI-LFA algorithm—In real networks, the P space and Q space do not have common nodes or directly connected nodes. The device cannot calculate the backup path and cannot meet the high availability requirement. The TI-LFA algorithm can calculate the extended P space, Q space, converged shortest path tree, repair list, and backup output interface for the protected link to get the backup next hop.
· Repair list—A constraint path used to indicate how a P node reaches a Q node when the P space and Q space do not have common nodes. The repair list contains the following labels (SIDs):
¡ Labels of P nodes.
¡ Adjacency labels from P nodes to Q nodes.
TI-LFA FRR path calculation
As shown in Figure 14, PE 1 is the source node. P 1 is the faulty node. PE 2 is the destination node. The numbers on links represent the link costs. A data flow traverses PE 1, P 1, and PE 2. To protect data against P 1 failure, TI-LFA FRR calculates the extended P space, Q space, shortest path tree converged after P 1 fails, repair list, and backup output interface, and creates the backup forwarding entry.
TI-LFA FRR calculates the backup path by using the following steps:
1. Calculates the extended P space: P 2.
2. Calculates the Q space: PE 2 and P 4.
3. Calculates the shortest path tree converged after P 1 fails: PE 1 --> P 2 --> P 4 --> PE 2.
4. Calculates the repair list: Node label of P 2 (16030), adjacency label of P 2 to P 3 (2168), and adjacency label of P 3 to P 4 (2178).
5. Calculates the backup output interface, that is, the output interface to the next hop after the link from PE 1 to P 1 fails.
TI-LFA FRR forwarding process
After TI-LFA FRR finishes backup path calculation, traffic will be switched to the backup path in response to a primary path failure.
As shown in Figure 15, P 2 is a P node and P 4 is a Q node. When the next hop on the primary path (P 1) fails, TI-LFA FRR switches the traffic to the backup path. The following are the detailed steps:
1. PE 1 encapsulates a label stack to a packet according to the repair list. The labels, from the outmost to inmost, are as follows:
¡ Node label of P node P2 (16030), which equals the SRGB base value of P 2's next hop plus the SID index value of P 2.
¡ Adjacency labels from P node P2 to Q node P 4, which are 2168 and 2178.
¡ The destination's node label 16010, which equals the SRGB base value of Q node P 4 plus the SID index value of destination node PE 2.
2. P2 receives the packet, searches for a label forwarding entry based on the outmost label, pops label 2168, and forwards the packet to P 3.
3. P3 receives the packet, searches for a label forwarding entry based on the outmost label, pops label 2178, and forwards the packet to P 4.
4. P4 receives the packet, and searches for a label forwarding entry based on the outmost label. Because the outgoing label is 16010 and the next hop is PE 2, P 4 encapsulates 16010 as the outmost label and forwards the packet to PE 2.
Figure 15 Data forwarding over the TI-LFA FRR backup path
Microloop avoidance after a network failure
As shown in Figure 16, when Device B fails, traffic to Device C will be switched to the backup path calculated by TI-LFA. After Device A finishes route convergence, traffic will be switched to the post-convergence path. If Device D and Device F have not finished route convergence and still forward traffic along the pre-convergence path, a loop is formed between Device A and Device F. The loop exists until Device D and Device F finish route convergence.
FRR microloop avoidance and SR microloop avoidance can resolve this issue. After you configure TI-LFA, Device A first switches traffic to the backup path calculated by TI-LFA when Device B fails. Then, Device A waits for Device D and Device F to finish route convergence before starting route convergence. After Device A also finishes route convergence, Device A switches the traffic to the converged route.
Figure 16 Diagram for microloop avoidance after a network failure
Microloop avoidance after a failure recovery
As shown in Figure 17, before the link between Device B and Device C recovers, traffic traverses along the backup path. After the link recovers, Device A will forward the traffic to Device B if Device A finishes route convergence before Device B. Before Device B also finishes route convergence, Device B still forwards the traffic along the backup path. A loop is formed between Device A and Device B.
SR microloop avoidance can resolve this issue. After the link recovers, SR microloop avoidance automatically calculates the optimal path from Device A to Device C and forwards traffic along the path. To forward a packet along the newly calculated path, Device A adds, for example, the adjacency label from Device B to Device C to the packet and then sends the packet to Device B. Then, Device B forwards the packet to Device C based on the path information.
When the microloop avoidance RIB-update-delay timer expires, Device B should have finished route convergence. Device A does not add path information to packets anymore, and it forwards packets to Device C as usual.
Figure 17 Diagram for microloop avoidance after a failure recovery
Protocols and standards
· draft-bashandy-rtgwg-segment-routing-ti-lfa-04
· draft-ietf-spring-segment-routing-mpls-00
· draft-ietf-spring-segment-routing-02
· draft-ietf-isis-segment-routing-extensions-06
· draft-ietf-spring-segment-routing-11
· 3draft-ietf-idr-bgpls-segment-routing-epe-15
· draft-ietf-idr-bgp-prefix-sid-19
· RFC 7752, North-Bound Distribution of Link-State and Traffic Engineering (TE) Information Using BGP
· RFC 8402, Segment Routing Architecture
SR-MPLS tasks at a glance
IP traffic forwarding over SRLSPs tasks at a glance
To forward IP traffic over SRLSPs, perform the following configuration tasks:
1. Configuring segments
Select one of the following tasks:
¡ Configuring IGP-based SID advertisement
2. Configuring the SRLSP establishment triggering policy
3. (Optional.) Configuring the device to prefer SRLSPs in traffic forwarding
4. (Optional.) Configuring IGP SR and LDP interworking
5. (Optional.) Configuring TI-LFA FRR
6. (Optional.) Configuring SR OAM
MPLS TE traffic forwarding over static SRLSPs tasks at a glance
To forward MPLS TE traffic over static SRLSPs, perform the following configuration tasks:
1. Configuring segments
Select one of the following tasks:
¡ Configuring IGP-based SID advertisement
¡ Configuring BGP-based SID advertisement
2. Configuring an MPLS TE tunnel over a static SRLSP
3. (Optional.) Configuring IGP SR and LDP interworking
4. (Optional.) Configuring TI-LFA FRR
5. (Optional.) Configuring SR OAM
MPLS TE traffic forwarding over explicit paths tasks at a glance
To forward MPLS TE traffic over explicit paths, perform the following configuration tasks:
1. Configuring IGP-based SID advertisement
2. Configuring an MPLS TE tunnel over an explicit-path SRLSP
3. (Optional.) Configuring IGP SR and LDP interworking
4. (Optional.) Configuring TI-LFA FRR
5. (Optional.) Configuring SR OAM
MPLS TE traffic forwarding over PCE-calculated SRLSPs tasks at a glance
To forward MPLS TE traffic over PCE-calculated SRLSPs, perform the following configuration tasks:
1. Configuring an MPLS TE tunnel over a PCE-calculated SRLSP
2. (Optional.) Configuring IGP SR and LDP interworking
3. (Optional.) Configuring TI-LFA FRR
4. (Optional.) Configuring SR OAM
Configuring MPLS SRGBs
Restrictions and guidelines
The global MPLS SRGB is used for static prefix segments and BGP prefix SIDs. If no MPLS SRGB is configured for a protocol process, the process uses the global MPLS SRGB.
If you have configured prefix SIDs when you configure an SRGB, the SRGB must contain the configured prefix SIDs.
In the following situations, a configured SRGB takes effect after a device reboot:
· The SRGB contains a label that is already used by another protocol. For example, the SRGB contains a label that is already used by LDP.
· The SRGB overlaps with the label range of another protocol.
Configuring the global MPLS SRGB
1. Enter system view.
system-view
2. Enter segment routing view.
segment-routing
3. Configure the global MPLS SRGB.
global-block { minivalue maxivalue | name name }
By default, the global MPLS SRGB is from 16000 to 55999.
Configuring the MPLS SRGB for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Configure the MPLS SRGB.
segment-routing global-block minivalue maxivalue
By default, the MPLS SRGB for an IS-IS process is the same as the global MPLS SRGB configured in segment routing view.
Configuring the MPLS SRGB for OSPF
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Configure the MPLS SRGB.
segment-routing global-block minivalue maxivalue
By default, the MPLS SRGB for OSPF is the same as the global SRGB.
Configuring the MPLS SRLB
About this task
The segment routing local block (SRLB) is the range of local labels dedicated for SR-MPLS adjacency SIDs.
Restrictions and guidelines
Before configuring the MPLS SRLB, use the display mpls label command to display MPLS label usage information. Make sure that all labels in the specified range are idle. If a label in the range is not idle, the configured MPLS SRLB takes effect only after you save the running configuration and reboot the device. For more information about the display mpls label command, see MPLS Command Reference.
Procedure
1. Enter system view.
system-view
2. Enter segment routing view.
segment-routing
3. Configure the MPLS SRLB.
local-block { minimum-value maximum-value | name name }
By default, the MPLS SRLB is from 15000 to 15999.
Configuring static segments
Prerequisites for configuring static segments
Before you configure static segments, perform the following tasks:
· Determine the ingress node, transit nodes, and egress node of a static SRLSP.
· Determine the incoming label for the adjacency segment from a node to next hop of the node. Determine the incoming label for the destination IP address for the prefix segment on each node. On a device, a static SRLSP, a static LSP, and a static CRLSP cannot use the same incoming label.
· Execute the static-sr-mpls lsp command to create a static SRLSP. Packets forwarded over the static SRLSP will carry the label values in the specified outgoing label list. The nodes of the static CRLSP will pop outgoing label values or insert new labels in sequence.
· Enable MPLS on all nodes and interfaces that will participate in MPLS forwarding. For information about enabling MPLS, see basic MPLS configuration in MPLS Configuration Guide.
Configuring a static adjacency segment
About this task
Perform this task on a node of a static SRLSP to assign an incoming label to a next hop or output interface. After the node receives a packet with that incoming label, it will forward the packet through the corresponding next hop or output interface.
Restrictions and guidelines
This task is required on all nodes of a static SRLSP.
Multiple static SRLSPs can share an adjacency segment.
If you specify the next hop address for a static adjacency segment, make sure the following requirements are met:
· The device has a route to the next hop address.
· MPLS is enabled on the output interface of the route.
If you specify an output interface for a static adjacency segment, make sure the following requirements are met:
· The interface is up.
· The interface can receive direct routes.
· MPLS is enabled on the interface.
A static adjacency segment must use a different incoming label than existing static LSPs, static PWs, and static CRLSPs. If not, the adjacency segment fails to be configured.
If you specify a link local address as the next hop address in an IPv6 static adjacency segment, you must also specify an output interface.
Configuring an IPv4 static adjacency segment
1. Enter system view.
system-view
2. Configure an IPv4 static adjacency segment.
static-sr-mpls adjacency adjacency-path-name in-label label-value { nexthop ip-address | outgoing-interface interface-type interface-number }
The next hop address for a static adjacency segment cannot be a local public IPv4 address.
Configuring an IPv6 static adjacency segment
1. Enter system view.
system-view
2. Configure an IPv6 static adjacency segment.
static-sr-mpls ipv6 adjacency adjacency-path-name in-label label-value { nexthop ipv6-address | outgoing-interface interface-type interface-number } *
The next hop address for a static adjacency segment cannot be a local public IPv6 address.
Configuring a static prefix segment
About this task
Perform this task on a node of a static SRLSP to assign an incoming label and an outgoing label to a destination address. After the node receives a packet with that incoming label, it will pop the incoming label, insert the outgoing label, and forward the packet through the specified next hop or output interface.
If you do not specify the next hop and outgoing label or do not specify the output interface and outgoing label, the device does not insert an outgoing label after popping the incoming label. On the egress node of a static SRLSP, you can perform this task without specifying a next hop, an output interface, and an outgoing label.
Restrictions and guidelines
This task is required on all nodes of a static SRLSP.
Multiple static SRLSPs to the same destination can share a prefix segment.
A prefix segment must use the next hop or output interface of the optimal route (non-BGP route) to the destination address of the prefix segment. You can configure multiple prefix segments to the destination address for load sharing if the optimal route has more than one next hop or output interface. To avoid configuration failure, make sure all prefix segments use the same prefix segment name and incoming label.
A static prefix segment must use a different incoming label than existing static LSPs, static PWs, and static CRLSPs. If not, the prefix segment fails to be configured.
Configuring an IPv4 static prefix segment
1. Enter system view.
system-view
2. Configure a static prefix segment.
static-sr-mpls prefix prefix-path-name destination ip-address { mask-length | mask } in-label in-label-value [ { nexthop ip-address | outgoing-interface interface-type interface-number } out-label out-label-value ]
The next hop address for a static prefix segment cannot be a local public IPv4 address.
Configuring an IPv6 static prefix segment
1. Enter system view.
system-view
2. Configure a static prefix segment.
static-sr-mpls ipv6 prefix prefix-path-name destination ipv6-address prefix-length in-label in-label-value [ { nexthop ipv6-address | outgoing-interface interface-type interface-number } out-label out-label-value ]
The next hop address for a static prefix segment cannot be a local public IPv6 address.
Configuring IGP-based SID advertisement
IGP-based SID advertisement tasks at a glance
IGP-based prefix SID advertisement tasks at a glance
Perform the following tasks on each node along an SRLSP:
1. Configuring the IGP to support SR-MPLS
IGP-based adjacency SID advertisement tasks at a glance(for non-member interfaces)
Perform the following tasks on each node along an SRLSP:
1. Configuring the IGP to support SR-MPLS
2. Enabling SR-MPLS adjacency label allocation for the IGP
The device will allocate SIDs to adjacencies randomly.
3. (Optional.) Assigning adjacency SIDs
You can assign adjacency SIDs to adjacencies manually.
IGP-based adjacency SID advertisement tasks at a glance (for member interfaces)
Perform the following tasks on each node along an SRLSP:
1. Configuring the IGP to support SR-MPLS
2. Enabling SR-MPLS adjacency SID allocation for aggregation group member interfaces
3. (Optional.) Assigning adjacency SIDs to aggregation group member interfaces
You can assign adjacency SIDs to adjacencies on aggregation group member interfaces manually.
Prerequisites for configuring IGP-based SID advertisement
Before you configure IGP-based SID advertisement, perform the following tasks:
· Determine the ingress node, transit nodes, and egress node of an SRLSP.
· Determine the SIDs, MPLS SRGBs, and MPLS SRLBs for nodes.
· Enable MPLS on all nodes and interfaces that will participate in MPLS forwarding. For information about enabling MPLS, see basic MPLS configuration in MPLS Configuration Guide.
Configuring the IGP to support SR-MPLS
Prerequisites
For SR-MPLS to take effect, perform the following tasks before configuring the IGP to support SR-MPLS:
· If the IGP is IS-IS, set the cost style to wide, compatible, or wide-compatible before configuring IS-IS to support SR-MPLS. For more information about the cost style, see IS-IS configuration in Layer 3—IP Routing Configuration Guide.
· If the IGP is OSPF, enable opaque LSA reception and advertisement capability. For more information about the capability, see OSPF configuration in Layer 3—IP Routing Configuration Guide.
Configuring IS-IS to support SR-MPLS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable SR-MPLS.
segment-routing mpls
By default, SR-MPLS is disabled.
Configuring OSPF to support SR-MPLS
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable SR-MPLS.
segment-routing mpls
By default, SR-MPLS is disabled.
Configuring prefix SIDs
About this task
Configuring a prefix SID in loopback interface view binds the SID with the IP address of the loopback interface.
To configure a prefix SID, use one of the following methods:
· Specify an absolute value. The absolute value is used as the prefix SID. The prefix SID takes effect only if the absolute value is in the SRGB of the node.
· Specify an index value. The sum of the index value and the SRGB base value is used as the prefix SID. The prefix SID takes effect only if it is in the SRGB.
Restrictions and guidelines
To use a prefix SID for a group of SR nodes in anycast scenarios, specify the n-flag-clear keyword to set the Node-SID flag bit of the prefix SID to 0.
To configure an IS-IS prefix SID, you must enable an IS-IS process on the loopback interface.
Configuring an IS-IS prefix SID
1. Enter system view.
system-view
2. Enter loopback interface view.
interface loopback interface-number
3. Configure an IS-IS prefix SID.
isis [ process-id process-id ] prefix-sid [ algorithm algorithm-id ] { absolute absolute-value | index index-value } [ n-flag-clear | { explicit-null | no-php } ] *
By default, no IS-IS prefix SID is configured.
Configuring an OSPF prefix SID
1. Enter system view.
system-view
2. Enter loopback interface view.
interface loopback interface-number
3. Configure an OSPF prefix SID.
ospf process-id prefix-sid { absolute absolute-value | index index-value } [ n-flag-clear | { explicit-null | no-php } ] *
By default, no OSPF prefix SID is configured.
Enabling SR-MPLS adjacency label allocation for the IGP
Restrictions and guidelines
For this feature to take effect, you must enable SR-MPLS.
Enabling SR-MPLS adjacency label allocation for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable SR-MPLS adjacency label allocation.
segment-routing adjacency enable
By default, SR-MPLS adjacency label allocation is disabled.
Enabling SR-MPLS adjacency SID allocation for OSPF
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable SR-MPLS adjacency SID allocation.
segment-routing adjacency enable
By default, SR-MPLS adjacency SID allocation is disabled.
Assigning adjacency SIDs
About this task
After you enable SR-MPLS adjacency label allocation, the device randomly allocates adjacency SIDs to the links to its IGP neighbors. If the link to an IGP neighbor flaps, the adjacency SID of the link keeps changing. For a link to always use the same adjacency SID, use this feature to assign a specific adjacency SID to the link.
If you assign the same adjacency SID to the adjacencies on multiple interfaces, multiple forwarding paths are available for adjacency SID-based forwarding. By default, packets are assigned to the adjacencies evenly. If the adjacencies have different bandwidths, you can set the load balancing weights for the adjacencies to avoid congestion. The traffic ratio on an adjacency will be its load balancing weight divided by the total load balancing weights of the adjacencies with the same adjacency SID.
Restrictions and guidelines
To assign adjacency SIDs by using absolute values, make sure the SIDs are in the label range of the SRLB. To assign adjacency SIDs by using index values, make sure the index values plus the base value of the SRLB are in the label range of the SRLB.
The assigned adjacency SIDs take effect after you enable SR-MPLS and SR-MPLS adjacency label allocation.
Prerequisites
Before assigning adjacency SIDs, execute the display mpls label command to display the usage status of the labels that you want to assign as adjacency SIDs. Make sure the labels are in Idle state.
A label that is not in Idle state is being used by another protocol. If you assign it to a link as an adjacency SID, the adjacency SID is not available even if the status of the label changes to Idle later. To use the adjacency SID, you must remove the adjacency SID assignment and assign the adjacency SID again.
Assigning adjacency SIDs to IS-IS adjacencies
1. Enter system view.
system-view
2. Enter interface view.
interface interface-type interface-number
3. Assign an adjacency SID to an IS-IS adjacency.
isis adjacency-sid { absolute absolute-value | index index-value } [ nexthop nexthop-address ]
By default, an IS-IS adjacency does not have an adjacency SID.
4. (Optional.) Set the load balancing weight for an IS-IS adjacency.
isis adjacency-sid weight weight-value
By default, the load balancing weight for an IS-IS adjacency is not set.
Assigning adjacency SIDs to OSPF adjacencies
1. Enter system view.
system-view
2. Enter interface view.
interface interface-type interface-number
3. Assign an adjacency SID to an OSPF adjacency.
ospf adjacency-sid { absolute absolute-value | index index-value } [ nexthop nexthop-address ]
By default, an OSPF adjacency does not have an adjacency SID.
4. (Optional.) Set the load balancing weight for an OSPF adjacency.
ospf adjacency-sid weight weight-value
By default, the load balancing weight for an OSPF adjacency is not set.
Enabling SR-MPLS adjacency SID allocation for aggregation group member interfaces
About this task
In an SR-MPLS domain with Layer 3 aggregate links between SR nodes, you can enable SR-MPLS adjacency SID allocation for aggregation group member interfaces. Then, the system will assign adjacency SIDs to links on member interfaces of a Layer 3 aggregation group so traffic goes out of specific member interfaces. If you do not enable SR-MPLS adjacency SID allocation for aggregation group member interfaces, traffic will be load balanced on all member interfaces in the aggregation group.
Restrictions and guidelines
Before enabling SR-MPLS adjacency SID allocation for aggregation group member interfaces, make sure SR-MPLS is enabled.
Enabling SR-MPLS adjacency SID allocation for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable SR-MPLS adjacency SID allocation for aggregation group member interfaces.
segment-routing member-port adjacency enable
By default, SR-MPLS adjacency SID allocation is disabled for aggregation group member interfaces.
Assigning adjacency SIDs to aggregation group member interfaces
About this task
After you enable adjacency SID allocation for aggregation group member interfaces, the device randomly allocates adjacency SIDs to the links to its IGP neighbors on aggregation group member interfaces. If the link to a neighbor flaps, the adjacency SID of the link keeps changing. For a link to always use the same adjacency SID, you can assign a specific adjacency SID to the link.
Restrictions and guidelines
To assign adjacency SIDs by using absolute values, make sure the SIDs are in the label range of the SRLB. To assign adjacency SIDs by using index values, make sure the index values plus the base value of the SRLB are in the label range of the SRLB.
The assigned adjacency SIDs take effect after you enable SR-MPLS and SR-MPLS adjacency SID allocation for aggregation group member interfaces.
Prerequisites
Before assigning adjacency SIDs, execute the display mpls label command to display the usage status of the labels that you want to assign as adjacency SIDs. Make sure the labels are in Idle state.
A label that is not in Idle state is being used by another protocol. If you assign it to a link as an adjacency SID, the adjacency SID is not available even if the status of the label changes to Idle later. To use the adjacency SID, you must remove the adjacency SID assignment and assign the adjacency SID again.
Assigning adjacency SIDs to IS-IS adjacencies
1. Enter system view.
system-view
2. Enter Layer 3 Ethernet interface view.
interface interface-type interface-number
3. Assign an adjacency SID to an IS-IS adjacency.
isis process-id member-port adjacency-sid { absolute absolute-value | index index-value } nexthop nexthop-address
By default, an IS-IS adjacency does not have an adjacency SID.
Enabling prefix SID conflict checking
About this task
In an SR-MPLS network where multiple downstream devices advertise prefix SIDs in inform of index values to the device through IS-IS routes, the device determines SID conflicts in routes in the following cases:
· Different IP prefixes with the same prefix SID.
· Different prefix SIDs for the same IP prefix.
· Duplicate IP prefix and duplicate prefix SID.
By default, the device does not check SID conflicts when it receives the previous routes and process the routes as follows:
· When the device receives IS-IS routes that contain the same IP prefix and different prefix SIDs, it does not generate label forwarding entries for those routes.
· When the device receives IS-IS routes that contain the same prefix SID and the same or different IP prefixes, the device generates a label forwarding entry for the last of those routes.
If SID conflicts are ignored, the device might not able to detect faults on the network and might generate incorrect label forwarding entries.
After SID conflict checking is enabled, the device checks the SID conflicts and if any conflicts are detected in routes, it does not generate label forwarding entries for the routes.
Procedure
1. Enter system view.
system-view
2. Enable checking for IS-IS prefix SID conflicts.
isis label-conflict-check enable
By default, IS-IS prefix SID conflict checking is disabled.
Configuring BGP-based SID advertisement
BGP-based SID advertisement tasks at a glance
Perform the following tasks on each node along an SRLSP:
1. Configuring BGP to support MPLS SR
2. Configuring BGP prefix SIDs
Prerequisites for configuring BGP-based SID advertisement
Before you configure BGP-based SID advertisement, perform the following tasks:
· Determine the ingress node, transit nodes, and egress node of an SRLSP.
· Determine the index value for the prefix SID of each node:
· Enable MPLS on all nodes and interfaces that will participate in MPLS forwarding. For information about enabling MPLS, see basic MPLS configuration in MPLS Configuration Guide.
Configuring BGP to support MPLS SR
1. Enter system view.
system-view
2. Enable BGP and enter BGP instance view.
bgp as-number [ instance instance-name ]
3. Create the BGP IPv4 unicast address family and enter its view.
address-family ipv4 [ unicast ]
4. Enable SR-MPLS.
segment-routing mpls
By default, SR-MPLS is disabled.
Configuring BGP prefix SIDs
About this task
To configure a BGP prefix SID, use the following methods:
· Instead of specifying a routing policy for route redistribution, use the SID advertised by the IGP as the BGP prefix SID.
· Specify a routing policy for route redistribution. Set the index value for the prefix SID in the routing policy to define the binding between the SID and the prefix.
Restrictions and guidelines
To use BGP routes to exchange prefix SIDs, you must enable BGP peers to exchange labeled routes.
Configuring the device to use the SIDs advertised by the IGP
1. Configure the IGP to support SR-MPLS.
For more information, see "Configuring the IGP to support SR-MPLS."
2. Configure prefix SIDs.
For more information, see "Configuring prefix SIDs."
3. Enter system view.
system-view
4. Enter BGP instance view.
bgp as-number [ instance instance-name ]
5. Enter BGP IPv4 unicast address family view.
address-family ipv4 [ unicast ]
6. Redistribute routes from IS-IS or OSPF.
import-route { isis | ospf } process-id
Specifying a routing policy for route redistribution
1. Enter system view.
system-view
2. Enter BGP instance view.
bgp as-number [ instance instance-name ]
3. Enter BGP IPv4 unicast address family view.
address-family ipv4 [ unicast ]
4. Redistribute routes from IS-IS or OSPF and apply a routing policy to the redistributed routes.
import-route { isis | ospf } process-id route-policy route-policy-name
5. Set the index value for the prefix SID:
a. Return to BGP instance view.
quit
b. Return to system view.
quit
c. Enter the routing policy view.
route-policy route-policy-name { deny | permit } node node-number
d. Specify a label index value.
apply label-index index-value
By default, a routing policy does not have a label index value.
Configuring BGP EPE
About BGP EPE
BGP EPE assigns BGP peering SIDs to segments across ASs. The device sends BGP peering SIDs to the controller through BGP-LS extensions. The controller orchestrates IGP SIDs and BGP peering SIDs for inter-AS forwarding over optimal paths.
After you configure BGP EPE on a device, the device assigns SIDs to connected BGP peers or peer groups to identify the BGP neighbors or links.
Configuring BGP EPE-based SID allocation
Restrictions and guidelines
When you configure BGP EPE, follow these restrictions and guidelines:
· By default, a BGP peering SID is node type.
· If you do not specify a routing policy when enabling BGP EPE, the system will assign labels to BGP peers randomly.
· BGP EPE must be used together with SR-MPLS TE policy, MPLS TE, or static SRLSP. The MPLS TE tunnel requires using a static SRLSP. The outgoing label of the static SRLSP must be the same as the label specified during BGP EPE configuration.
When you use BGP EPE to apply a routing policy to a peer or peer group, follow these restrictions and guidelines:
· You can use the apply label-value command to assign an SID value but cannot use the apply label-index command to assign a label index value.
· You cannot assign the same peer node SID or peer adjacency SID to multiple BGP peers or peer groups.
· You can assign the same set type label to BGP peers or peer groups.
· You can use if-match interface as a filtering condition only when you assign peer adjacency SIDs to BGP peers or peer groups.
Prerequisites
Before assigning BGP-EPE SIDs, execute the display mpls label command to display the usage status of the labels that you want to assign as BGP-EPE SIDs. Make sure the labels are in Idle state. A label that is not in Idle state is being used by another protocol. If you assign it to a peer or peer group as a BGP-EPE SID, the BGP-EPE SID is not available even if the status of the label changes to Idle later. To use the BGP-EPE SID, you must remove the BGP-EPE SID assignment and assign the BGP-EPE SID again.
Procedure
1. Enter system view.
system-view
2. Enter BGP instance view.
bgp as-number [ instance instance-name ]
3. Enable BGP EPE and specify a routing policy for the peer or peer group.
peer { group-name | ipv4-address [ mask-length ] } egress-engineering [ adjacency | node-adjacency ] [ label label-value | route-policy policy-name ] [ link-down relate-bfd-state ]
peer { group-name | ipv4-address [ mask-length ] } egress-engineering [ set ] [ label label-value | route-policy policy-name ]
By default, BGP EPE is disabled.
The link-down relate-bfd-state parameter is used for BGP-EPE to collaborate with SBFD when a link between ASs fails. The node configured with BGP-EPE will send an SBFD response packet to the source node of an SR-MPLS TE policy. After receiving the SBFD response packet, the source node sets the SBFD session detecting the backup path to down and triggers traffic switchover. If you do not specify this parameter, BGP-EPE will not collaborate with SBFD when a link between ASs fails. This parameter must work together with the sr-policy sbfd enable command in SR-TE view or the sbfd command in SR-MPLS TE policy view. For more information about SR-MPLS TE policy, see "Configuring SR-MPLS TE policy."
4. (Optional.) Configure the label value in the routing policy.
a. Return to system view.
quit
b. Enter the routing policy view.
route-policy route-policy-name { deny | permit } node node-number
c. Specify a label value.
apply label-value label-value
By default, no label value is specified.
Configuring a BGP EPE peer set
About this task
If a device has established BGP peer relationships with multiple devices, you can manually add the BGP peers to a BGP EPE peer set and assign a Peer-Set-SID to the set. Then, the device can send traffic to the peers in the set for load sharing when it forwards the traffic based on the Peer-Set-SID.
Prerequisites
Before adding a peer or peer group to a BGP EPE peer set, you must enable BGP EPE for the peer or peer group.
Procedure
1. Enter system view.
system-view
2. Enter BGP instance view.
bgp as-number [ instance instance-name ]
3. Create a BGP EPE peer set.
egress-engineering peer-set peer-set-name [ label label-value ] [ link-down relate-bfd-state ]
The link-down relate-bfd-state parameter is used for BGP-EPE to collaborate with SBFD when a link between ASs fails. The node configured with BGP-EPE will send an SBFD response packet to the source node of an SR-MPLS TE policy. After receiving the SBFD response packet, the source node sets the SBFD session detecting the backup path to down and triggers traffic switchover. If you do not specify this parameter, BGP-EPE will not collaborate with SBFD when a link between ASs fails. This parameter must work together with the sr-policy sbfd enable command in SR-TE view or the sbfd command in SR-MPLS TE policy view. For more information about SR-MPLS TE policy, see "Configuring SR-MPLS TE policy."
4. Add a peer or peer group to the BGP EPE peer set.
peer { group-name | ipv4-address [ mask-length ] } peer-set peer-set-name
By default, a peer or peer group does not belong to a BGP EPE peer set.
Configuring the SRLSP establishment triggering policy
About this task
To save system resources, you can configure the SRLSP establishment triggering policy to allow only certain FECs to trigger SRLSP establishment.
Procedure
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable BGP EPE and specify a routing policy for the peer or peer group.
segment-routing lsp-trigger { host | none | prefix-list prefix-name }
By default, the device allows all FECs to trigger SRLSP establishment.
Configuring the device to prefer SRLSPs in traffic forwarding
About this task
This feature enables the device to preferentially use SRLSPs to forward traffic when both SRLSPs and LDP LSPs are available for traffic forwarding. If you do not configure this feature, the device prefers to use LDP LSPs for traffic forwarding.
Restrictions and guidelines
This feature takes effect only when SR-MPLS is enabled and SRLSPs use prefix SIDs.
Configuring the device to prefer SRLSPs established by IS-IS in traffic forwarding
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Configure the device to prefer SRLSPs in traffic forwarding.
segment-routing sr-prefer [ prefix-list prefix-list-name ]
By default, the device prefers LDP LSPs to SRLSPs.
Configuring the device to prefer SRLSPs established by OSPF in traffic forwarding
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Configure the device to prefer SRLSPs in traffic forwarding.
segment-routing sr-prefer [ prefix-list prefix-list-name ]
By default, the device prefers LDP LSPs to SRLSPs.
Configuring an MPLS TE tunnel over a static SRLSP
Tasks at a glance
1. Enable MPLS TE.
Perform this task on all nodes that the MPLS TE tunnel traverses. For more information, see MPLS TE configuration in MPLS Configuration Guide.
Perform this task on the ingress node of the MPLS TE tunnel.
3. Create the tunnel interface and specify the destination address of the tunnel.
Perform this task on the ingress node of the MPLS TE tunnel. For more information, see MPLS TE configuration in MPLS Configuration Guide.
4. Binding a static SRLSP to an MPLS TE tunnel interface
Perform this task on the ingress node of the MPLS TE tunnel.
5. (Optional.) Configuring the static SRLSP switchback delay time
When an MPLS TE tunnel uses a backup static SRLSP to protect the primary static SRLSP, you can perform this task on the ingress node of the MPLS TE tunnel.
6. Configure static routes or policy-based routing to direct traffic to the MPLS TE tunnel.
Perform this task on the ingress node of the MPLS TE tunnel. For more information, see MPLS TE configuration in MPLS Configuration Guide.
Configuring a static SRLSP
1. Enter system view.
system-view
2. Configure a static SRLSP.
static-sr-mpls lsp lsp-name out-label out-label-value&<1-11>
Binding a static SRLSP to an MPLS TE tunnel interface
1. Enter system view.
system-view
2. Enter MPLS TE tunnel interface view.
interface tunnel tunnel-number [ mode mpls-te ]
3. Set the MPLS TE tunnel establishment mode to static.
mpls te signaling static
By default, MPLS TE uses RSVP-TE to establish a tunnel.
4. Bind a static SRLSP to the MPLS TE tunnel interface.
mpls te static-sr-mpls lsp-name [ backup ]
By default, an MPLS TE tunnel does not use a static SRLSP.
The specified static SRLSP must have been created by using the static-sr-mpls lsp command. To specify a backup static SRLSP by using the backup keyword, make sure both the primary and backup static SRLSPs are established based on adjacency SIDs.
Configuring the static SRLSP switchback delay time
About this task
The switchback delay time refers to the period of time that a TE tunnel waits before it performs a backup-to-primary static SRLSP switchover when the primary static SRLSP recovers.
It might happen that the upstream primary static SRLSP becomes up before the downstream primary static CRLSP becomes up. In this case, if the upstream node switches traffic back to the primary SRLSP, the traffic will be dropped until the primary SRLSP on the downstream node becomes up. Setting a proper switchback delay can resolve this issue.
Procedure
1. Enter system view.
system-view
2. Enter the view of an MPLS TE tunnel interface.
interface tunnel tunnel-number [ mode mpls-te ]
3. Configure the static SRLSP switchback delay time.
mpls te static-sr-mpls wtr delay-time
By default, the static SRLSP switchback delay is 10 seconds.
Configuring an MPLS TE tunnel over an explicit-path SRLSP
Tasks at a glance
Perform the following tasks on the ingress node of the MPLS TE tunnel:
1. Configuring an explicit path for the MPLS TE tunnel
2. Creating an MPLS TE tunnel interface and specifying the destination address.
For more information, see MPLS TE configuration in MPLS Configuration Guide.
3. Configuring an MPLS TE tunnel over the explicit path
Prerequisites
Before you configure an MPLS TE tunnel over an explicit-path SRLSP, perform the following tasks:
· Determine the ingress node of the SRLSP.
· Determine the SIDs of the nodes along the SRLSP.
· Enable MPLS on all nodes and interfaces that will participate in MPLS forwarding. For information about enabling MPLS, see basic MPLS configuration in MPLS Configuration Guide.
Configuring an explicit path for the MPLS TE tunnel
1. Enter system view.
system-view
2. Create an explicit path and enter its view.
explicit-path path-name
3. Add or modify a node in the explicit path.
¡ Specify a node by its label.
nextsid [ index index-number ] label label-value type { adjacency | prefix }
For an adjacency or prefix SID node, specify the label assigned to the next hop for the label-value argument. For a node that uses a BSID, specify the BSID for the MPLS TE tunnel.
¡ Specify a node by its IP address.
nexthop [ index index-number ] ip-address [ exclude | include [ loose | strict ] ]
By default, an explicit path does not include any node.
Configuring an MPLS TE tunnel over the explicit path
1. Enter system view.
system-view
2. Enter MPLS TE tunnel interface view.
interface tunnel tunnel-number mode mpls-te
3. Set the MPLS TE tunnel establishment mode to SR.
mpls te signaling segment-routing
By default, MPLS TE uses RSVP-TE to establish a tunnel.
4. Configure the MPLS TE tunnel interface to use an explicit path.
mpls te path preference value explicit-path path-name [ no-cspf ]
By default, MPLS TE uses the calculated path to establish an SRLSP.
If the specified explicit path includes a BSID, the device uses the routing protocol to calculate the path instead of using CSPF, regardless of whether you specify the no-cspf keyword or not.
You must specify the no-cspf keyword if the specified explicit path is created with the nextsid command and contains an adjacency SID that exists on multiple interfaces.
5. (Optional.) Configure the tunnel interface to perform CSPF calculation strictly based on adjacency SID information when establishing an SRLSP for an MPLS TE tunnel.
mpls te path-selection adjacency-sid
By default, a tunnel interface does not perform CSPF calculation strictly based on adjacency SID information when establishing an SRLSP for an MPLS TE tunnel.
Configuring an MPLS TE tunnel over a PCE-calculated SRLSP
Tasks at a glance
1. Enabling MPLS TE
Perform this task on all nodes that the MPLS TE tunnel traverses. For more information, see MPLS TE configuration in MPLS Configuration Guide.
2. Configuring PCE discovery
Perform this task on all nodes that the MPLS TE tunnel traverses. You can manually specify PCEs or configure dynamic PCE discovery. For more information, see MPLS TE configuration in MPLS Configuration Guide.
3. Establishing a PCEP session that supports SR.
Perform this task on all nodes that the MPLS TE tunnel traverses. Set the PCEP device type to active stateful. For more information, see MPLS TE configuration in MPLS Configuration Guide.
4. Creating an MPLS TE tunnel interface and specifying the destination address.
Perform this task on the ingress node of the MPLS TE tunnel. For more information, see MPLS TE configuration in MPLS Configuration Guide.
5. Configuring an MPLS TE tunnel interface to use PCE to calculate the SRLSP
Perform this task on the ingress node of the MPLS TE tunnel.
Configuring an MPLS TE tunnel interface to use PCE to calculate the SRLSP
1. Enter system view.
system-view
2. Enter MPLS TE tunnel interface view.
interface tunnel tunnel-number mode mpls-te
3. Set the MPLS TE tunnel establishment mode to SR.
mpls te signaling segment-routing
By default, MPLS TE uses RSVP-TE to establish a tunnel.
4. Configure the MPLS TE tunnel interface to use PCE to calculate the SRLSP.
¡ Establish an SRLSP by using the path calculated by PCEs.
mpls te path preference value dynamic [ pce [ ip-address ]&<0-8> ]
By default, the automatically calculated path is used to establish an SRLSP.
¡ Establish an SRLSP by using SRLSP delegation.
mpls te delegation
By default, SRLSP delegation is disabled.
Configuring IGP SR and LDP interworking
Restrictions and guidelines for IGP SR and LDP interworking
To configure IGP SR and LDP interworking, make sure the SRLSP uses prefix SIDs.
SR to LDP tasks at a glance
SRMS tasks at a glance
Perform the following tasks on an SRMS:
1. Enabling SR-MPLS on the SRMS:
a. Configuring the IGP to support SR-MPLS
2. Enabling advertisement of locally configured prefix-SID mappings
3. Configuring prefix-SID mappings
SRMC tasks at a glance
Perform the following tasks on each SRMC:
1. Enabling SR-MPLS on the SRMC:
a. Configuring the IGP to support SR-MPLS
d. Enabling reception of advertised prefix-SID mappings
LDP to SR tasks at a glance
1. Configuring the IGP to support SR-MPLS
SR over LDP tasks at a glance
1. Configuring the IGP to support SR-MPLS
Prerequisites for SR-MPLS and LDP internetworking
Before you configure SR-MPLS and LDP internetworking, perform the following tasks:
· Determine the ingress node, transit nodes, and egress node of an SRLSP.
· Determine the index value for the prefix SID of each node.
· Enable MPLS on all nodes and interfaces that will participate in MPLS forwarding. For information about enabling MPLS, see basic MPLS configuration in MPLS Configuration Guide.
Enabling advertisement of locally configured prefix-SID mappings
Restrictions and guidelines
Configure this feature on the device that acts as the SRMS.
Configuring IS-IS to advertise locally configured prefix-SID mappings
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable advertisement of locally configured prefix-SID mappings.
segment-routing mapping-server advertise-local
By default, advertisement is disabled for locally configured prefix-SID mappings.
Configuring OSPF to advertise locally configured prefix-SID mappings
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable advertisement of locally configured prefix-SID mappings.
segment-routing mapping-server advertise-local
By default, advertisement is disabled for locally configured prefix-SID mappings.
Configuring prefix-SID mappings
Restrictions and guidelines
Configure this feature on the device that acts as the SRMS.
The specified prefixes must not belong to any existing prefix-SID mappings.
Prerequisites
Before you configure prefix-SID mappings in bulk, plan the number of mappings carefully.
Procedure
1. Enter system view.
system-view
2. Enable SR and enter segment routing view.
segment-routing
3. Configure a prefix-SID mapping.
mapping-server prefix-sid-map ip-address mask-length start-value [ range range-value ] [ attached ]
By default, no prefix-SID mappings exist.
If you specify a value greater than 65535 for the range-value argument, the prefix-SID mappings cannot be advertised through IS-IS or OSPF.
Enabling reception of advertised prefix-SID mappings
Restrictions and guidelines
Configure this feature on the devices that act as the SRMCs.
Configuring IS-IS to receive advertised prefix-SID mappings
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable reception of prefix-SID mappings.
segment-routing mapping-server receive
By default, reception of prefix-SID mappings is enabled.
Configuring OSPF to receive advertised prefix-SID mappings
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable reception of prefix-SID mappings.
segment-routing mapping-server receive
By default, reception of prefix-SID mappings is enabled.
Configuring TI-LFA FRR
Restrictions and guidelines for TI-LFA FRR
TI-LFA FRR is not supported on static SR networks.
In SR-MPLS and LDP interworking scenarios, you must configure the device to prefer the IS-IS or OSPF SRLSP to the LDP LSP. This rule ensures the effectiveness of the TI-LFA FRR backup next hop.
TI-LFA FRR tasks at a glance
2. (Optional.) Disabling an interface from participating in TI-LFA calculation
On the source node, disable TI-LFA on the route's output interface to the next hop on the primary path.
3. (Optional.) Configuring microloop avoidance
Enabling TI-LFA FRR
Enabling TI-LFA FRR for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable LFA FRR for IS-IS.
fast-reroute lfa [ level-1 | level-2 ]
By default, LFA FRR is disabled for IS-IS.
5. Enable TI-LFA FRR for IS-IS.
fast-reroute ti-lfa [ per-prefix ] [ route-policy route-policy-name | host ] [ level-1 | level-2 ]
By default, TI-LFA FRR is disabled for IS-IS.
6. (Optional.) Set the priority for the lowest-cost, node-protection, or SRLG-disjoint backup path selection policy.
fast-reroute tiebreaker { lowest-cost | node-protecting | srlg-disjoint } preference preference
By default, the priority values of the lowest-cost, node-protection, and SRLG-disjoint backup path selection policies are 20, 40, and 10, respectively.
Enabling TI-LFA FRR for OSPF
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable LFA FRR for OSPF.
fast-reroute { lfa [ abr-only ] | route-policy route-policy-name }
By default, LFA FRR is disabled for OSPF.
4. Enable TI-LFA FRR for OSPF.
fast-reroute ti-lfa [ per-prefix ] [ route-policy route-policy-name | host ]
By default, TI-LFA FRR is disabled for OSPF.
5. (Optional.) Set the priority for the lowest-cost, node-protection, or SRLG-disjoint backup path selection policy.
fast-reroute tiebreaker { lowest-cost | node-protecting | srlg-disjoint } preference preference
By default, the priority values of the lowest-cost, node-protection, and SRLG-disjoint backup path selection policies are 20, 40, and 10, respectively.
Disabling an interface from participating in TI-LFA calculation
Disabling an IS-IS interface from participating in TI-LFA calculation
1. Enter system view.
system-view
2. Enter the view of IS-IS interface.
interface interface-type interface-number
3. Disable the interface from participating in TI-LFA calculation.
isis fast-reroute ti-lfa disable [ level-1 | level-2 ]
By default, an IS-IS interface participates in TI-LFA calculation.
Disabling an OSPF interface from participating in TI-LFA calculation
1. Enter system view.
system-view
2. Enter the view of OSPF interface.
interface interface-type interface-number
3. Disable the interface from participating in TI-LFA calculation.
ospf fast-reroute ti-lfa disable
By default, an OSPF interface participates in TI-LFA calculation.
Configuring microloop avoidance
About this task
The following microloop avoidance methods are available:
· FRR microloop avoidance—Provides microloop avoidance after a network failure.
On a network deployed with TI-LFA FRR, when a node or link fails, traffic will be switched to the backup path calculated by TI-LFA. If devices on the backup path have not finished route convergence, a loop is formed between the source node (failed node or the previous node along the link) and a device on the backup path. The loop exists until the devices on the backup path finish route convergence.
To resolve this issue, FRR microloop avoidance first switches traffic to the backup path calculated by TI-LFA after the node or link failure. Then, the source node waits for the nodes on the backup path to finish route convergence before starting route convergence.
· SR microloop avoidance—Provides microloop avoidance both after a network failure and after a failure recovery.
After a network failure occurs or recovers, route convergence occurs on relevant network devices. Because of non-simultaneous convergence on network devices, microloops might be formed. After you configure SR microloop avoidance, the devices will forward traffic along the specified path before route convergence is finished on all the relevant network devices. Because the forwarding path is independent of route convergence, microloops are avoided. The specific process is as follows:
¡ After a network failure occurs, the device installs the calculated forwarding path to the FIB and switches to the forwarding path after a delay time. During the delay time, the device still uses the TI-LFA FRR backup path.
¡ After a network failure recovers, the device calculates an active path and a backup path with a SID. During the delay time, the device still uses the backup path.
To leave sufficient time for IGP to finish route convergence, set the SR microloop avoidance RIB-update-delay timer. Before the timer expires, failure relevant devices will forward traffic along the specified path. After the timer expires, IGP route convergence should have finished and traffic will traverse along the IGP-calculated path.
Restrictions and guidelines
For OSPF, if you configure both FRR microloop avoidance and SR microloop avoidance, both timers are started and SR microloop avoidance takes effect.
· The value of the delay timer of SR microloop avoidance is greater than or equal to the value of the delay timer of FRR microloop avoidance, the device switches to the converged path immediately after the delay timer of the former expires.
· The value of the delay timer of SR microloop avoidance is smaller than or equal to the value of the delay timer of FRR microloop avoidance, the device switches to the converged path after the delay timer of the latter expires.
For IS-IS, if you configure both FRR microloop avoidance and SR microloop avoidance, both timers are started and FRR microloop avoidance takes effect.
· The value of the delay timer of FRR microloop avoidance is greater than or equal to the value of the delay timer of SR microloop avoidance, the device switches to the converged path immediately after the delay timer of the latter expires.
· The value of the delay timer of FRR microloop avoidance is smaller than or equal to the value of the delay timer of SR microloop avoidance, the device switches to the converged path after the delay timer of the former expires.
Configuring FRR microloop avoidance for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable FRR microloop avoidance for IS-IS.
fast-reroute microloop-avoidance enable [ level-1 | level-2 ]
By default, FRR microloop avoidance is disabled for IS-IS.
5. (Optional.) Set the FRR microloop avoidance RIB-update-delay time.
fast-reroute microloop-avoidance rib-update-delay delay-time [ level-1 | level-2 ]
By default, the FRR microloop avoidance RIB-update-delay time is 5000 ms.
Configuring FRR microloop avoidance for OSPF
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable FRR microloop avoidance for OSPF.
fast-reroute microloop-avoidance enable
By default, FRR microloop avoidance is disabled for OSPF.
4. (Optional.) Set the FRR microloop avoidance RIB-update-delay time.
fast-reroute microloop-avoidance rib-update-delay delay-time
By default, the FRR microloop avoidance RIB-update-delay time is 5000 ms.
Configuring SR microloop avoidance for IS-IS
1. Enter system view.
system-view
2. Enter IS-IS view.
isis process-id
3. Enter IS-IS IPv4 unicast address family view.
address-family ipv4
4. Enable SR microloop avoidance for IS-IS.
segment-routing microloop-avoidance enable [ level-1 | level-2 ]
By default, SR microloop avoidance is disabled for IS-IS.
5. (Optional.) Set the SR microloop avoidance RIB-update-delay time.
segment-routing microloop-avoidance rib-update-delay delay-time [ level-1 | level-2 ]
By default, the SR microloop avoidance RIB-update-delay time is 5000 ms.
Configuring SR microloop avoidance for OSPF
1. Enter system view.
system-view
2. Enter OSPF view.
ospf process-id
3. Enable SR microloop avoidance for OSPF.
segment-routing microloop-avoidance enable
By default, SR microloop avoidance is disabled for OSPF.
4. (Optional.) Set the SR microloop avoidance RIB-update-delay time for OSPF.
segment-routing microloop-avoidance rib-update-delay delay-time
By default, the SR microloop avoidance RIB-update-delay time is 5000 ms.
Configuring SR OAM
Configuring BFD for SRLSPs
About this task
This feature enables the device to create a BFD session for each primary SRLSP to verify the connectivity of the primary SRLSPs. When a primary SRLSP fails, BFD can quickly detect the failure and switches traffic to the backup SRLSP to reduce packet loss.
Restrictions and guidelines
Before you execute this command, enable MPLS BFD by using the mpls bfd enable command.
If you execute both the bfd enable command and the mpls bfd command for SRLSPs, the mpls bfd command takes effect on the SRLSPs.
Procedure
1. Enter system view.
system-view
2. Enter segment routing view.
segment-routing
3. Enable BFD to verify SRLSP connectivity.
bfd enable [ prefix-list prefix-list-name ] [ echo | nil-fec ]
By default, BFD is not enabled to verify SRLSP connectivity.
4. Configure the BFD session parameters for verifying SRLSP connectivity:
¡ Configure the BFD detection time multiplier.
bfd detect-multiplier value
By default, the BFD detection time multiplier is not set for SRLSPs. The BFD detection time multiplier set by the bfd multi-hop detect-multiplier command applies.
¡ Configure the minimum interval for receiving BFD packets.
bfd min-receive-interval interval
By default, the minimum interval for receiving BFD packets is not set. The interval set by the bfd multi-hop min-receive-interval command applies.
¡ Configure the minimum interval for transmitting BFD packets.
bfd min-transmit-interval interval
By default, the minimum interval for transmitting BFD packets is not set. The interval set by the bfd multi-hop min-transmit-interval command applies.
¡ Configure the minimum interval for receiving BFD echo packets.
bfd min-echo-receive-interval interval
By default, the minimum interval for receiving BFD echo packets is not set. The interval set by the bfd multi-hop min-echo-receive-interval command applies.
See High Availability Command Reference for more information about the following BFD commands: bfd multi-hop detect-multiplier, bfd multi-hop min-receive-interval, bfd multi-hop min-transmit-interval, and bfd multi-hop min-echo-receive-interval.
Configuring SBFD for SRLSPs
About this task
This feature enables the device to create an SBFD session for each primary SRLSP to verify the connectivity of the primary SRLSPs. When a primary SRLSP fails, BFD can quickly detect the failure and switches traffic to the backup SRLSP to reduce packet loss.
Restrictions and guidelines
Before you configure this feature, enable MPLS BFD by using the mpls bfd enable command.
After you configure this feature, the local end uses the destination address of an SRLSP as the remote discriminator to establish an SBFD session for the SRLSP. Make sure you specify the local discriminator of the SBFD session on the remote end as the SRLSP's destination address by using the sbfd local-discriminator command.
If you execute both the sbfd enable command and the mpls sbfd command for SRLSPs, the mpls sbfd command takes effect on the SRLSPs.
Procedure
1. Enter system view.
system-view
2. Enter segment routing view.
segment-routing
3. Enable SBFD to verify SRLSP connectivity.
sbfd enable [ prefix-list prefix-list-name ]
By default, SBFD is not enabled to verify SRLSP connectivity.
4. Configure the SBFD session parameters for verifying SRLSP connectivity:
¡ Configure the SBFD detection time multiplier.
sbfd detect-multiplier value
By default, the SBFD detection time multiplier is not set for SRLSPs. The multiplier set by the bfd multi-hop detect-multiplier command applies.
¡ Configure the minimum interval for receiving SBFD packets.
sbfd min-receive-interval interval
By default, the minimum interval for receiving SBFD packets is not set. The interval set by the bfd multi-hop min-receive-interval command applies.
¡ Configure the minimum interval for transmitting SBFD packets.
sbfd min-transmit-interval interval
By default, the minimum interval for transmitting SBFD packets is not set. The interval set by the bfd multi-hop min-transmit-interval command applies.
See High Availability Command Reference for more information about the following BFD commands: bfd multi-hop detect-multiplier, bfd multi-hop min-receive-interval, and bfd multi-hop min-transmit-interval.
Configuring tunnel BFD for all SRLSPs
About this task
This task establishes tunnel BFD sessions to verify the connectivity of all SRLSPs.
A tunnel BFD session is established for primary and backup SRLSPs of a specific FEC (destination IP/mask). The BFD session is up as long as an SRLSP is available for the FEC. If both the primary and backup SRLSPs for the FEC are unavailable, the BFD session goes down. BFD then quickly triggers a protection measure (such as MPLS L3VPN FRR) to switch traffic to other forwarding paths to reduce traffic loss.
Tunnel BFD verifies SRLSP connectivity as follows:
1. Establishes a BFD session between the ingress and egress of the tunnel to be verified.
2. Inserts labels for the SRLSPs into to the BFD control packets on the ingress.
3. Forwards the BFD control packets to the egress over the SRLSPs.
4. Determines the connectivity of the SRLSPs according to the BFD control packets returned by the egress.
Restrictions and guidelines
If you configure both the mpls tunnel-bfd command for an SRLSP and the tunnel-bfd enable command for all SRLSPs, the mpls tunnel-bfd command takes effect for that SRLSP.
Procedure
1. Enter system view.
system-view
2. Enter segment routing view.
segment-routing
3. Enable tunnel BFD to verify the connectivity of all SRLSPs.
tunnel-bfd enable [ prefix-list prefix-list-name ] [ echo | nil-fec ]
By default, tunnel BFD is not enabled to verify SRLSP connectivity.
4. Configure the tunnel BFD session parameters for verifying SRLSP connectivity:
¡ Configure the tunnel BFD detection time multiplier.
tunnel-bfd detect-multiplier value
By default, the tunnel BFD detection time multiplier is not set and the multiplier set by the bfd multi-hop detect-multiplier command applies.
¡ Configure the minimum interval for receiving BFD packets.
tunnel-bfd min-receive-interval interval
By default, the minimum receive interval is not set, and the interval set by the bfd multi-hop min-receive-interval command applies.
¡ Configure the minimum interval for transmitting BFD packets.
tunnel-bfd min-transmit-interval interval
By default, the minimum transmit interval is not set, and the interval set by the bfd multi-hop min-transmit-interval command applies.
¡ Configure the minimum interval for receiving BFD echo packets.
tunnel-bfd min-echo-receive-interval interval
By default, the minimum interval for receiving BFD echo packets is not set, and the interval set by the bfd multi-hop min-echo-receive-interval command applies.
For more information about the bfd multi-hop detect-multiplier, bfd multi-hop min-receive-interval, bfd multi-hop min-transmit-interval, and bfd multi-hop min-echo-receive-interval commands, see BFD commands in High Availability Command Reference.
Verifying and maintaining SR-MPLS
Displaying SR label block information
Perform display tasks in any view.
· Display SR-MPLS label block information.
display segment-routing label–block [ protocol { isis | ospf } ]
· Display prefix-SID mappings.
display segment-routing mapping-server prefix-sid-map [ ip-address mask-length | verbose ]
Displaying static segments
Perform display tasks in any view.
· Display static SRLSP information.
display mpls static-sr-mpls lsp [ lsp-name ]
· Display IPv4 static adjacency segment information.
display mpls static-sr-mpls adjacency [ adjacency-path-name ]
· Display IPv6 static adjacency segment information.
display mpls static-sr-mpls ipv6 adjacency [ adjacency-path-name ]
· Display IPv4 static prefix segment information.
display mpls static-sr-mpls prefix [ path prefix-path-name | destination ipv4-address [ mask | mask-length ] ]
· Display IPv6 static prefix segment information.
display mpls static-sr-mpls ipv6 prefix [ path prefix-path-name | destination ipv6-address prefix-length ]
Displaying BGP SR configuration and status information
Perform display tasks in any view.
· Display BGP-EPE segment information.
display bgp [ instance instance-name ] egress-engineering ipv4 [ ipv4-address ] [ verbose ]
· Display BGP-EPE peer set information
display bgp [ instance instance-name ] egress-engineering peer-set [ peer-set-name ]
· Display BGP SR label ranges.
display bgp [ instance instance-name ] segment-routing label-range
Displaying IS-IS SR configuration and status information
Perform display tasks in any view.
· Display IS-IS SRGB information.
display isis segment-routing global-block [ level-1 | level-2 ] [ process-id ]
· Display IS-IS SR adjacency segment information.
display isis [ process-id ] segment-routing adjacency [ { member-port | non-member-port } | sid sid-value | vpn-instance vpn-instance-name ] *
· Display IS-IS SR prefix-SID mappings.
display isis segment-routing prefix-sid-map [ active-policy | backup-policy ] [ process-id ] [ verbose ]
· Display IS-IS SR routing information.
display isis segment-routing routing-table [ vpn-instance vpn-instance-name ] [ ip ip-address { mask-length | mask } ] [ flex-algo flex-algo-id ]
Displaying OSPF SR configuration and status information
Perform display tasks in any view.
· Display OSPF SRGB information.
display ospf [ process-id ] [ area area-id ] segment-routing global-block
· Display OSPF SR adjacency segment information.
display ospf [ process-id ] segment-routing adjacency [ sid sid-value ] [ vpn-instance vpn-instance-name ]
· Display OSPF SR prefix-SID mappings.
display ospf segment-routing prefix-sid-map [ active-policy | backup-policy ] [ process-id ] [ verbose ]
· Display OSPF SR routing information.
display ospf segment-routing routing-table [ vpn-instance vpn-instance-name ] [ ip ip-address { mask-length | mask } ]
Displaying SRLSP configuration and status information
Perform display tasks in any view.
· Display path information for SR-MPLS TE tunnels.
display mpls te segment-routing tunnel path [ tunnel number ]
· Display SRLSP event information for MPLS TE tunnels.
display mpls te tunnel lsp-event { down | switch } [ tunnel number ]
SR-MPLS configuration examples
Example: Configuring SR-MPLS based on static segments
Network configuration
As shown in Figure 18, Router A, Router B, Router C, Router D, and Router E run IS-IS.
Establish an MPLS TE tunnel over a static SRLSP from Router A to Router D to transmit data between the IP networks. The static SRLSP traverses three adjacency segments: Router A—Router B, Router B—Router C, and Router C—Router D.
Establish an MPLS TE tunnel over a static SRLSP from Router A to Router E to transmit data between the IP networks. The static SRLSP traverses three segments: Router A—Router B (adjacency segment), Router B—Router C (prefix segment), and Router C—Router E (adjacency segment).
Table 1 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop0 |
1.1.1.9/32 |
Router B |
Loop0 |
2.2.2.9/32 |
|
HGE1/0/1 |
100.1.1.1/24 |
|
HGE1/0/1 |
10.1.1.2/24 |
|
HGE1/0/2 |
10.1.1.1/24 |
|
HGE1/0/2 |
20.1.1.1/24 |
|
|
|
|
HGE1/0/3 |
60.1.1.1/24 |
Router C |
Loop0 |
3.3.3.9/32 |
Router D |
Loop0 |
4.4.4.9/32 |
|
HGE1/0/1 |
30.1.1.1/24 |
|
HGE1/0/1 |
100.1.2.1/24 |
|
HGE1/0/2 |
20.1.1.2/24 |
|
HGE1/0/2 |
30.1.1.2/24 |
|
HGE1/0/3 |
50.1.1.1/24 |
|
|
|
|
HGE1/0/4 |
60.1.1.2/24 |
|
|
|
Router E |
Loop0 |
5.5.5.9/32 |
|
|
|
|
HGE1/0/1 |
200.1.2.1/24 |
|
|
|
|
HGE1/0/2 |
50.1.1.2/24 |
|
|
|
Prerequisites
1. Configure IP addresses and masks for interfaces.
2. Configure IS-IS to advertise interface addresses, including the loopback interface address.
3. Execute the display ip routing-table command on each router to verify that the routers have learned the routes to one another, including the routes to the loopback interfaces.
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure LSR IDs, and enable MPLS and MPLS TE:
# Configure Router A.
<RouterA> system-view
[RouterA] mpls lsr-id 1.1.1.9
[RouterA] mpls te
[RouterA-te] quit
[RouterA] interface hundredgige 1/0/2
[RouterA-HundredGigE1/0/2] mpls enable
[RouterA-HundredGigE1/0/2] quit
# Configure Router B.
<RouterB> system-view
[RouterB] mpls lsr-id 2.2.2.9
[RouterB] mpls te
[RouterB-te] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] mpls enable
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface hundredgige 1/0/3
[RouterB-HundredGigE1/0/3] mpls enable
[RouterB-HundredGigE1/0/3] quit
# Configure Router C.
<RouterC> system-view
[RouterC] mpls lsr-id 3.3.3.9
[RouterC] mpls te
[RouterC-te] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface hundredgige 1/0/3
[RouterC-HundredGigE1/0/3] mpls enable
[RouterC-HundredGigE1/0/3] quit
[RouterC] interface hundredgige 1/0/4
[RouterC-HundredGigE1/0/4] mpls enable
[RouterC-HundredGigE1/0/4] quit
# Configure Router D.
<RouterD> system-view
[RouterD] mpls lsr-id 4.4.4.9
[RouterD] mpls te
[RouterD-te] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] mpls enable
[RouterD-HundredGigE1/0/2] quit
# Configure Router E.
<RouterE> system-view
[RouterE] mpls lsr-id 5.5.5.9
[RouterE] mpls te
[RouterE-te] quit
[RouterE] interface hundredgige 1/0/2
[RouterE-HundredGigE1/0/2] mpls enable
[RouterE-HundredGigE1/0/2] quit
2. Configure adjacency and prefix segments on the nodes:
# On Router A, create adjacency segment adjacency-1, and bind incoming label 16 to next hop address 10.1.1.2.
[RouterA] static-sr-mpls adjacency adjacency-1 in-label 16 nexthop 10.1.1.2
# On Router B, create adjacency segment adjacency-2, and bind incoming label 21 to next hop address 20.1.1.2.
[RouterB] static-sr-mpls adjacency adjacency-2 in-label 21 nexthop 20.1.1.2
# On Router B, create prefix segments named prefix-1 to destination IP address 5.5.5.9, bind incoming label 16000 to next hop addresses 20.1.1.2 and 60.1.1.2, and specify the outgoing label as 16001.
[RouterB] static-sr-mpls prefix prefix-1 destination 5.5.5.9 32 in-label 16000 nexthop 20.1.1.2 out-label 16001
[RouterB] static-sr-mpls prefix prefix-1 destination 5.5.5.9 32 in-label 16000 nexthop 60.1.1.2 out-label 16001
# On Router C, create adjacency segment adjacency-1, and bind incoming label 30 to next hop address 30.1.1.2. Create adjacency segment adjacency-2, and bind incoming label 31 to next hop address 50.1.1.2.
[RouterC] static-sr-mpls adjacency adjacency-1 in-label 30 nexthop 30.1.1.2
[RouterC] static-sr-mpls adjacency adjacency-2 in-label 31 nexthop 50.1.1.2
# On Router C, create prefix segment named prefix-1 to destination IP address 5.5.5.9, and specify the incoming label as 16001.
[RouterC] static-sr-mpls prefix prefix-1 destination 5.5.5.9 32 in-label 16001
3. On Router A, establish static SRLSP static-sr-lsp-1 to Router D and static SRLSP static-sr-lsp-2 to Router E:
# Configure Router A as the ingress node of static SRLSP static-sr-lsp-1 and configure a label stack of [16, 21, 30].
[RouterA] static-sr-mpls lsp static-sr-lsp-1 out-label 16 21 30
# Configure Router A as the ingress node of static SRLSP static-sr-lsp-2 and configure a label stack of [16, 16000, 31].
[RouterA] static-sr-mpls lsp static-sr-lsp-2 out-label 16 16000 31
4. Configure MPLS TE tunnels over static SRLSPs on Router A:
# Establish static MPLS TE tunnel 0 to Router D and specify the tunnel destination address as the LSR ID of Router D. Bind static SRLSP static-sr-lsp-1 to MPLS TE tunnel interface 0.
[RouterA] interface tunnel 0 mode mpls-te
[RouterA-Tunnel0] ip address 6.1.1.1 255.255.255.0
[RouterA-Tunnel0] destination 4.4.4.9
[RouterA-Tunnel0] mpls te signaling static
[RouterA-Tunnel0] mpls te static-sr-mpls static-sr-lsp-1
[RouterA-Tunnel0] quit
# Establish static MPLS TE tunnel 1 to Router E and specify the tunnel destination address as the LSR ID of Router E. Bind static SRLSP static-sr-lsp-2 to MPLS TE tunnel interface 1.
[RouterA] interface tunnel 1 mode mpls-te
[RouterA-Tunnel1] ip address 7.1.1.1 255.255.255.0
[RouterA-Tunnel1] destination 5.5.5.9
[RouterA-Tunnel1] mpls te signaling static
[RouterA-Tunnel1] mpls te static-sr-mpls static-sr-lsp-2
[RouterA-Tunnel1] quit
5. On Router A, configure two static routes to direct traffic destined for 100.1.2.0/24 and 200.1.2.0/24 to MPLS TE tunnel 0 and tunnel 1, respectively.
[RouterA] ip route-static 100.1.2.0 24 tunnel 0 preference 1
[RouterA] ip route-static 200.1.2.0 24 tunnel 1 preference 1
Verifying the configuration
# Display static SRLSP establishment on each router by using the display mpls lsp or display mpls static-sr-lsp command.
[RouterA] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
1.1.1.9/0/1 StaticCR -/21 HGE1/0/1
30
1.1.1.9/1/2 StaticCR -/16000 HGE1/0/1
31
[RouterB] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
- StaticCR 21/- HGE1/0/2
5.5.5.9/32 StaticCR 16000/16001 HGE1/0/2
5.5.5.9/32 StaticCR 16000/16001 HGE1/0/4
[RouterC] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
- StaticCR 30/- HGE1/0/1
- StaticCR 31/- HGE1/0/3
5.5.5.9/32 StaticCR 16001/- -
Example: Configuring SR-MPLS based on ISIS-advertised SIDs
Network configuration
As shown in Figure 19, Router A, Router B, Router C, and Router D are running IS-IS.
Configure dynamic SID allocation on loopback interfaces of the routers. Then, establish an SRLSP from Router A to Router D based on the allocated SIDs and configure an MPLS TE tunnel over the SRLSP to transmit data.
Table 2 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
|
|
|
|
|
HGE1/0/2 |
11.0.0.1/24 |
Router C |
Loop1 |
3.3.3.3/32 |
Router D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
HGE1/0/1 |
12.0.0.2/24 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/2 |
100.1.2.1/24 |
Prerequisites
Configure IP addresses and masks for interfaces.
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IS-IS on the routers and set the IS-IS cost style to wide:
# Configure Router A.
<RouterA> system-view
[RouterA] isis 1
[RouterA-isis-1] network-entity 00.0000.0000.0001.00
[RouterA-isis-1] cost-style wide
[RouterA-isis-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] isis enable 1
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis enable 1
[RouterA-LoopBack1] quit
# Configure Router B.
<RouterB> system-view
[RouterB] isis 1
[RouterB-isis-1] network-entity 00.0000.0000.0002.00
[RouterB-isis-1] cost-style wide
[RouterB-isis-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] isis enable 1
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] isis enable 1
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis enable 1
[RouterB-LoopBack1] quit
# Configure Router C.
<RouterC> system-view
[RouterC] isis 1
[RouterC-isis-1] network-entity 00.0000.0000.0003.00
[RouterC-isis-1] cost-style wide
[RouterC-isis-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] isis enable 1
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] isis enable 1
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis enable 1
[RouterC-LoopBack1] quit
# Configure Router D.
<RouterD> system-view
[RouterD] isis 1
[RouterD-isis-1] network-entity 00.0000.0000.0004.00
[RouterD-isis-1] cost-style wide
[RouterD-isis-1] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] isis enable 1
[RouterD-HundredGigE1/0/1] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] isis enable 1
[RouterD-HundredGigE1/0/2] quit
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis enable 1
[RouterD-LoopBack1] quit
2. Configure LSR IDs, and enable MPLS and MPLS TE on the routers:
# Configure Router A.
[RouterA] mpls lsr-id 1.1.1.1
[RouterA] mpls te
[RouterA-te] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] mpls enable
[RouterA-HundredGigE1/0/1] quit
# Configure Router B.
[RouterB] mpls lsr-id 2.2.2.2
[RouterB] mpls te
[RouterB-te] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] mpls enable
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] quit
# Configure Router C.
[RouterC] mpls lsr-id 3.3.3.3
[RouterC] mpls te
[RouterC-te] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] quit
# Configure Router D.
[RouterD] mpls lsr-id 4.4.4.4
[RouterD] mpls te
[RouterD-te] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] mpls enable
[RouterD-HundredGigE1/0/1] quit
3. Enable SR-MPLS on the routers:
# Configure Router A.
[RouterA] isis 1
[RouterA-isis-1] address-family ipv4
[RouterA-isis-1-ipv4] segment-routing mpls
[RouterA-isis-1-ipv4] quit
[RouterA-isis-1] quit
# Configure Router B.
[RouterB] isis 1
[RouterB-isis-1] address-family ipv4
[RouterB-isis-1-ipv4] segment-routing mpls
[RouterB-isis-1-ipv4] quit
[RouterB-isis-1] quit
# Configure Router C.
[RouterC] isis 1
[RouterC-isis-1] address-family ipv4
[RouterC-isis-1-ipv4] segment-routing mpls
[RouterC-isis-1-ipv4] quit
[RouterC-isis-1] quit
# Configure Router D.
[RouterD] isis 1
[RouterD-isis-1] address-family ipv4
[RouterD-isis-1-ipv4] segment-routing mpls
[RouterD-isis-1-ipv4] quit
[RouterD-isis-1] quit
4. Configure IS-IS prefix SIDs for the routers:
# Configure Router A.
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis prefix-sid index 10
# Configure Router B.
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis prefix-sid index 20
# Configure Router C.
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis prefix-sid index 30
# Configure Router D.
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis prefix-sid index 40
5. On Router A, establish static SRLSP static-sr-lsp-1 to Router D and configure an MPLS TE tunnel over the static SRLSP:
# Configure Router A as the ingress node of static SRLSP static-sr-lsp-1 and specify the prefix label that Router A allocated to Router D (16040) as the outgoing label.
[RouterA] static-sr-mpls lsp static-sr-lsp-1 out-label 16040
# Establish static MPLS TE tunnel 1 to Router D and specify the LSR ID of Router D as the tunnel destination address. Bind static SRLSP static-sr-lsp-1 to MPLS TE tunnel interface 1.
[RouterA] interface tunnel 1 mode mpls-te
[RouterA-Tunnel1] ip address 6.1.1.1 255.255.255.0
[RouterA-Tunnel1] destination 4.4.4.4
[RouterA-Tunnel1] mpls te signaling static
[RouterA-Tunnel1] mpls te static-sr-mpls static-sr-lsp-1
[RouterA-Tunnel1] quit
6. On Router A, configure a static route to direct traffic destined for 100.1.2.0/24 to MPLS TE tunnel 1.
[RouterA] ip route-static 100.1.2.0 24 tunnel 1 preference 1
Verifying the configuration
# Display detailed IS-IS interface information on Router A to view SID information for the loopback interface.
[RouterA] display isis interface verbose
Interface information for IS-IS(1)
----------------------------------
Interface: LoopBack1
Index IPv4 state IPv6 state Circuit ID MTU Type DIS
00002 Up Down 1 1536 L1/L2 --
SNPA address : 0000-0000-0000
IP address : 1.1.1.1
Secondary IP address(es) :
IPv6 link-local address :
Extended circuit ID : 2
CSNP timer value : L1 10 L2 10
Hello timer value : 10
Hello multiplier value : 3
LSP timer value : L12 33
LSP transmit-throttle count : L12 5
Cost : L1 0 L2 0
IPv6 cost : L1 0 L2 0
Priority : L1 64 L2 64
Retransmit timer value : L12 5
MPLS TE status : L1 Disabled L2 Disabled
IPv4 BFD : Disabled
IPv6 BFD : Disabled
IPv4 FRR LFA backup : Enabled
IPv6 FRR LFA backup : Enabled
IPv4 prefix suppression : Disabled
IPv6 prefix suppression : Disabled
IPv4 tag : 0
IPv6 tag : 0
Prefix-SID type : Index
Value : 10
Prefix-SID validity : Valid
# Display detailed IS-IS routing information on Router A to view information about routes bound with labels.
[RouterA] display isis route verbose
Route information for IS-IS(1)
------------------------------
Level-1 IPv4 Forwarding Table
-----------------------------
IPv4 Dest : 10.0.0.0/24 Int. Cost : 10 Ext. Cost : NULL
Admin Tag : - Src Count : 2 Flag : D/L/-
InLabel : 4294967295 InLabel Flag: -/-/-/-/-/-
NextHop : Interface : ExitIndex :
Direct HGE1/0/1 0x00000102
Nib ID : 0x0 OutLabel : 4294967295 OutLabelFlag: -
IPv4 Dest : 11.0.0.0/24 Int. Cost : 20 Ext. Cost : NULL
Admin Tag : - Src Count : 2 Flag : R/-/-
InLabel : 4294967295 InLabel Flag: -/-/-/-/-/-
NextHop : Interface : ExitIndex :
10.0.0.2 HGE1/0/1 0x00000102
Nib ID : 0x14000004 OutLabel : 4294967295 OutLabelFlag: -
IPv4 Dest : 12.0.0.0/24 Int. Cost : 30 Ext. Cost : NULL
Admin Tag : - Src Count : 2 Flag : R/-/-
InLabel : 4294967295 InLabel Flag: -/-/-/-/-/-
NextHop : Interface : ExitIndex :
10.0.0.2 HGE1/0/1 0x00000102
Nib ID : 0x14000004 OutLabel : 4294967295 OutLabelFlag: -
IPv4 Dest : 1.1.1.1/32 Int. Cost : 0 Ext. Cost : NULL
Admin Tag : - Src Count : 1 Flag : D/L/-
InLabel : 16010 InLabel Flag: -/N/-/-/-/-
NextHop : Interface : ExitIndex :
Direct Loop1 0x00000584
Nib ID : 0x0 OutLabel : 4294967295 OutLabelFlag: -
IPv4 Dest : 2.2.2.2/32 Int. Cost : 10 Ext. Cost : NULL
Admin Tag : - Src Count : 1 Flag : R/-/-
InLabel : 16020 InLabel Flag: -/N/-/-/-/-
NextHop : Interface : ExitIndex :
10.0.0.2 HGE1/0/1 0x00000102
Nib ID : 0x14000003 OutLabel : 16020 OutLabelFlag: I
IPv4 Dest : 3.3.3.3/32 Int. Cost : 20 Ext. Cost : NULL
Admin Tag : - Src Count : 1 Flag : R/-/-
InLabel : 16030 InLabel Flag: -/N/-/-/-/-
NextHop : Interface : ExitIndex :
10.0.0.2 HGE1/0/1 0x00000102
Nib ID : 0x14000002 OutLabel : 16030 OutLabelFlag: -
IPv4 Dest : 4.4.4.4/32 Int. Cost : 20 Ext. Cost : NULL
Admin Tag : - Src Count : 1 Flag : R/-/-
InLabel : 16040 InLabel Flag: -/N/-/-/-/-
NextHop : Interface : ExitIndex :
10.0.0.2 HGE1/0/1 0x00000102
Nib ID : 0x14000002 OutLabel : 16040 OutLabelFlag: -
Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set
InLabel flags: R-Readvertisement, N-Node SID, P-no PHP
E-Explicit null, V-Value, L-Local
OutLabelFlags: E-Explicit null, I-Implicit null, N-Normal
# Display MPLS LSP information on Router A.
[RouterA] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
10.0.0.2 Local -/- HGE1/0/1
1.1.1.1/32 ISIS 16010/- -
2.2.2.2/32 ISIS 16020/3 HGE1/0/1
2.2.2.2/32 ISIS -/3 HGE1/0/1
3.3.3.3/32 ISIS 16030/16030 HGE1/0/1
3.3.3.3/32 ISIS -/16030 HGE1/0/1
4.4.4.4/32 ISIS 16040/16040 HGE1/0/1
4.4.4.4/32 ISIS -/16040 HGE1/0/1
Example: Configuring SR-MPLS based on OSPF-advertised SIDs
Network configuration
As shown in Figure 20, Router A, Router B, Router C, and Router D are running OSPF.
Configure dynamic SID allocation on loopback interfaces of the routers. Then, establish an SRLSP from Router A to Router D based on the allocated SIDs and configure an MPLS TE tunnel over the SRLSP to transmit data.
Table 3 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
|
|
|
|
HGE1/0/2 |
11.0.0.1/24 |
Router C |
Loop1 |
3.3.3.3/32 |
Router D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
HGE1/0/1 |
12.0.0.2/24 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/2 |
100.1.2.1/24 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure Router A:
# Configure OSPF to achieve network level connectivity.
<RouterA> system-view
[RouterA] ospf 1 router-id 1.1.1.1
[RouterA-ospf-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] ospf 1 area 0
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] ospf 1 area 0
[RouterA-LoopBack1] quit
# Configure the LSR ID, and enable MPLS and MPLS TE.
[RouterA] mpls lsr-id 1.1.1.1
[RouterA] mpls te
[RouterA-te] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] mpls enable
[RouterA-HundredGigE1/0/1] quit
# Enable SR-MPLS.
[RouterA] ospf 1
[RouterA-ospf-1] segment-routing mpls
[RouterA-ospf-1] quit
# Configure the OSPF prefix SID by specifying a relative value.
[RouterA] interface loopback 1
[RouterA-LoopBack1] ospf 1 prefix-sid index 10
[RouterA-LoopBack1] quit
# Configure a static SRLSP (static-sr-lsp-1) to Router D, setting the outgoing label to the prefix label that Router A allocated to Router D (16040).
[RouterA] static-sr-mpls lsp static-sr-lsp-1 out-label 16040
# Establish static MPLS TE tunnel 1 to Router D. Specify the LSR ID of Router D as the tunnel destination address and bind static SRLSP static-sr-lsp-1 to MPLS TE tunnel interface 1.
[RouterA] interface tunnel 1 mode mpls-te
[RouterA-Tunnel1] ip address 6.1.1.1 255.255.255.0
[RouterA-Tunnel1] destination 4.4.4.4
[RouterA-Tunnel1] mpls te signaling static
[RouterA-Tunnel1] mpls te static-sr-mpls static-sr-lsp-1
[RouterA-Tunnel1] quit
# Configure a static route to direct traffic destined for 100.1.2.0/24 to MPLS TE tunnel 1.
[RouterA] ip route-static 100.1.2.0 24 tunnel 1 preference 1
3. Configure Router B:
# Configure OSPF to achieve network level connectivity.
<RouterB> system-view
[RouterB] ospf 1 router-id 2.2.2.2
[RouterB-ospf-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] ospf 1 area 0
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] ospf 1 area 0
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] ospf 1 area 0
[RouterB-LoopBack1] quit
# Configure the LSR ID, and enable MPLS and MPLS TE.
[RouterB] mpls lsr-id 2.2.2.2
[RouterB] mpls te
[RouterB-te] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] mpls enable
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] quit
# Enable SR-MPLS.
[RouterB] ospf 1
[RouterB-ospf-1] segment-routing mpls
[RouterB-ospf-1] quit
# Configure the OSPF prefix SID by specifying a relative value.
[RouterB] interface loopback 1
[RouterB-LoopBack1] ospf 1 prefix-sid index 20
4. Configure Router C:
# Configure OSPF to achieve network level connectivity.
<RouterC> system-view
[RouterC] ospf 1 router-id 3.3.3.3
[RouterC-ospf-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] ospf 1 area 0
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] ospf 1 area 0
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] ospf 1 area 0
[RouterC-LoopBack1] quit
# Configure the LSR ID, and enable MPLS and MPLS TE.
[RouterC] mpls lsr-id 3.3.3.3
[RouterC] mpls te
[RouterC-te] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] quit
# Enable SR-MPLS.
[RouterC] ospf 1
[RouterC-ospf-1] segment-routing mpls
[RouterC-ospf-1] quit
# Configure the OSPF prefix SID by specifying a relative value.
[RouterC] interface loopback 1
[RouterC-LoopBack1] ospf 1 prefix-sid index 30
5. Configure Router D:
# Configure OSPF to achieve network level connectivity.
<RouterD> system-view
[RouterD] ospf 1 router-id 4.4.4.4
[RouterD-ospf-1] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] ospf 1 area 0
[RouterD-HundredGigE1/0/1] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] ospf 1 area 0
[RouterD-HundredGigE1/0/2] quit
[RouterD] interface loopback 1
[RouterD-LoopBack1] ospf 1 area 0
[RouterD-LoopBack1] quit
# Configure the LSR ID, and enable MPLS and MPLS TE.
[RouterD] mpls lsr-id 4.4.4.4
[RouterD] mpls te
[RouterD-te] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] mpls enable
[RouterD-HundredGigE1/0/1] quit
# Enable SR-MPLS.
[RouterD] ospf 1
[RouterD-ospf-1] segment-routing mpls
[RouterD-ospf-1] quit
# Configure the OSPF prefix SID by specifying a relative value.
[RouterD] interface loopback 1
[RouterD-LoopBack1] ospf 1 prefix-sid index 40
Verifying the configuration
# Display detailed OSPF routing information on Router A to view information about routes bound with labels.
[RouterA] display ospf routing verbose
OSPF Process 1 with Router ID 1.1.1.1
Routing Table
Topology base (MTID 0)
Routing for network
Destination: 11.0.0.0/24
Priority: Low Type: Transit
AdvRouter: 3.3.3.3 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 10.0.0.2 BkNextHop: N/A
IfType: Broadcast BkIfType: N/A
Interface: HGE1/0/1 BkInterface: N/A
NibID: 0x13000005 Status: Normal
Cost: 2
InLabel: 4294967295
OutLabel: 4294967295 OutLabel flag: N
Destination: 10.0.0.0/24
Priority: Low Type: Transit
AdvRouter: 1.1.1.1 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 0.0.0.0 BkNextHop: N/A
IfType: Broadcast BkIfType: N/A
Interface: HGE1/0/1 BkInterface: N/A
NibID: 0x13000001 Status: Direct
Cost: 1
InLabel: 4294967295
OutLabel: 4294967295 OutLabel flag: N
Destination: 4.4.4.4/32
Priority: Medium Type: Stub
AdvRouter: 4.4.4.4 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 10.0.0.2 BkNextHop: N/A
IfType: Broadcast BkIfType: N/A
Interface: HGE1/0/1 BkInterface: N/A
NibID: 0x13000005 Status: Normal
Cost: 2
InLabel: 16040
OutLabel: 16040 OutLabel flag: N
Destination: 3.3.3.3/32
Priority: Medium Type: Stub
AdvRouter: 3.3.3.3 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 10.0.0.2 BkNextHop: N/A
IfType: Broadcast BkIfType: N/A
Interface: HGE1/0/1 BkInterface: N/A
NibID: 0x13000005 Status: Normal
Cost: 2
InLabel: 16030
OutLabel: 16030 OutLabel flag: N
Destination: 2.2.2.2/32
Priority: Medium Type: Stub
AdvRouter: 2.2.2.2 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 10.0.0.2 BkNextHop: N/A
IfType: Broadcast BkIfType: N/A
Interface: HGE1/0/1 BkInterface: N/A
NibID: 0x13000005 Status: Normal
Cost: 1
InLabel: 16020
OutLabel: 16020 OutLabel flag: N
Destination: 1.1.1.1/32
Priority: Medium Type: Stub
AdvRouter: 1.1.1.1 Area: 0.0.0.0
SubProtoID: 0x1 Preference: 10
NextHop: 0.0.0.0 BkNextHop: N/A
IfType: PTP BkIfType: N/A
Interface: Loop1 BkInterface: N/A
NibID: 0x13000002 Status: Direct
Cost: 0
InLabel: 16010
OutLabel: 4294967295 OutLabel flag: N
Total nets: 6
Intra area: 6 Inter area: 0 ASE: 0 NSSA: 0
# Display MPLS LSP information on Router A.
[RouterA] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
10.0.0.2 Local -/- HGE1/0/1
1.1.1.1/32 OSPF 16010/- -
2.2.2.2/32 OSPF 16020/3 HGE1/0/1
2.2.2.2/32 OSPF -/3 HGE1/0/1
3.3.3.3/32 OSPF 16030/16030 HGE1/0/1
3.3.3.3/32 OSPF -/16030 HGE1/0/1
4.4.4.4/32 OSPF 16040/16040 HGE1/0/1
4.4.4.4/32 OSPF -/16040 HGE1/0/1
Example: Configuring an SR-based MPLS TE tunnel over an explicit path
Network configuration
As shown in Figure 21, Router A, Router B, Router C, and Router D are running IS-IS.
Configure dynamic SID allocation on loopback interfaces of the routers. Then, create an explicit path from Router A to Router D and configure the MPLS TE tunnel interface to use SR to establish an MPLS TE tunnel over the explicit path.
Table 4 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
|
|
|
|
HGE1/0/2 |
11.0.0.1/24 |
Router C |
Loop1 |
3.3.3.3/32 |
Router D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
HGE1/0/1 |
12.0.0.2/24 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/2 |
100.1.2.1/24 |
Prerequisites
Configure IP addresses and masks for interfaces.
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure LSR IDs, and enable MPLS and MPLS TE:
# Configure Router A.
<RouterA> system-view
[RouterA] mpls lsr-id 1.1.1.1
[RouterA] mpls te
[RouterA-te] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] mpls enable
[RouterA-HundredGigE1/0/1] quit
# Configure Router B.
<RouterB> system-view
[RouterB] mpls lsr-id 2.2.2.2
[RouterB] mpls te
[RouterB-te] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] mpls enable
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] quit
# Configure Router C.
<RouterC> system-view
[RouterC] mpls lsr-id 3.3.3.3
[RouterC] mpls te
[RouterC-te] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] quit
# Configure Router D.
<RouterD> system-view
[RouterD] mpls lsr-id 4.4.4.4
[RouterD] mpls te
[RouterD-te] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] mpls enable
[RouterD-HundredGigE1/0/1] quit
2. Configure IS-IS on the routers to achieve network level connectivity and set the IS-IS cost style to wide:
# Configure Router A.
<RouterA> system-view
[RouterA] isis 1
[RouterA-isis-1] network-entity 00.0000.0000.0001.00
[RouterA-isis-1] cost-style wide
[RouterA-isis-1] is-level level-1
[RouterA-isis-1] mpls te enable
[RouterA-isis-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] isis enable 1
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis enable 1
[RouterA-LoopBack1] quit
# Configure Router B.
<RouterB> system-view
[RouterB] isis 1
[RouterB-isis-1] network-entity 00.0000.0000.0002.00
[RouterB-isis-1] cost-style wide
[RouterB-isis-1] is-level level-1
[RouterB-isis-1] mpls te enable
[RouterB-isis-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] isis enable 1
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] isis enable 1
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis enable 1
[RouterB-LoopBack1] quit
# Configure Router C.
<RouterC> system-view
[RouterC] isis 1
[RouterC-isis-1] network-entity 00.0000.0000.0003.00
[RouterC-isis-1] cost-style wide
[RouterC-isis-1] is-level level-1
[RouterC-isis-1] mpls te enable
[RouterC-isis-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] isis enable 1
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] isis enable 1
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis enable 1
[RouterC-LoopBack1] quit
# Configure Router D.
<RouterD> system-view
[RouterD] isis 1
[RouterD-isis-1] network-entity 00.0000.0000.0004.00
[RouterD-isis-1] cost-style wide
[RouterD-isis-1] is-level level-1
[RouterD-isis-1] mpls te enable
[RouterD-isis-1] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] isis enable 1
[RouterD-HundredGigE1/0/1] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] isis enable 1
[RouterD-HundredGigE1/0/2] quit
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis enable 1
[RouterD-LoopBack1] quit
3. Enable SR-MPLS on the routers:
# Configure Router A.
[RouterA] isis 1
[RouterA-isis-1] address-family ipv4
[RouterA-isis-1-ipv4] segment-routing mpls
[RouterA-isis-1-ipv4] quit
[RouterA-isis-1] quit
# Configure Router B.
[RouterB] isis 1
[RouterB-isis-1] address-family ipv4
[RouterB-isis-1-ipv4] segment-routing mpls
[RouterB-isis-1-ipv4] quit
[RouterB-isis-1] quit
# Configure Router C.
[RouterC] isis 1
[RouterC-isis-1] address-family ipv4
[RouterC-isis-1-ipv4] segment-routing mpls
[RouterC-isis-1-ipv4] quit
[RouterC-isis-1] quit
# Configure Router D.
[RouterD] isis 1
[RouterD-isis-1] address-family ipv4
[RouterD-isis-1-ipv4] segment-routing mpls
[RouterD-isis-1-ipv4] quit
[RouterD-isis-1] quit
4. Configure IS-IS prefix SIDs for the routers:
# Configure Router A.
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis prefix-sid index 10
[RouterA-LoopBack1] quit
# Configure Router B.
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis prefix-sid index 20
[RouterB-LoopBack1] quit
# Configure Router C.
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis prefix-sid index 30
[RouterC-LoopBack1] quit
# Configure Router D.
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis prefix-sid index 40
[RouterD-LoopBack1] quit
5. Configure an explicit path on Router A.
# Create an explicit path to Router D and specify the nodes by their prefix labels.
[RouterA] explicit-path 1
[RouterA-explicit-path-1] nextsid label 16020 type prefix
[RouterA-explicit-path-1] nextsid label 16030 type prefix
[RouterA-explicit-path-1] nextsid label 16040 type prefix
[RouterA-explicit-path-1] quit
6. Configure an MPLS TE tunnel on Router A:
# Configure MPLS TE tunnel interface Tunnel 1.
[RouterA] interface tunnel 1 mode mpls-te
[RouterA-Tunnel1] ip address unnumbered interface LoopBack 1
# Set the tunnel destination address to the IP address of the loopback interface on Router D.
[RouterA-Tunnel1] destination 4.4.4.4
# Configure the MPLS TE tunnel interface to use SR to establish a tunnel over the explicit path.
[RouterA-Tunnel1] mpls te signaling segment-routing
[RouterA-Tunnel1] mpls te path preference 1 explicit-path 1
[RouterA-Tunnel1] quit
Verifying the configuration
# Display MPLS LSP information on Router A.
[RouterA] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
10.0.0.2 Local -/- HGE1/0/1
Tunnel1 Local -/- NHLFE6
1.1.1.1/32 ISIS 16010/- -
2.2.2.2/32 ISIS 16020/3 HGE1/0/1
2.2.2.2/32 ISIS -/3 HGE1/0/1
3.3.3.3/32 ISIS 16030/16030 HGE1/0/1
3.3.3.3/32 ISIS -/16030 HGE1/0/1
4.4.4.4/32 ISIS 16040/16040 HGE1/0/1
4.4.4.4/32 ISIS -/16040 HGE1/0/1
1.1.1.1/1/17700 SR-TE -/16030 HGE1/0/1
16040
# Display the NHLFE entry information.
[RouterA] display mpls forwarding nhlfe
Total NHLFE entries: 3
Flags: T - Forwarded through a tunnel
N - Forwarded through the outgoing interface to the nexthop IP address
B - Backup forwarding information
A - Active forwarding information
M - P2MP forwarding information
NID Tnl-Type Flag OutLabel Forwarding Info
--------------------------------------------------------------------------------
5 LOCAL NA - HGE1/0/1 10.0.0.2
6 SRLSP NA 16030 HGE1/0/1 10.0.0.2
16040
268435457 TE TA - 6
The output shows that there are two tiers of outgoing labels to the destination. The traffic is forwarded through the explicit path.
Example: Configuring an MPLS TE tunnel over a PCE-calculated SRLSP
Network configuration
As shown in Figure 22, Router A, Router B, Router C, and Router D are running IS-IS.
Configure Router B, Router C, and Router D as PCEs. Configure Router A as a PCC and specify the PCEs for the PCC. Configure Router A to request the PCEs to calculate the path to Router D.
Table 5 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
|
|
|
|
HGE1/0/2 |
11.0.0.1/24 |
Router C |
Loop1 |
3.3.3.3/32 |
Router D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
HGE1/0/1 |
12.0.0.2/24 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/2 |
100.1.2.1/24 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure Router A:
# Configure the LSR ID, and enable MPLS and MPLS TE.
<RouterA> system-view
[RouterA] mpls lsr-id 1.1.1.1
[RouterA] mpls te
[RouterA-te] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] mpls enable
[RouterA-HundredGigE1/0/1] mpls te enable
[RouterA-HundredGigE1/0/1] quit
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
[RouterA] isis 1
[RouterA-isis-1] network-entity 00.0000.0000.0001.00
[RouterA-isis-1] cost-style wide
[RouterA-isis-1] mpls te enable
[RouterA-isis-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] isis enable 1
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis enable 1
[RouterA-LoopBack1] quit
# Enable SR-MPLS.
[RouterA] isis 1
[RouterA-isis-1] address-family ipv4
[RouterA-isis-1-ipv4] segment-routing mpls
[RouterA-isis-1-ipv4] quit
[RouterA-isis-1] quit
# Configure Router A as a PCC and specify the PCEs.
[RouterA] mpls te
[RouterA-te] pcep type active-stateful
[RouterA-te] pce static 2.2.2.2
[RouterA-te] pce static 3.3.3.3
[RouterA-te] pce static 4.4.4.4
[RouterA-te] quit
# Configure MPLS TE tunnel interface Tunnel 1.
[RouterA] interface tunnel 1 mode mpls-te
[RouterA-Tunnel1] ip address unnumbered interface LoopBack1
# Configure the MPLS TE tunnel interface to use SR and stateful PCE to establish the tunnel over the SRLSP calculated in PCE delegation mode.
[RouterA-Tunnel1] mpls te signaling segment-routing
[RouterA-Tunnel1] mpls te delegation
[RouterA-Tunnel1] destination 4.4.4.4
[RouterA-Tunnel1] quit
3. Configure Router B:
# Configure the LSR ID, and enable MPLS and MPLS TE.
<RouterB> system-view
[RouterB] mpls lsr-id 2.2.2.2
[RouterB] mpls te
[RouterB-te] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] mpls enable
[RouterB-HundredGigE1/0/1] mpls te enable
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] mpls te enable
[RouterB-HundredGigE1/0/2] quit
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
[RouterB] isis 1
[RouterB-isis-1] network-entity 00.0000.0000.0002.00
[RouterB-isis-1] cost-style wide
[RouterB-isis-1] mpls te enable
[RouterB-isis-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] isis enable 1
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] isis enable 1
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis enable 1
[RouterB-LoopBack1] quit
# Enable SR-MPLS.
[RouterB] isis 1
[RouterB-isis-1] address-family ipv4
[RouterB-isis-1-ipv4] segment-routing mpls
[RouterB-isis-1-ipv4] quit
[RouterB-isis-1] quit
# Configure Router B as a PCE.
[RouterB] mpls te
[RouterB-te] pce address 2.2.2.2
4. Configure Router C:
# Configure the LSR ID, and enable MPLS and MPLS TE.
<RouterC> system-view
[RouterC] mpls lsr-id 3.3.3.3
[RouterC] mpls te
[RouterC-te] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] mpls te enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] mpls te enable
[RouterC-HundredGigE1/0/2] quit
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
[RouterC] isis 1
[RouterC-isis-1] network-entity 00.0000.0000.0003.00
[RouterC-isis-1] cost-style wide
[RouterC-isis-1] mpls te enable
[RouterC-isis-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] isis enable 1
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] isis enable 1
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis enable 1
[RouterC-LoopBack1] quit
# Enable SR-MPLS.
[RouterC] isis 1
[RouterC-isis-1] address-family ipv4
[RouterC-isis-1-ipv4] segment-routing mpls
[RouterC-isis-1-ipv4] quit
[RouterC-isis-1] quit
# Configure Router C as a PCE.
[RouterC] mpls te
[RouterC-te] pce address 3.3.3.3
5. Configure Router D:
# Configure the LSR ID, and enable MPLS and MPLS TE.
<RouterD> system-view
[RouterD] mpls lsr-id 4.4.4.4
[RouterD] mpls te
[RouterD-te] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] mpls enable
[RouterD-HundredGigE1/0/1] mpls te enable
[RouterD-HundredGigE1/0/1] quit
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
[RouterD] isis 1
[RouterD-isis-1] network-entity 00.0000.0000.0004.00
[RouterD-isis-1] cost-style wide
[RouterD-isis-1] mpls te enable
[RouterD-isis-1] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] isis enable 1
[RouterD-HundredGigE1/0/1] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] isis enable 1
[RouterD-HundredGigE1/0/2] quit
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis enable 1
[RouterD-LoopBack1] quit
# Enable SR-MPLS.
[RouterD] isis 1
[RouterD-isis-1] address-family ipv4
[RouterD-isis-1-ipv4] segment-routing mpls
[RouterD-isis-1-ipv4] quit
[RouterD-isis-1] quit
# Configure Router D as a PCE.
[RouterD] mpls te
[RouterD-te] pce address 4.4.4.4
Verifying the configuration
# Display discovered PCEs on each router. This example uses Router A.
[RouterA] display mpls te pce discovery verbose
PCE address: 2.2.2.2
Discovery methods: Static
Path scopes:
Path scope Preference
Compute intra-area paths 7
Act as PCE for inter-area TE LSP computation 6
Capabilities:
Bidirectional path computation
Support for request prioritization
Support for multiple requests per message
PCE address: 3.3.3.3
Discovery methods: Static
Path scopes:
Path scope Preference
Compute intra-area paths 7
Act as PCE for inter-area TE LSP computation 6
Capabilities:
Bidirectional path computation
Support for request prioritization
Support for multiple requests per message
PCE address: 4.4.4.4
Discovery methods: Static
Path scopes:
Path scope Preference
Compute intra-area paths 7
Act as PCE for inter-area TE LSP computation 6
Capabilities:
Bidirectional path computation
Support for request prioritization
Support for multiple requests per message
# Verify that PCEP sessions have been established on each router. This example uses Router A.
[RouterA] display mpls te pce peer verbose
Peer address: 2.2.2.2
TCP connection : 1.1.1.1:36818 -> 2.2.2.2:4189
Peer type : PCE
Session type : Stateless
Session state : UP
Mastership : Normal
Role : Active
Session up time : 0000 days 00 hours 15 minutes
Session ID : Local 0, Peer 0
Keepalive interval : Local 30 sec, Peer 30 sec
Recommended DeadTimer : Local 120 sec, Peer 120 sec
Tolerance:
Min keepalive interval : 10 sec
Max unknown messages : 5
Request timeout : 10 sec
Capability for Initiate : No
Capability for Segment-Routing: No
Peer address: 3.3.3.3
TCP connection : 1.1.1.1:36821 -> 3.3.3.3:4189
Peer type : PCE
Session type : Stateless
Session state : UP
Mastership : Normal
Role : Active
Session up time : 0000 days 00 hours 13 minutes
Session ID : Local 1, Peer 0
Keepalive interval : Local 30 sec, Peer 30 sec
Recommended DeadTimer : Local 120 sec, Peer 120 sec
Tolerance:
Min keepalive interval : 10 sec
Max unknown messages : 5
Request timeout : 10 sec
Capability for Initiate : No
Capability for Segment-Routing: No
Peer address: 4.4.4.4
TCP connection : 1.1.1.1:36822 -> 4.4.4.4:4189
Peer type : PCE
Session type : Stateless
Session state : UP
Mastership : Normal
Role : Active
Session up time : 0000 days 00 hours 13 minutes
Session ID : Local 2, Peer 0
Keepalive interval : Local 30 sec, Peer 30 sec
Recommended DeadTimer : Local 120 sec, Peer 120 sec
Tolerance:
Min keepalive interval : 10 sec
Max unknown messages : 5
Request timeout : 10 sec
Capability for Initiate : No
Capability for Segment-Routing: No
Example: Configuring SR-MPLS inter-AS option B
Network configuration
As shown in Figure 23, complete the following tasks:
· Start OSPF and enable OSPF-based SR-MPLS on the PEs in the same AS.
· Establish an MPLS TE tunnel between ASBR-PEs in different ASs and enable BGP EPE.
· Configure PE 1 and ASBR-PE 1 to exchange VPNv4 routes through MP IBGP.
· Configure PE 2 and ASBR-PE 2 to exchange VPNv4 routes through MP IBGP.
· Establish an MP-EBGP peer relationship between ASBR-PE 1 and ASBR-PE 2 to exchange VPNv4 routes.
· Disable route target-based filtering of received VPNv4 routes on ASBR-PE 1 and ASBR-PE 2.
· Configure dynamic SID allocation on loopback interfaces of the devices. Then, establish an SRLSP based on the allocated SIDs and configure an MPLS TE tunnel over the SRLSP to transmit data.
Table 6 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
PE 1 |
Loop1 |
2.2.2.9/32 |
PE 2 |
Loop1 |
5.5.5.9/32 |
|
HGE1/0/1 |
30.0.0.1/24 |
|
HGE1/0/1 |
20.0.0.1/24 |
|
HGE1/0/5 |
1.1.1.2/8 |
|
HGE1/0/5 |
9.1.1.2/8 |
ASBR-PE 1 |
Loop1 |
3.3.3.9/32 |
ASBR-PE 2 |
Loop1 |
4.4.4.9/32 |
|
HGE1/0/5 |
1.1.1.1/8 |
|
HGE1/0/5 |
9.1.1.1/8 |
|
HGE1/0/4 |
11.0.0.2/8 |
|
HGE1/0/4 |
11.0.0.1/8 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure PE 1:
# Start OSPF on PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<PE1> system-view
[PE1] ospf 1 router-id 2.2.2.9
[PE1-ospf-1] quit
[PE1] interface hundredgige 1/0/5
[PE1-HundredGigE1/0/5] ip address 1.1.1.2 255.0.0.0
[PE1-HundredGigE1/0/5] ospf 1 area 0
[PE1-HundredGigE1/0/5] mpls enable
[PE1-HundredGigE1/0/5] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ip address 2.2.2.9 32
[PE1-LoopBack1] ospf 1 area 0
[PE1-LoopBack1] quit
[PE1] mpls lsr-id 2.2.2.9
[PE1] mpls te
[PE1-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE1] ospf 1
[PE1-ospf-1] segment-routing mpls
[PE1-ospf-1] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ospf 1 prefix-sid index 20
[PE1-LoopBack1] quit
# Create VPN instance vpn1, and configure the RD and route target attributes.
[PE1] ip vpn-instance vpn1
[PE1-vpn-instance-vpn1] route-distinguisher 11:11
[PE1-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE1-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE1-vpn-instance-vpn1] quit
# Associate HundredGigE 1/0/1 with VPN instance vpn1, and assign an IP address to the interface.
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE1-HundredGigE1/0/1] ip address 30.0.0.1 24
[PE1-HundredGigE1/0/1] quit
# Start BGP on PE 1.
[PE1] bgp 100
# Configure peer 3.3.3.9 as a VPNv4 peer.
[PE1-bgp-default] peer 3.3.3.9 as-number 100
[PE1-bgp-default] peer 3.3.3.9 connect-interface loopback 1
[PE1-bgp-default] address-family vpnv4
[PE1-bgp-default-vpnv4] peer 3.3.3.9 enable
[PE1-bgp-default-vpnv4] quit
# Redistribute direct routes to the VPN routing table of vpn1.
[PE1-bgp-default] ip vpn-instance vpn1
[PE1-bgp-default-vpn1] address-family ipv4 unicast
[PE1-bgp-default-ipv4-vpn1] import-route direct
3. Configure ASBR-PE 1:
# Start OSPF on ASBR-PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE1> system-view
[ASBR-PE1] ospf 1 router-id 3.3.3.9
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface hundredgige 1/0/4
[ASBR-PE1-HundredGigE1/0/4] mpls enable
[ASBR-PE1-HundredGigE1/0/4] quit
[ASBR-PE1] interface hundredgige 1/0/5
[ASBR-PE1-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE1-HundredGigE1/0/5] mpls enable
[ASBR-PE1-HundredGigE1/0/5] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ip address 3.3.3.9 32
[ASBR-PE1-LoopBack1] ospf 1 area 0
[ASBR-PE1-LoopBack1] quit
[ASBR-PE1] mpls lsr-id 3.3.3.9
[ASBR-PE1] mpls te
[ASBR-PE1-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE1] ospf 1
[ASBR-PE1-ospf-1] segment-routing mpls
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ospf 1 prefix-sid index 30
[ASBR-PE1-LoopBack1] quit
# Create a routing policy to assign a label.
[ASBR-PE1] route-policy epe permit node 1
[ASBR-PE1-route-policy-epe-1] apply label-value 245555
[ASBR-PE1-route-policy-epe-1] quit
# Start BGP on ASBR-PE 1.
[ASBR-PE1] bgp 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 as-number 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 connect-interface loopback 1
[ASBR-PE1-bgp-default] peer 11.0.0.1 as-number 600
[ASBR-PE1-bgp-default] peer 11.0.0.1 connect-interface hundredgige 1/0/4
# Disable route target-based filtering of received VPNv4 routes.
[ASBR-PE1-bgp-default] address-family vpnv4
[ASBR-PE1-bgp-default-vpnv4] undo policy vpn-target
# Configure IBGP peer 2.2.2.9 and EBGP peer 11.0.0.1 as a VPNv4 peer.
[ASBR-PE1-bgp-default-vpnv4] peer 11.0.0.1 enable
[ASBR-PE1-bgp-default-vpnv4] peer 2.2.2.9 enable
[ASBR-PE1-bgp-default-vpnv4] quit
# Enable BGP EPE for EBGP neighbor 11.0.0.1 and specify a routing policy to assign a label to the neighbor.
[ASBR-PE1-bgp-default] peer 11.0.0.1 egress-engineering route-policy epe
[ASBR-PE1-bgp-default] quit
[ASBR-PE1-bgp] quit
4. Configure ASBR-PE 2:
# Start OSPF on ASBR-PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE2> system-view
[ASBR-PE2] ospf 1 router-id 4.4.4.9
[ASBR-PE2-ospf-1] quit
[ASBR-PE2] interface hundredgige 1/0/4
[ASBR-PE2-HundredGigE1/0/4] mpls enable
[ASBR-PE2-HundredGigE1/0/4] quit
[ASBR-PE2] interface hundredgige 1/0/5
[ASBR-PE2-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE2-HundredGigE1/0/5] mpls enable
[ASBR-PE2-HundredGigE1/0/5] quit
[ASBR-PE2] interface loopback 1
[ASBR-PE2-LoopBack1] ip address 4.4.4.9 32
[ASBR-PE2-LoopBack1] ospf 1 area 0
[ASBR-PE2-LoopBack1] quit
[ASBR-PE2] mpls lsr-id 4.4.4.9
[ASBR-PE2] mpls te
[ASBR-PE2-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE1] ospf 1
[ASBR-PE1-ospf-1] segment-routing mpls
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ospf 1 prefix-sid index 40
[ASBR-PE1-LoopBack1] quit
# Create a routing policy to assign a label.
[ASBR-PE2] route-policy epe permit node 1
[ASBR-PE2-route-policy-epe-1] apply label-value 246666
[ASBR-PE2-route-policy-epe-1] quit
# Start BGP on ASBR-PE 2.
[ASBR-PE2] bgp 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 as-number 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 connect-interface loopback 1
[ASBR-PE2-bgp-default] peer 11.0.0.2 as-number 100
[ASBR-PE2-bgp-default] peer 11.0.0.2 connect-interface hundredgige 1/0/4
# Disable route target-based filtering of received VPNv4 routes.
[ASBR-PE2-bgp-default] address-family vpnv4
[ASBR-PE2-bgp-default-vpnv4] undo policy vpn-target
# Configure IBGP peer 5.5.5.9 and EBGP peer 11.0.0.2 as a VPNv4 peer.
[ASBR-PE2-bgp-default-vpnv4] peer 11.0.0.2 enable
[ASBR-PE2-bgp-default-vpnv4] peer 5.5.5.9 enable
[ASBR-PE2-bgp-default-vpnv4] quit
# Enable BGP EPE for EBGP neighbor 11.0.0.2 and specify a routing policy to assign a label to the neighbor.
[ASBR-PE2-bgp-default] peer 11.0.0.2 egress-engineering route-policy epe
5. Configure PE 2:
# Start OSPF on PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<PE2> system-view
[PE2] ospf 1 router-id 5.5.5.9
[PE2-ospf-1] quit
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ospf 1 area 0
[PE2-HundredGigE1/0/1] mpls enable
[PE2-HundredGigE1/0/1] quit
[PE2] interface hundredgige 1/0/5
[PE2-HundredGigE1/0/5] ospf 1 area 0
[PE2-HundredGigE1/0/5] mpls enable
[PE2-HundredGigE1/0/5] quit
[PE2] interface loopback 1
[PE2-LoopBack1] ip address 5.5.5.9 32
[PE2-LoopBack1] ospf 1 area 0
[PE2-LoopBack1] quit
[PE2] mpls lsr-id 5.5.5.9
[PE2] mpls te
[PE2-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE2] ospf 1
[PE2-ospf-1] segment-routing mpls
[PE2] interface loopback 1
[PE2-LoopBack1] ospf 1 prefix-sid index 50
[PE2-LoopBack1] quit
# Create VPN instance vpn1, and configure the RD and route target attributes.
[PE2] ip vpn-instance vpn1
[PE2-vpn-instance-vpn1] route-distinguisher 11:11
[PE2-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE2-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE2-vpn-instance-vpn1] quit
# Associate HundredGigE 1/0/1 with VPN instance vpn1, and assign an IP address to the interface.
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE2-HundredGigE1/0/1] ip address 20.0.0.1 24
[PE2-HundredGigE1/0/1] quit
# Start BGP on PE 2.
[PE2] bgp 600
# Configure IBGP peer 4.4.4.9 as a VPNv4 peer.
[PE2-bgp-default] peer 4.4.4.9 as-number 600
[PE2-bgp-default] peer 4.4.4.9 connect-interface loopback 1
[PE2-bgp-default] address-family vpnv4
[PE2-bgp-default-vpnv4] peer 4.4.4.9 enable
[PE2-bgp-default-vpnv4] quit
# Redistribute direct routes to the VPN routing table of vpn1.
[PE2-bgp-default] ip vpn-instance vpn1
[PE2-bgp-default-vpn1] address-family ipv4 unicast
[PE2-bgp-default-ipv4-vpn1] import-route direct
6. Configuring an MPLS TE tunnel:
# Configure ASBR-PE 1 as the ingress node of static SRLSP static-sr-lsp-1 and specify the label that ASBR-PE 1 allocated to ASBR-PE 2 (245555) as the outgoing label.
<ASBR-PE1> system-view
[ASBR-PE1] static-sr-mpls lsp static-sr-lsp-1 out-label 245555
# On ASBR-PE 1, establish static MPLS TE tunnel 1 to ASBR-PE 2. Specify the IP address (11.0.0.1) of the directly connected interface on ASBR-PE 2 as the tunnel destination address. Bind static SRLSP static-sr-lsp-1 to MPLS TE tunnel interface 1.
[ASBR-PE1] interface tunnel 1 mode mpls-te
[ASBR-PE1-Tunnel1] ip address 6.1.1.1 255.255.255.0
[ASBR-PE1-Tunnel1] destination 11.0.0.1
[ASBR-PE1-Tunnel1] mpls te signaling static
[ASBR-PE1-Tunnel1] mpls te static-sr-mpls static-sr-lsp-1
[ASBR-PE1-Tunnel1] quit
# Configure ASBR-PE 2 as the ingress node of static SRLSP static-sr-lsp-2 and specify the label that ASBR-PE 2 allocated to ASBR-PE 1 (246666) as the outgoing label.
<ASBR-PE2> system-view
[ASBR-PE2] static-sr-mpls lsp static-sr-lsp-2 out-label 246666
# On ASBR-PE 2, establish static MPLS TE tunnel 1 to ASBR-PE 1. Specify the IP address (11.0.0.2) of the directly connected interface on ASBR-PE 1 as the tunnel destination address. Bind static SRLSP static-sr-lsp-2 to MPLS TE tunnel interface 1.
[ASBR-PE2] interface tunnel 1 mode mpls-te
[ASBR-PE2-Tunnel1] ip address 7.1.1.1 255.255.255.0
[ASBR-PE2-Tunnel1] destination 11.0.0.2
[ASBR-PE2-Tunnel1] mpls te signaling static
[ASBR-PE2-Tunnel1] mpls te static-sr-mpls static-sr-lsp-2
[ASBR-PE2-Tunnel1] quit
Verifying the configuration
# Execute the display ip routing-table command on CE 1 and CE 2 to verify that they have a route to each other. (Details not shown.)
# Verify that CE 1 and CE 2 can ping each other. (Details not shown.)
# Display MPLS LSP information on ASBR-PE1.
[ASBR-PE1] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
3.3.3.9/1/53168 StaticCR -/- NHLFE1
11.0.0.1 BGP -/- HGE1/0/4
2.2.2.9/1151 BGP 1151/1151 -
11.0.0.1/1149 BGP 1150/1149 -
11.0.0.1 BGP 245555/- NHLFE1
1.1.1.2 Local -/- HGE1/0/5
11.0.0.1 Local -/- HGE1/0/4
Tunnel1 Local -/- NHLFE4
2.2.2.9/32 OSPF 16020/3 HGE1/0/5
2.2.2.9/32 OSPF -/3 HGE1/0/5
3.3.3.9/32 OSPF 16030/- -
Example: Configuring SR-MPLS inter-AS option C (I)
Network configuration
As shown in Figure 24, complete the following tasks:
· Start OSPF and enable OSPF-based SR-MPLS on the PEs in the same AS.
· Configure PE 1 and ASBR-PE 1 to exchange labeled IPv4 routes through IBGP.
· Configure PE 2 and ASBR-PE 2 to exchange labeled IPv4 routes through IBGP.
· Establish an MP-EBGP peer relationship between PE 1 and PE 2 to exchange VPNv4 routes.
· Configure ASBR-PE 1 and ASBR-PE 2 to exchange labeled IPv4 routes through EBGP. Enable BGP-based SR-MPLS.
· Configure dynamic SID allocation on loopback interfaces of the devices. Then, establish an SRLSP based on the allocated SIDs and configure an MPLS TE tunnel over the SRLSP to transmit data.
Table 7 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
PE 1 |
Loop1 |
2.2.2.9/32 |
PE 2 |
Loop1 |
5.5.5.9/32 |
|
HGE1/0/1 |
30.0.0.1/24 |
|
HGE1/0/1 |
20.0.0.1/24 |
|
HGE1/0/5 |
1.1.1.2/8 |
|
HGE1/0/5 |
9.1.1.2/8 |
ASBR-PE 1 |
Loop1 |
3.3.3.9/32 |
ASBR-PE 2 |
Loop1 |
4.4.4.9/32 |
|
HGE1/0/5 |
1.1.1.1/8 |
|
HGE1/0/5 |
9.1.1.1/8 |
|
HGE1/0/4 |
11.0.0.2/8 |
|
HGE1/0/4 |
11.0.0.1/8 |
CE 1 |
HGE1/0/1 |
30.0.0.2/24 |
CE 2 |
HGE1/0/1 |
20.0.0.2/24 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure CE 1:
# Assign an IP address to interface HundredGigE 1/0/1.
<CE1> system-view
[CE1] interface hundredgige 1/0/1
[CE1-HundredGigE1/0/1] ip address 30.0.0.2 24
[CE1-HundredGigE1/0/1] quit
# Configure PE 1 as an EBGP peer and redistribute the VPN route.
[CE1] bgp 65001
[CE1-bgp-default] peer 30.0.0.1 as-number 100
[CE1-bgp-default] address-family ipv4 unicast
[CE1-bgp-default-ipv4] peer 30.0.0.1 enable
[CE1-bgp-default-ipv4] import-route direct
[CE1-bgp-default-ipv4] quit
[CE1-bgp-default] quit
3. Configure PE 1:
# Start OSPF on PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<PE1> system-view
[PE1] ospf 1 router-id 2.2.2.9
[PE1-ospf-1] quit
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] mpls enable
[PE1-HundredGigE1/0/1] quit
[PE1] interface hundredgige 1/0/5
[PE1-HundredGigE1/0/5] ospf 1 area 0
[PE1-HundredGigE1/0/5] mpls enable
[PE1-HundredGigE1/0/5] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ip address 2.2.2.9 32
[PE1-LoopBack1] ospf 1 area 0
[PE1-LoopBack1] quit
[PE1] mpls lsr-id 2.2.2.9
[PE1] mpls te
[PE1-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE1] ospf 1
[PE1-ospf-1] segment-routing mpls
[PE1-ospf-1] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ospf 1 prefix-sid index 20
[PE1-LoopBack1] quit
# Create VPN instance vpn1. Configure an RD and both import and export route targets for the VPN instance.
[PE1] ip vpn-instance vpn1
[PE1-vpn-instance-vpn1] route-distinguisher 11:11
[PE1-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE1-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE1-vpn-instance-vpn1] quit
# Bind VPN instance vpn1 to interface HundredGigE 1/0/1 and assign an IP address to the interface.
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE1-HundredGigE1/0/1] ip address 30.0.0.1 24
[PE1-HundredGigE1/0/1] quit
# Start BGP on PE 1.
[PE1] bgp 100
# Enable the capability to exchange labeled routes with IBGP peer 3.3.3.9.
[PE1-bgp-default] peer 3.3.3.9 as-number 100
[PE1-bgp-default] peer 3.3.3.9 connect-interface loopback 1
[PE1-bgp-default] address-family ipv4 unicast
[PE1-bgp-default-ipv4] peer 3.3.3.9 enable
[PE1-bgp-default-ipv4] peer 3.3.3.9 label-route-capability
# Enable SR-MPLS.
[PE1-bgp-default-ipv4] segment-routing mpls
[PE1-bgp-default-ipv4] quit
# Configure the maximum number of hops from PE 1 to EBGP peer 5.5.5.9 as 10.
[PE1-bgp-default] peer 5.5.5.9 as-number 600
[PE1-bgp-default] peer 5.5.5.9 connect-interface loopback 1
[PE1-bgp-default] peer 5.5.5.9 ebgp-max-hop 10
# Configure peer 5.5.5.9 as a VPNv4 peer.
[PE1-bgp-default] address-family vpnv4
[PE1-bgp-default-vpnv4] peer 5.5.5.9 enable
[PE1-bgp-default-vpnv4] quit
# Configure CE 1 as an EBGP peer of PE 1 and install the learned BGP routes in the routing table of the VPN instance.
[PE1-bgp-default] address-family vpnv4
4. Configure ASBR-PE 1:
# Start OSPF on ASBR-PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE1> system-view
[ASBR-PE1] ospf 1 router-id 3.3.3.9
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface hundredgige 1/0/4
[ASBR-PE1-HundredGigE1/0/4] mpls enable
[ASBR-PE1-HundredGigE1/0/4] quit
[ASBR-PE1] interface hundredgige 1/0/5
[ASBR-PE1-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE1-HundredGigE1/0/5] mpls enable
[ASBR-PE1-HundredGigE1/0/5] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ip address 3.3.3.9 32
[ASBR-PE1-LoopBack1] ospf 1 area 0
[ASBR-PE1-LoopBack1] quit
[ASBR-PE1] mpls lsr-id 3.3.3.9
[ASBR-PE1] mpls te
[ASBR-PE1-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE1] ospf 1
[ASBR-PE1-ospf-1] segment-routing mpls
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ospf 1 prefix-sid index 30
[ASBR-PE1-LoopBack1] quit
# Create a routing policy and specify a label index value.
[ASBR-PE1]ip prefix-list 1 permit 2.2.2.9 32
[ASBR-PE1]route-policy policy1 permit node 1
[ASBR-PE1-route-policy-policy1-1] if-match ip address prefix-list 1
[ASBR-PE1-route-policy-policy1-1] apply label-index 20
[ASBR-PE1-route-policy-policy1-1] quit
# Start BGP on ASBR-PE 1. Enable the capability to exchange labeled routes with IBGP peer 2.2.2.9.
[ASBR-PE1] bgp 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 as-number 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 connect-interface loopback 1
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 2.2.2.9 enable
[ASBR-PE1-bgp-default-ipv4] peer 2.2.2.9 label-route-capability
# Redistribute routes from OSPF process 1 to BGP and apply the routing policy.
[ASBR-PE1-bgp-default-ipv4] import-route ospf 1 route-policy policy1
# Enable SR-MPLS.
[ASBR-PE1-bgp-default-ipv4] segment-routing mpls
[ASBR-PE1-bgp-default-ipv4] quit
# Enable the capability to exchange labeled routes with EBGP peer 11.0.0.1.
[ASBR-PE1-bgp-default] peer 11.0.0.1 as-number 600
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 11.0.0.1 enable
[ASBR-PE1-bgp-default-ipv4] peer 11.0.0.1 label-route-capability
5. Configure ASBR-PE 2:
# Start OSPF on ASBR-PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE2> system-view
[ASBR-PE2] ospf 1 router-id 4.4.4.9
[ASBR-PE2-ospf-1] quit
[ASBR-PE2] interface hundredgige 1/0/4
[ASBR-PE2-HundredGigE1/0/4] mpls enable
[ASBR-PE2-HundredGigE1/0/4] quit
[ASBR-PE2] interface hundredgige 1/0/5
[ASBR-PE2-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE2-HundredGigE1/0/5] mpls enable
[ASBR-PE2-HundredGigE1/0/5] quit
[ASBR-PE2] interface loopback 1
[ASBR-PE2-LoopBack1] ip address 4.4.4.9 32
[ASBR-PE2-LoopBack1] ospf 1 area 0
[ASBR-PE2-LoopBack1] quit
[ASBR-PE2] mpls lsr-id 4.4.4.9
[ASBR-PE2] mpls te
[ASBR-PE2-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE2] ospf 1
[ASBR-PE2-ospf-1] segment-routing mpls
[ASBR-PE2-ospf-1] quit
[ASBR-PE2] interface loopback 1
[ASBR-PE2-LoopBack1] ospf 1 prefix-sid index 40
[ASBR-PE2-LoopBack1] quit
# Create a routing policy and specify a label index value.
[ASBR-PE2]ip prefix-list 1 permit 5.5.5.9 32
[ASBR-PE2] route-policy policy1 permit node 1
[ASBR-PE2-route-policy-policy1-1] if-match ip address prefix-list 1
[ASBR-PE2-route-policy-policy1-1] apply label-index 50
[ASBR-PE2-route-policy-policy1-1] quit
# Start BGP on ASBR-PE 2. Enable the capability to exchange labeled routes with IBGP peer 5.5.5.9.
[ASBR-PE2] bgp 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 as-number 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 connect-interface loopback 1
[ASBR-PE2-bgp-default] address-family ipv4 unicast
[ASBR-PE2-bgp-default-ipv4] peer 5.5.5.9 enable
[ASBR-PE2-bgp-default-ipv4] peer 5.5.5.9 label-route-capability
# Redistribute routes from OSPF process 1 to BGP and apply the routing policy.
[ASBR-PE2-bgp-default-ipv4] import-route ospf 1 route-policy policy1
# Enable SR-MPLS.
[ASBR-PE2-bgp-default-ipv4] segment-routing mpls
[ASBR-PE2-bgp-default-ipv4] quit
# Enable the capability to exchange labeled routes with EBGP peer 11.0.0.2.
[ASBR-PE2-bgp-default] peer 11.0.0.2 as-number 100
[ASBR-PE2-bgp-default] address-family ipv4 unicast
[ASBR-PE2-bgp-default-ipv4] peer 11.0.0.2 enable
[ASBR-PE2-bgp-default-ipv4] peer 11.0.0.2 label-route-capability
6. Configure PE 2:
# Start OSPF on PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<PE2> system-view
[PE2] ospf 1 router-id 5.5.5.9
[PE2-ospf-1] quit
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] mpls enable
[PE2-HundredGigE1/0/1] quit
[PE2] interface hundredgige 1/0/5
[PE2-HundredGigE1/0/5] ospf 1 area 0
[PE2-HundredGigE1/0/5] mpls enable
[PE2-HundredGigE1/0/5] quit
[PE2] interface loopback 1
[PE2-LoopBack1] ip address 5.5.5.9 32
[PE2-LoopBack1] ospf 1 area 0
[PE2-LoopBack1] quit
[PE2] mpls lsr-id 5.5.5.9
[PE2] mpls te
[PE2-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE2] ospf 1
[PE2-ospf-1] segment-routing mpls
[PE2-ospf-1] quit
[PE2] interface loopback 1
[PE2-LoopBack1] ospf 1 prefix-sid index 50
[PE2-LoopBack1] quit
# Create VPN instance vpn1, and configure the RD and route target attributes.
[PE2] ip vpn-instance vpn1
[PE2-vpn-instance-vpn1] route-distinguisher 11:11
[PE2-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE2-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE2-vpn-instance-vpn1] quit
# Associate HundredGigE 1/0/1 with VPN instance vpn1, and assign an IP address to the interface.
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE2-HundredGigE1/0/1] ip address 20.0.0.1 24
[PE2-HundredGigE1/0/1] quit
# Start BGP on PE 2.
[PE2] bgp 600
# Enable the capability to exchange labeled routes with IBGP peer 4.4.4.9.
[PE2-bgp-default] peer 4.4.4.9 as-number 600
[PE2-bgp-default] peer 4.4.4.9 connect-interface loopback 1
[PE2-bgp-default] address-family ipv4 unicast
[PE2-bgp-default-ipv4] peer 4.4.4.9 enable
[PE2-bgp-default-ipv4] peer 4.4.4.9 label-route-capability
# Enable SR-MPLS.
[PE2-bgp-default-ipv4] segment-routing mpls
[PE2-bgp-default-ipv4] quit
# Configure the maximum number of hops from PE 2 to EBGP peer 2.2.2.9 as 10.
[PE2-bgp-default] peer 2.2.2.9 as-number 100
[PE2-bgp-default] peer 2.2.2.9 connect-interface loopback 1
[PE2-bgp-default] peer 2.2.2.9 ebgp-max-hop 10
# Configure peer 2.2.2.9 as a VPNv4 peer.
[PE2-bgp-default] address-family vpnv4
[PE2-bgp-default-vpnv4] peer 2.2.2.9 enable
[PE2-bgp-default-vpnv4] quit
# Configure CE 2 as an EBGP peer and install the learned BGP route in the routing table of the VPN instance.
[PE2-bgp-default] ip vpn-instance vpn1
[PE2-bgp-default-vpn1] peer 20.0.0.2 as-number 65002
[PE2-bgp-default-vpn1] address-family ipv4 unicast
[PE2-bgp-default-ipv4-vpn1] peer 20.0.0.2 enable
7. Configure CE 2:
# Assign an IP address to interface HundredGigE 1/0/1.
<CE2> system-view
[CE2] interface hundredgige 1/0/1
[CE2-HundredGigE1/0/1] ip address 20.0.0.2 24
[CE2-HundredGigE1/0/1] quit
# Establish an EBGP peer relationship with PE 2, and redistribute VPN routes.
[CE2] bgp 65002
[CE2-bgp-default] peer 20.0.0.1 as-number 600
[CE2-bgp-default] address-family ipv4 unicast
[CE2-bgp-default-ipv4] peer 20.0.0.1 enable
[CE2-bgp-default-ipv4] import-route direct
Verifying the configuration
# Execute the display ip routing-table command on CE 1 and CE 2 to verify that they have a route to each other. (Details not shown.)
# Verify that CE 1 and CE 2 can ping each other. (Details not shown.)
# Display MPLS LSP information on PE 1.
[PE1] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
2.2.2.9/32 BGP -/16020 NHLFE1
5.5.5.9/32 BGP -/16050 NHLFE1
5.5.5.9 BGP -/- HGE1/0/5
1.1.1.1 Local -/- HGE1/0/5
2.2.2.9/32 OSPF 16020/- -
3.3.3.9/32 OSPF 16030/3 HGE1/0/5
3.3.3.9/32 OSPF -/3 HGE1/0/5
Example: Configuring SR-MPLS inter-AS option C (II)
Network configuration
As shown in Figure 25, complete the following tasks:
· Start OSPF and enable OSPF-based SR-MPLS on the PEs in the same AS.
· Configure PE 1 and ASBR-PE 1 to exchange labeled IPv4 routes through IBGP. Enable BGP-based SR-MPLS.
· Configure PE 2 and ASBR-PE 2 to exchange labeled IPv4 routes through IBGP. Enable BGP-based SR-MPLS.
· Establish an MP-EBGP peer relationship between PE 1 and PE 2 to exchange VPNv4 routes.
· Configure ASBR-PE 1 and ASBR-PE 2 to exchange labeled IPv4 routes through EBGP. Enable BGP-based SR-MPLS.
· Configure dynamic SID allocation on loopback interfaces of the devices. Then, establish an SRLSP based on the allocated SIDs and configure an MPLS TE tunnel over the SRLSP to transmit data.
Table 8 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
PE 1 |
Loop1 |
2.2.2.9/32 |
PE 2 |
Loop1 |
5.5.5.9/32 |
|
HGE1/0/1 |
30.0.0.1/24 |
|
HGE1/0/1 |
20.0.0.1/24 |
|
HGE1/0/5 |
1.1.1.2/8 |
|
HGE1/0/5 |
9.1.1.2/8 |
ASBR-PE 1 |
Loop1 |
3.3.3.9/32 |
ASBR-PE 2 |
Loop1 |
4.4.4.9/32 |
|
HGE1/0/5 |
1.1.1.1/8 |
|
HGE1/0/5 |
9.1.1.1/8 |
|
HGE1/0/4 |
11.0.0.2/8 |
|
HGE1/0/4 |
11.0.0.1/8 |
CE 1 |
HGE1/0/1 |
30.0.0.2/24 |
CE 2 |
HGE1/0/1 |
20.0.0.2/24 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure CE 1:
# Assign an IP address to interface HundredGigE 1/0/1.
<CE1> system-view
[CE1] interface hundredgige 1/0/1
[CE1-HundredGigE1/0/1] ip address 30.0.0.2 24
[CE1-HundredGigE1/0/1] quit
# Establish an EBGP peer relationship with PE 1, and redistribute VPN routes.
[CE1] bgp 65001
[CE1-bgp-default] peer 30.0.0.1 as-number 100
[CE1-bgp-default] address-family ipv4 unicast
[CE1-bgp-default-ipv4] peer 30.0.0.1 enable
[CE1-bgp-default-ipv4] import-route direct
[CE1-bgp-default-ipv4] quit
[CE1-bgp-default] quit
3. Configure PE 1:
# Start OSPF on PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<PE1> system-view
[PE1] ospf 1 router-id 2.2.2.9
[PE1-ospf-1] quit
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] ospf 1 area 0
[PE1-HundredGigE1/0/1] mpls enable
[PE1-HundredGigE1/0/1] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ip address 2.2.2.9 32
[PE1-LoopBack1] ospf 1 area 0
[PE1-LoopBack1] quit
[PE1] mpls lsr-id 2.2.2.9
[PE1] mpls te
[PE1-te] quit
# Assign an IP address to HundredGigE 1/0/5. Start OSPF and enable MPLS on the interface.
[PE1] interface hundredgige 1/0/5
[PE1-HundredGigE1/0/5] ip address 1.1.1.2 255.0.0.0
[PE1-HundredGigE1/0/5] ospf 1 area 0
[PE1-HundredGigE1/0/5] mpls enable
[PE1-HundredGigE1/0/5] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE1] ospf 1
[PE1-ospf-1] segment-routing mpls
[PE1-ospf-1] quit
[PE1] interface loopback 1
[PE1-LoopBack1] ospf 1 prefix-sid index 20
[PE1-LoopBack1] quit
# Create VPN instance vpn1, and configure the RD and route target attributes.
[PE1] ip vpn-instance vpn1
[PE1-vpn-instance-vpn1] route-distinguisher 11:11
[PE1-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE1-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE1-vpn-instance-vpn1] quit
# Associate HundredGigE 1/0/1 with VPN instance vpn1, and assign an IP address to the interface.
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE1-HundredGigE1/0/1] ip address 30.0.0.1 24
[PE1-HundredGigE1/0/1] quit
# Create a routing policy and specify a label index value.
[PE1] route-policy policy1 permit node 1
[PE1-route-policy-policy1-1] apply label-index 20
[PE1-route-policy-policy1-1] quit
# Start BGP on PE 1.
[PE1] bgp 100
# Enable the capability to exchange labeled routes with IBGP peer 3.3.3.9.
[PE1-bgp-default] peer 3.3.3.9 as-number 100
[PE1-bgp-default] peer 3.3.3.9 connect-interface loopback 1
[PE1-bgp-default] address-family ipv4 unicast
[PE1-bgp-default-ipv4] peer 3.3.3.9 enable
[PE1-bgp-default-ipv4] peer 3.3.3.9 label-route-capability
# Enable SR-MPLS.
[PE1-bgp-default-ipv4] segment-routing mpls
# Redistribute the route of loopback interface 1 to BGP and apply the routing policy.
[PE1-bgp-default-ipv4] network 2.2.2.9 32 route-policy policy1
[PE1-bgp-default-ipv4] quit
# Configure the maximum number of hops from PE 1 to EBGP peer 5.5.5.9 as 10.
[PE1-bgp-default] peer 5.5.5.9 as-number 600
[PE1-bgp-default] peer 5.5.5.9 connect-interface loopback 1
[PE1-bgp-default] peer 5.5.5.9 ebgp-max-hop 10
# Configure peer 5.5.5.9 as a VPNv4 peer.
[PE1-bgp-default] address-family vpnv4
[PE1-bgp-default-vpnv4] peer 5.5.5.9 enable
[PE1-bgp-default-vpnv4] quit
# Configure CE 1 as an EBGP peer of PE 1 and install the learned BGP routes in the routing table of the VPN instance.
[PE1-bgp-default] ip vpn-instance vpn1
[PE1-bgp-default-vpn1] peer 30.0.0.2 as-number 65001
[PE1-bgp-default-vpn1] address-family ipv4 unicast
[PE1-bgp-default-ipv4-vpn1] peer 30.0.0.2 enable
4. Configure ASBR-PE 1:
# Start OSPF on ASBR-PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE1> system-view
[ASBR-PE1] ospf 1 router-id 3.3.3.9
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface hundredgige 1/0/4
[ASBR-PE1-HundredGigE1/0/4] mpls enable
[ASBR-PE1-HundredGigE1/0/4] quit
[ASBR-PE1] interface hundredgige 1/0/5
[ASBR-PE1-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE1-HundredGigE1/0/5] mpls enable
[ASBR-PE1-HundredGigE1/0/5] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ip address 3.3.3.9 32
[ASBR-PE1-LoopBack1] ospf 1 area 0
[ASBR-PE1-LoopBack1] quit
[ASBR-PE1] mpls lsr-id 3.3.3.9
[ASBR-PE1] mpls te
[ASBR-PE1-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE1] ospf 1
[ASBR-PE1-ospf-1] segment-routing mpls
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface loopback 1
[ASBR-PE1-LoopBack1] ospf 1 prefix-sid index 30
[ASBR-PE1-LoopBack1] quit
# Start BGP on ASBR-PE 1. Enable the capability to exchange labeled routes with IBGP peer 2.2.2.9.
[ASBR-PE1] bgp 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 as-number 100
[ASBR-PE1-bgp-default] peer 2.2.2.9 connect-interface loopback 1
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 2.2.2.9 enable
[ASBR-PE1-bgp-default-ipv4] peer 2.2.2.9 label-route-capability
# Enable SR-MPLS.
[ASBR-PE1-bgp-default-ipv4] segment-routing mpls
[ASBR-PE1-bgp-default-ipv4] quit
# Enable the capability to exchange labeled routes with EBGP peer 11.0.0.1.
[ASBR-PE1-bgp-default] peer 11.0.0.1 as-number 600
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 11.0.0.1 enable
[ASBR-PE1-bgp-default-ipv4] peer 11.0.0.1 label-route-capability
5. Configure ASBR-PE 2:
# Start OSPF on ASBR-PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE2> system-view
[ASBR-PE2] ospf 1 router-id 4.4.4.9
[ASBR-PE2-ospf-1] quit
[ASBR-PE2] interface hundredgige 1/0/4
[ASBR-PE2-HundredGigE1/0/4] mpls enable
[ASBR-PE2-HundredGigE1/0/4] quit
[ASBR-PE2] interface hundredgige 1/0/5
[ASBR-PE2-HundredGigE1/0/5] ospf 1 area 0
[ASBR-PE2-HundredGigE1/0/5] mpls enable
[ASBR-PE2-HundredGigE1/0/5] quit
[ASBR-PE2] interface loopback 1
[ASBR-PE2-LoopBack1] ip address 4.4.4.9 32
[ASBR-PE2-LoopBack1] ospf 1 area 0
[ASBR-PE2-LoopBack1] quit
[ASBR-PE2] mpls lsr-id 4.4.4.9
[ASBR-PE2] mpls te
[ASBR-PE2-te] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE2] ospf 1
[ASBR-PE2-ospf-1] segment-routing mpls
[ASBR-PE2-ospf-1] quit
[ASBR-PE2] interface loopback 1
[ASBR-PE2-LoopBack1] ospf 1 prefix-sid index 40
[ASBR-PE2-LoopBack1] quit
# Start BGP on ASBR-PE 2. Enable the capability to exchange labeled routes with IBGP peer 5.5.5.9.
[ASBR-PE2] bgp 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 as-number 600
[ASBR-PE2-bgp-default] peer 5.5.5.9 connect-interface loopback 1
[ASBR-PE2-bgp-default] address-family ipv4 unicast
[ASBR-PE2-bgp-default-ipv4] peer 5.5.5.9 enable
[ASBR-PE2-bgp-default-ipv4] peer 5.5.5.9 label-route-capability
# Enable SR-MPLS.
[ASBR-PE2-bgp-default-ipv4] segment-routing mpls
[ASBR-PE2-bgp-default-ipv4] quit
# Enable the capability to exchange labeled routes with EBGP peer 11.0.0.2.
[ASBR-PE2-bgp-default] peer 11.0.0.2 as-number 100
[ASBR-PE2-bgp-default] address-family ipv4 unicast
[ASBR-PE2-bgp-default-ipv4] peer 11.0.0.2 enable
[ASBR-PE2-bgp-default-ipv4] peer 11.0.0.2 label-route-capability
6. Configure PE 2:
# Start OSPF on PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<PE2> system-view
[PE2] ospf 1 router-id 5.5.5.9
[PE2-ospf-1] quit
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ospf 1 area 0
[PE2-HundredGigE1/0/1] mpls enable
[PE2-HundredGigE1/0/1] quit
[PE2] interface loopback 1
[PE2-LoopBack1] ip address 5.5.5.9 32
[PE2-LoopBack1] ospf 1 area 0
[PE2-LoopBack1] quit
[PE2] mpls lsr-id 5.5.5.9
[PE2] mpls te
[PE2-te] quit
# Assign an IP address to HundredGigE 1/0/5. Start OSPF and enable MPLS on the interface.
[PE2] interface hundredgige 1/0/5
[PE2-HundredGigE1/0/5] ip address 9.1.1.2 255.0.0.0
[PE2-HundredGigE1/0/5] ospf 1 area 0
[PE2-HundredGigE1/0/5] mpls enable
[PE2-HundredGigE1/0/5] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE2] ospf 1
[PE2-ospf-1] segment-routing mpls
[PE2-ospf-1] quit
[PE2] interface loopback 1
[PE2-LoopBack1] ospf 1 prefix-sid index 50
[PE2-LoopBack1] quit
# Create VPN instance vpn1, and configure the RD and route target attributes.
[PE2] ip vpn-instance vpn1
[PE2-vpn-instance-vpn1] route-distinguisher 11:11
[PE2-vpn-instance-vpn1] vpn-target 1:1 2:2 3:3 import-extcommunity
[PE2-vpn-instance-vpn1] vpn-target 3:3 export-extcommunity
[PE2-vpn-instance-vpn1] quit
# Associate HundredGigE 1/0/1 with VPN instance vpn1, and assign an IP address to the interface.
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ip binding vpn-instance vpn1
[PE2-HundredGigE1/0/1] ip address 20.0.0.1 24
[PE2-HundredGigE1/0/1] quit
# Create a routing policy and specify a label index value.
[PE2] route-policy policy1 permit node 1
[PE2-route-policy-policy1-1] apply label-index 50
[PE2-route-policy-policy1-1] quit
# Start BGP on PE 2. Enable the capability to exchange labeled routes with IBGP peer 4.4.4.9.
[PE2] bgp 600
[PE2-bgp-default] peer 4.4.4.9 as-number 600
[PE2-bgp-default] peer 4.4.4.9 connect-interface loopback 1
[PE2-bgp-default] address-family ipv4 unicast
[PE2-bgp-default-ipv4] peer 4.4.4.9 enable
[PE2-bgp-default-ipv4] peer 4.4.4.9 label-route-capability
# Enable SR-MPLS.
[PE2-bgp-default-ipv4] segment-routing mpls
# Redistribute the route of loopback interface 1 to BGP and apply the routing policy.
[PE2-bgp-default-ipv4] network 5.5.5.9 32 route-policy policy1
[PE2-bgp-default-ipv4] quit
# Configure the maximum number of hops from PE 2 to EBGP peer 2.2.2.9 as 10.
[PE2-bgp-default] peer 2.2.2.9 as-number 100
[PE2-bgp-default] peer 2.2.2.9 connect-interface loopback 1
[PE2-bgp-default] peer 2.2.2.9 ebgp-max-hop 10
# Configure peer 2.2.2.9 as a VPNv4 peer.
[PE2-bgp-default] address-family vpnv4
[PE2-bgp-default-vpnv4] peer 2.2.2.9 enable
[PE2-bgp-default-vpnv4] quit
# Configure CE 2 as an EBGP peer of PE 2 and install the learned BGP routes in the routing table of the VPN instance.
[PE2-bgp-default] ip vpn-instance vpn1
[PE2-bgp-default-vpn1] peer 20.0.0.2 as-number 65001
[PE2-bgp-default-vpn1] address-family ipv4 unicast
[PE2-bgp-default-ipv4-vpn1] peer 20.0.0.2 enable
7. Configure CE 2:
# Assign an IP address to interface HundredGigE 1/0/1.
<CE2> system-view
[CE2] interface hundredgige 1/0/1
[CE2-HundredGigE1/0/1] ip address 20.0.0.2 24
[CE2-HundredGigE1/0/1] quit
# Establish an EBGP peer relationship with PE 2, and redistribute VPN routes.
[CE2] bgp 65002
[CE2-bgp-default] peer 20.0.0.1 as-number 600
[CE2-bgp-default] address-family ipv4 unicast
[CE2-bgp-default-ipv4] peer 20.0.0.1 enable
[CE2-bgp-default-ipv4] import-route direct
[CE2-bgp-default-ipv4] quit
[CE2-bgp-default] quit
Verifying the configuration
# Execute the display ip routing-table command on CE 1 and CE 2 to verify that they have a route to each other. (Details not shown.)
# Verify that CE 1 and CE 2 can ping each other. (Details not shown.)
# Display MPLS LSP information on PE1.
[PE1] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
2.2.2.9/32 BGP 3/- -
5.5.5.9/32 BGP -/16050 NHLFE1
5.5.5.9 BGP -/- HGE1/0/5
1.1.1.1 Local -/- HGE1/0/5
2.2.2.9/32 OSPF 16020/- -
3.3.3.9/32 OSPF 16030/3 HGE1/0/5
3.3.3.9/32 OSPF -/3 HGE1/0/5
Example: Configuring SR-MPLS inter-AS option C (III)
Network configuration
As shown in Figure 26, complete the following tasks:
· Start OSPF and enable OSPF-based SR-MPLS on the PEs in the same AS.
· Configure PE 1, ASBR-PE 1, and ASBR-PE 2 to exchange labeled IPv4 routes through IBGP.
· Configure PE 2, ASBR-PE 3, and ASBR-PE 4 to exchange labeled IPv4 routes through IBGP.
· Configure ASBR-PE 1 and ASBR-PE 3 to use their loopback interfaces to establish an EBGP relationship to exchange labeled IPv4 routes. Enable BGP-based SR-MPLS.
· Configure ASBR-PE 2 and ASBR-PE 4 to use their loopback interfaces to establish an EBGP relationship to exchange labeled IPv4 routes. Enable BGP-based SR-MPLS.
· Configure dynamic SID allocation on loopback interfaces of the devices. Then, establish SRLSPs based on the allocated SIDs and configure a multisegmented MPLS TE tunnel over the SRLSPs to transmit data.
Table 9 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
PE1 |
Loop0 |
1.1.1.1/32 |
PE2 |
Loop0 |
6.6.6.1/32 |
|
HGE1/0/1 |
11.0.0.1/24 |
|
HGE1/0/1 |
21.0.0.1/24 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/2 |
22.0.0.1/24 |
ASBR-PE1 |
Loop0 |
2.2.2.1/32 |
ASBR-PE3 |
Loop0 |
4.4.4.1/32 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
HGE1/0/1 |
21.0.0.2/24 |
|
HGE1/0/3 |
13.0.0.1/24 |
|
HGE1/0/3 |
23.0.0.1/24 |
|
HGE1/0/4 |
14.0.0.1/24 |
|
HGE1/0/4 |
14.0.0.2/24 |
ASBR-PE2 |
Loop0 |
3.3.3.1/32 |
ASBR-PE4 |
Loop0 |
5.5.5.1/32 |
|
HGE1/0/2 |
12.0.0.2/24 |
|
HGE1/0/2 |
22.0.0.2/24 |
|
HGE1/0/3 |
13.0.0.2/24 |
|
HGE1/0/3 |
23.0.0.2/24 |
|
HGE1/0/4 |
24.0.0.1/24 |
|
HGE1/0/4 |
24.0.0.2/24 |
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure PE 1:
# Start OSPF on PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<PE1> system-view
[PE1] interface loopback 0
[PE1-LoopBack0] ip address 1.1.1.1 32
[PE1-LoopBack0] ospf 1 area 100
[PE1-LoopBack0] quit
[PE1] mpls lsr-id 1.1.1.1
[PE1] mpls te
[PE1-te] quit
[PE1] interface hundredgige 1/0/1
[PE1-HundredGigE1/0/1] ospf 1 area 100
[PE1-HundredGigE1/0/1] mpls enable
[PE1-HundredGigE1/0/1] mpls te enable
[PE1-HundredGigE1/0/1] quit
[PE1] interface hundredgige 1/0/2
[PE1-HundredGigE1/0/2] ospf 1 area 100
[PE1-HundredGigE1/0/2] mpls enable
[PE1-HundredGigE1/0/2] mpls te enable
[PE1-HundredGigE1/0/2] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE1] ospf 1
[PE1-ospf-1] segment-routing mpls
[PE1-ospf-1] quit
[PE1] interface loopback 0
[PE1-LoopBack0] ospf 1 prefix-sid index 10
[PE1-LoopBack0] quit
# Start BGP on PE 1.
[PE1] bgp 100
# Configure IBGP peer group 1, add peers 2.2.2.1 and 3.3.3.1 to the group, and enable the capability to exchange labeled routes for the group.
[PE1-bgp-default] group 1
[PE1-bgp-default] peer 1 connect-interface loopback 0
[PE1-bgp-default] peer 2.2.2.1 group 1
[PE1-bgp-default] peer 3.3.3.1 group 1
[PE1-bgp-default] address-family ipv4 unicast
[PE1-bgp-default-ipv4] peer 1 enable
[PE1-bgp-default-ipv4] peer 1 label-route-capability
3. Configure ASBR-PE 1:
# Start OSPF on ASBR-PE 1, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE1> system-view
[ASBR-PE1] interface loopback 0
[ASBR-PE1-LoopBack0] ip address 2.2.2.1 32
[ASBR-PE1-LoopBack0] ospf 1 area 100
[ASBR-PE1-LoopBack0] quit
[ASBR-PE1] mpls lsr-id 2.2.2.1
[ASBR-PE1] mpls te
[ASBR-PE1-te] quit
[ASBR-PE1] interface hundredgige 1/0/1
[ASBR-PE1-HundredGigE1/0/1] ospf 1 area 100
[ASBR-PE1-HundredGigE1/0/1] mpls enable
[ASBR-PE1-HundredGigE1/0/1] mpls te enable
[ASBR-PE1-HundredGigE1/0/1] quit
[ASBR-PE1] interface hundredgige 1/0/3
[ASBR-PE1-HundredGigE1/0/3] ospf 1 area 100
[ASBR-PE1-HundredGigE1/0/3] mpls enable
[ASBR-PE1-HundredGigE1/0/3] mpls te enable
[ASBR-PE1-HundredGigE1/0/3] quit
[ASBR-PE1] interface hundredgige 1/0/4
[ASBR-PE1-HundredGigE1/0/4] mpls enable
[ASBR-PE1-HundredGigE1/0/4] mpls te enable
[ASBR-PE1-HundredGigE1/0/4] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE1] ospf 1
[ASBR-PE1-ospf-1] segment-routing mpls
[ASBR-PE1-ospf-1] quit
[ASBR-PE1] interface loopback 0
[ASBR-PE1-LoopBack0] ospf 1 prefix-sid index 20
[ASBR-PE1-LoopBack0] quit
# Create a routing policy and specify a label index value.
[ASBR-PE1]ip prefix-list 1 permit 1.1.1.1 32
[ASBR-PE1] route-policy policy1 permit node 1
[ASBR-PE1-route-policy-policy1-1] if-match ip address prefix-list 1
[ASBR-PE1-route-policy-policy1-1] apply label-index 10
[ASBR-PE1-route-policy-policy1-1] quit
# Start BGP on ASBR-PE 1.
[ASBR-PE1] bgp 100
# Configure IBGP peer group 1, add peers 1.1.1.1 and 3.3.3.1 to the group, and enable the capability to exchange labeled routes for the group.
[ASBR-PE1-bgp-default] group 1
[ASBR-PE1-bgp-default] peer 1 connect-interface loopback 0
[ASBR-PE1-bgp-default] peer 1.1.1.1 group 1
[ASBR-PE1-bgp-default] peer 3.3.3.1 group 1
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 1 enable
[ASBR-PE1-bgp-default-ipv4] peer 1 label-route-capability
# Redistribute routes from OSPF process 1 to BGP and apply the routing policy.
[ASBR-PE1-bgp-default-ipv4] import-route ospf 1 route-policy policy1
# Enable SR-MPLS.
[ASBR-PE1-bgp-default-ipv4] segment-routing mpls
[ASBR-PE1-bgp-default-ipv4] quit
# Configure directly connected peer 14.0.0.2 as an EBGP peer. Advertise only the route of local loopback interface 0 to the peer.
[ASBR-PE1-bgp-default] peer 14.0.0.2 as-number 600
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] network 2.2.2.1 32 route-policy policy2
[ASBR-PE1-bgp-default-ipv4] peer 14.0.0.2 enable
[ASBR-PE1-bgp-default-ipv4] peer 14.0.0.2 route-policy policy2 export
[ASBR-PE1-bgp-default-ipv4] quit
# Create a multihop EBGP neighbor relationship with ASBR-PE 3 by using the loopback interfaces. Enable the capability to exchange labeled routes with peer 4.4.4.1. Set the preferred value to 100 for routes received from peer 4.4.4.1.
[ASBR-PE1-bgp-default] peer 4.4.4.1 as-number 600
[ASBR-PE1-bgp-default] peer 4.4.4.1 connect-interface loopback 0
[ASBR-PE1-bgp-default] peer 4.4.4.1 ebgp-max-hop 10
[ASBR-PE1-bgp-default] address-family ipv4 unicast
[ASBR-PE1-bgp-default-ipv4] peer 4.4.4.1 enable
[ASBR-PE1-bgp-default-ipv4] peer 4.4.4.1 label-route-capability
[ASBR-PE1-bgp-default-ipv4] peer 4.4.4.1 preferred-value 100
[ASBR-PE1-bgp-default-ipv4] quit
# Enable BGP EPE for neighbor 4.4.4.1 and specify a routing policy to assign a label to the neighbor.
[ASBR-PE1-bgp-default] peer 4.4.4.1 egress-engineering route-policy epe
[ASBR-PE1-bgp-default] quit
[ASBR-PE1-bgp] quit
# Create routing policy policy2 and epe to assign label index 20 and label 245555.
[ASBR-PE1]ip prefix-list 2 permit 2.2.2.1 32
[ASBR-PE1] route-policy policy2 permit node 1
[ASBR-PE1-route-policy-policy2-1] if-match ip address prefix-list 2
[ASBR-PE1-route-policy-policy2-1] apply label-index 20
[ASBR-PE1-route-policy-policy2-1] quit
[ASBR-PE1] route-policy epe permit node 1
[ASBR-PE1-route-policy-epe-1] apply label-value 245555
[ASBR-PE1-route-policy-epe-1] quit
4. Configure ASBR-PE 2:
# Configure ASBR-PE 2 in the same way you configure ASBR-PE 1. (Details not shown.)
5. Configure ASBR-PE 3:
# Start OSPF on ASBR-PE 3, set the LSR ID, and enable MPLS and MPLS TE.
<ASBR-PE3> system-view
[ASBR-PE3] interface loopback 0
[ASBR-PE3-LoopBack0] ip address 4.4.4.1 32
[ASBR-PE3-LoopBack0] ospf 1 area 200
[ASBR-PE3-LoopBack0] quit
[ASBR-PE3] mpls lsr-id 4.4.4.1
[ASBR-PE3] mpls te
[ASBR-PE3-te] quit
[ASBR-PE3] interface hundredgige 1/0/1
[ASBR-PE3-HundredGigE1/0/1] ospf 1 area 200
[ASBR-PE3-HundredGigE1/0/1] mpls enable
[ASBR-PE3-HundredGigE1/0/1] mpls te enable
[ASBR-PE3-HundredGigE1/0/1] quit
[ASBR-PE3] interface hundredgige 1/0/3
[ASBR-PE3-HundredGigE1/0/3] ospf 1 area 200
[ASBR-PE3-HundredGigE1/0/3] mpls enable
[ASBR-PE3-HundredGigE1/0/3] mpls te enable
[ASBR-PE3-HundredGigE1/0/3] quit
[ASBR-PE3] interface hundredgige 1/0/4
[ASBR-PE3-HundredGigE1/0/4] mpls enable
[ASBR-PE3-HundredGigE1/0/4] mpls te enable
[ASBR-PE3-HundredGigE1/0/4] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[ASBR-PE3] ospf 1
[ASBR-PE3-ospf-1] segment-routing mpls
[ASBR-PE3-ospf-1] quit
[ASBR-PE3] interface loopback 0
[ASBR-PE3-LoopBack0] ospf 1 prefix-sid index 40
[ASBR-PE3-LoopBack0] quit
# Create a routing policy and specify a label index value.
[ASBR-PE3]ip prefix-list 1 permit 6.6.6.1 32
[ASBR-PE3] route-policy policy1 permit node 1
[ASBR-PE3-route-policy-policy1-1] if-match ip address prefix-list 1
[ASBR-PE3-route-policy-policy1-1] apply label-index 60
[ASBR-PE3-route-policy-policy1-1] quit
# Start BGP on ASBR-PE 3.
[ASBR-PE3] bgp 600
# Configure IBGP peer group 1, add peers 5.5.5.1 and 6.6.6.1 to the group, and enable the capability to exchange labeled routes for the group.
[ASBR-PE3-bgp-default] group 1
[ASBR-PE3-bgp-default] peer 1 connect-interface loopback 0
[ASBR-PE3-bgp-default] peer 5.5.5.1 group 1
[ASBR-PE3-bgp-default] peer 6.6.6.1 group 1
[ASBR-PE3-bgp-default] address-family ipv4 unicast
[ASBR-PE3-bgp-default-ipv4] peer 1 enable
[ASBR-PE3-bgp-default-ipv4] peer 1 label-route-capability
# Redistribute routes from OSPF process 1 to BGP and apply the routing policy.
[ASBR-PE3-bgp-default-ipv4] import-route ospf 1 route-policy policy1
# Enable SR-MPLS.
[ASBR-PE3-bgp-default-ipv4] segment-routing mpls
[ASBR-PE3-bgp-default-ipv4] quit
# Configure directly connected peer 14.0.0.1 as an EBGP peer. Advertise only the route of local loopback interface 0 to the peer.
[ASBR-PE3-bgp-default] peer 14.0.0.1 as-number 100
[ASBR-PE3-bgp-default] address-family ipv4 unicast
[ASBR-PE3-bgp-default-ipv4] network 4.4.4.1 32 route-policy policy2
[ASBR-PE3-bgp-default-ipv4] peer 14.0.0.1 enable
[ASBR-PE3-bgp-default-ipv4] peer 14.0.0.1 route-policy policy2 export
[ASBR-PE3-bgp-default-ipv4] quit
# Create a multihop EBGP neighbor relationship with ASBR-PE 1 by using the loopback interfaces. Enable the capability to exchange labeled routes with peer 2.2.2.1. Set the preferred value to 100 for routes received from peer 2.2.2.1.
[ASBR-PE3-bgp-default] peer 2.2.2.1 as-number 100
[ASBR-PE3-bgp-default] peer 2.2.2.1 connect-interface loopback 0
[ASBR-PE3-bgp-default] peer 2.2.2.1 ebgp-max-hop 10
[ASBR-PE3-bgp-default] address-family ipv4 unicast
[ASBR-PE3-bgp-default-ipv4] peer 2.2.2.1 enable
[ASBR-PE3-bgp-default-ipv4] peer 2.2.2.1 label-route-capability
[ASBR-PE3-bgp-default-ipv4] peer 2.2.2.1 preferred-value 100
[ASBR-PE3-bgp-default-ipv4] quit
# Enable BGP EPE for EBGP neighbor 2.2.2.1 and specify a routing policy to assign a label to the neighbor.
[ASBR-PE3-bgp-default] peer 2.2.2.1 egress-engineering route-policy epe
[ASBR-PE3-bgp-default] quit
[ASBR-PE3-bgp] quit
# Create routing policies policy2 and epe to assign label index 40 and label 246666, respectively.
[ASBR-PE3]ip prefix-list 2 permit 4.4.4.1 32
[ASBR-PE3] route-policy policy2 permit node 1
[ASBR-PE3-route-policy-policy2-1] if-match ip address prefix-list 2
[ASBR-PE3-route-policy-policy2-1] apply label-index 40
[ASBR-PE3-route-policy-policy2-1] quit
[ASBR-PE3] route-policy epe permit node 1
[ASBR-PE3-route-policy-epe-1] apply label-value 246666
[ASBR-PE3-route-policy-epe-1] quit
6. Configure ASBR-PE 4:
# Configure ASBR-PE 4 in the same way you configure ASBR-PE 3. (Details not shown.)
7. Configure PE 2:
# Start OSPF on PE 2, set the LSR ID, and enable MPLS and MPLS TE.
<PE2> system-view
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 6.6.6.1 32
[PE2-LoopBack0] ospf 1 area 200
[PE2-LoopBack0] quit
[PE2] mpls lsr-id 6.6.6.1
[PE2] mpls te
[PE2-te] quit
[PE2] interface hundredgige 1/0/1
[PE2-HundredGigE1/0/1] ospf 1 area 200
[PE2-HundredGigE1/0/1] mpls enable
[PE2-HundredGigE1/0/1] mpls te enable
[PE2-HundredGigE1/0/1] quit
[PE2] interface hundredgige 1/0/2
[PE2-HundredGigE1/0/2] ospf 1 area 200
[PE2-HundredGigE1/0/2] mpls enable
[PE2-HundredGigE1/0/2] mpls te enable
[PE2-HundredGigE1/0/2] quit
# Enable SR-MPLS in OSPF view and configure an OSPF prefix SID.
[PE2] ospf 1
[PE2-ospf-1] segment-routing mpls
[PE2-ospf-1] quit
[PE2] interface loopback 0
[PE2-LoopBack0] ospf 1 prefix-sid index 60
[PE2-LoopBack0] quit
# Start BGP on PE 2.
[PE2] bgp 600
# Configure IBGP peer group 1, add peers 4.4.4.1 and 5.5.5.1 to the group, and enable the capability to exchange labeled routes for the group.
[PE2-bgp-default] group 1
[PE2-bgp-default] peer 1 connect-interface loopback 0
[PE2-bgp-default] peer 4.4.4.1 group 1
[PE2-bgp-default] peer 5.5.5.1 group 1
[PE2-bgp-default] address-family ipv4 unicast
[PE2-bgp-default-ipv4] peer 1 enable
[PE2-bgp-default-ipv4] peer 1 label-route-capability
8. Configuring a multisegmented MPLS TE tunnel:
# On PE 1, configure an MPLS TE tunnel to ASBR-PE 1 and an MPLS TE tunnel to ASBR-PE 2.
[PE1] static-sr-mpls lsp sr-lsp-20 out-label 16020
[PE1] static-sr-mpls lsp sr-lsp-30 out-label 16030
[PE1] interface tunnel 0 mode mpls-te
[PE1-Tunnel0] ip address unnumbered interface LoopBack0
[PE1-Tunnel0] destination 2.2.2.1
[PE1-Tunnel0] mpls te signaling static
[PE1-Tunnel0] mpls te static-sr-mpls sr-lsp-20
[PE1-Tunnel0] quit
[PE1] interface tunnel 1 mode mpls-te
[PE1-Tunnel1] ip address unnumbered interface LoopBack0
[PE1-Tunnel1] destination 3.3.3.1
[PE1-Tunnel1] mpls te signaling static
[PE1-Tunnel1] mpls te static-sr-mpls sr-lsp-30
[PE1-Tunnel1] quit
# On ASBR-PE 1, configure an MPLS TE tunnel to PE 1 and an MPLS TE tunnel to ASBR-PE 3.
[ASBR-PE1] static-sr-mpls lsp sr-lsp-10 out-label 16010
[ASBR-PE1] static-sr-mpls lsp sr-lsp-40 out-label 245555
[ASBR-PE1] interface tunnel 0 mode mpls-te
[ASBR-PE1-Tunnel0] ip address unnumbered interface LoopBack0
[ASBR-PE1-Tunnel0] destination 1.1.1.1
[ASBR-PE1-Tunnel0] mpls te signaling static
[ASBR-PE1-Tunnel0] mpls te static-sr-mpls sr-lsp-10
[ASBR-PE1-Tunnel0] quit
[ASBR-PE1] interface tunnel 1 mode mpls-te
[ASBR-PE1-Tunnel1] ip address unnumbered interface LoopBack0
[ASBR-PE1-Tunnel1] destination 4.4.4.1
[ASBR-PE1-Tunnel1] mpls te signaling static
[ASBR-PE1-Tunnel1] mpls te static-sr-mpls sr-lsp-40
[ASBR-PE1-Tunnel1] quit
# On ASBR-PE 3, configure an MPLS TE tunnel to PE 2 and an MPLS TE tunnel to ASBR-PE 1.
[ASBR-PE3] static-sr-mpls lsp sr-lsp-60 out-label 16060
[ASBR-PE3] static-sr-mpls lsp sr-lsp-40 out-label 246666
[ASBR-PE3] interface tunnel 0 mode mpls-te
[ASBR-PE3-Tunnel0] ip address unnumbered interface LoopBack0
[ASBR-PE3-Tunnel0] destination 6.6.6.1
[ASBR-PE3-Tunnel0] mpls te signaling static
[ASBR-PE3-Tunnel0] mpls te static-sr-mpls sr-lsp-60
[ASBR-PE3-Tunnel0] quit
[ASBR-PE3] interface tunnel 1 mode mpls-te
[ASBR-PE3-Tunnel1] ip address unnumbered interface LoopBack0
[ASBR-PE3-Tunnel1] destination 2.2.2.1
[ASBR-PE3-Tunnel1] mpls te signaling static
[ASBR-PE3-Tunnel1] mpls te static-sr-mpls sr-lsp-40
[ASBR-PE3-Tunnel1] quit
# Configure MPLS TE tunnels on PE 2, ASBR-PE 2, and ASBR-PE 4 in the same way you configure MPLS TE tunnels on PE 1, ASBR-PE 1, and ASBR-PE 3. (Details not shown.)
Verifying the configuration
# Execute the display ip routing-table command on PE 1 and PE 2 to verify that they have a route to each other. (Details not shown.)
# Verify that PE 1 and PE 2 can ping each other. (Details not shown.)
# Display MPLS LSP information on PE1.
[PE1] display mpls lsp
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
1.1.1.1/0/35940 StaticCR -/3 HGE1/0/1
1.1.1.1/1/35940 StaticCR -/3 HGE1/0/1
1.1.1.1/32 BGP -/16010 NHLFE4
4.4.4.1/32 BGP -/16040 NHLFE4
5.5.5.1/32 BGP -/16050 NHLFE4
6.6.6.1/32 BGP -/16060 NHLFE4
11.0.0.2 Local -/- HGE1/0/1
12.0.0.3 Local -/- HGE1/0/2
Tunnel0 Local -/- NHLFE4
Tunnel1 Local -/- NHLFE8
1.1.1.1/32 OSPF 16010/- -
2.2.2.1/32 OSPF 16020/3 HGE1/0/1
2.2.2.1/32 OSPF -/3 HGE1/0/1
3.3.3.1/32 OSPF 16030/3 HGE1/0/2
3.3.3.1/32 OSPF -/3 HGE1/0/2
Example: Configuring SR-MPLS to LDP (IS-IS)
Network configuration
As shown in Figure 27, complete the following tasks so Router A and Router C can communicate with each other:
· Configure Router A, Router B, and Router C to run IS-IS.
· Configure Router A and Router B to run SR-MPLS and establish an SRLSP between Router A and Router B.
· Configure Router B and Router C to run LDP to establish a dynamic LDP LSP between them.
· Configure Router B as the SRMS, map the prefix address of the LDP network to an SID, and advertise the mapping to Router A.
Table 10 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
Router C |
Loop1 |
3.3.3.3/32 |
|
HGE1/0/2 |
11.0.0.1/24 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
|
|
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure Router A:
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<RouterA> system-view
[RouterA] isis 1
[RouterA-isis-1] network-entity 00.0000.0000.0001.00
[RouterA-isis-1] cost-style wide
[RouterA-isis-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] isis enable 1
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis enable 1
[RouterA-LoopBack1] quit
# Configure the LSR ID.
[RouterA] mpls lsr-id 1.1.1.1
# Enable SR-MPLS.
[RouterA] isis 1
[RouterA-isis-1] address-family ipv4
[RouterA-isis-1-ipv4] segment-routing mpls
[RouterA-isis-1-ipv4] quit
[RouterA-isis-1] quit
3. Configure Router B:
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<RouterB> system-view
[RouterB] isis 1
[RouterB-isis-1] network-entity 00.0000.0000.0002.00
[RouterB-isis-1] cost-style wide
[RouterB-isis-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] isis enable 1
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] isis enable 1
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis enable 1
[RouterB-LoopBack1] quit
# Configure the LSR ID.
[RouterB] mpls lsr-id 2.2.2.2
# Configure LDP.
[RouterB] mpls ldp
[RouterB-ldp] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] mpls ldp enable
[RouterB-HundredGigE1/0/2] quit
# Enable SR-MPLS.
[RouterB] isis 1
[RouterB-isis-1] address-family ipv4
[RouterB-isis-1-ipv4] segment-routing mpls
# Configure the IGP to advertise locally configured prefix-SID mappings.
[RouterB-isis-1-ipv4] segment-routing mapping-server advertise-local
[RouterB-isis-1-ipv4] quit
[RouterB-isis-1] quit
# Configure a prefix-SID mapping.
[RouterB] segment-routing
[RouterB-segment-routing] mapping-server prefix-sid-map 3.3.3.3 32 100
[RouterB-segment-routing] quit
4. Configure Router C:
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<RouterC> system-view
[RouterC] isis 1
[RouterC-isis-1] network-entity 00.0000.0000.0003.00
[RouterC-isis-1] cost-style wide
[RouterC-isis-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] isis enable 1
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis enable 1
[RouterC-LoopBack1] quit
# Configure the LSR ID.
[RouterC] mpls lsr-id 3.3.3.3
# Configure LDP.
[RouterC] mpls ldp
[RouterC-ldp] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] mpls ldp enable
[RouterC-HundredGigE1/0/1] quit
Verifying the configuration
# Display IS-IS SRLSP information on Router A.
[RouterA] display mpls lsp protocol isis
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
3.3.3.3/32 ISIS 16100/16100 HGE1/0/1
3.3.3.3/32 ISIS -/16100 HGE1/0/1
The output shows that the outgoing label of the IS-IS SRLSP entry for Router C is using the SID assigned to Router C.
Example: Configuring SR-MPLS to LDP (OSPF)
Network configuration
As shown in Figure 28, complete the following tasks so Router A and Router C can communicate with each other:
· Configure Router A, Router B, and Router C to run OSPF.
· Configure Router A and Router B to run SR-MPLS and establish an SRLSP between Router A and Router B.
· Configure Router B and Router C to run LDP to establish a dynamic LDP LSP between them.
· Configure Router B as the SRMS, map the prefix address of the LDP network to an SID, and advertise the mapping to Router A.
Table 11 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
Router C |
Loop1 |
3.3.3.3/32 |
|
HGE1/0/2 |
11.0.0.1/24 |
|
HGE1/0/1 |
11.0.0.2/24 |
|
|
|
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IP addresses and masks for interfaces. (Details not shown.)
2. Configure Router A:
# Configure OSPF to achieve network level connectivity.
<RouterA> system-view
[RouterA] ospf 1 router-id 1.1.1.1
[RouterA-ospf-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] ospf 1 area 0
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] ospf 1 area 0
[RouterA-LoopBack1] quit
# Configure the LSR ID.
[RouterA] mpls lsr-id 1.1.1.1
# Enable SR-MPLS.
[RouterA] ospf 1
[RouterA-ospf-1] segment-routing mpls
[RouterA-ospf-1] quit
3. Configure Router B:
# Configure OSPF to achieve network level connectivity.
<RouterB> system-view
[RouterB] ospf 1 router-id 2.2.2.2
[RouterB-ospf-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] ospf 1 area 0
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] ospf 1 area 0
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] ospf 1 area 0
[RouterB-LoopBack1] quit
# Configure the LSR ID.
[RouterB] mpls lsr-id 2.2.2.2
# Configure LDP.
[RouterB] mpls ldp
[RouterB-ldp] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] mpls ldp enable
[RouterB-HundredGigE1/0/2] quit
# Enable SR-MPLS.
[RouterB] ospf 1
[RouterB-ospf-1] segment-routing mpls
# Configure the IGP to advertise locally configured prefix-SID mappings.
[RouterB-ospf-1] segment-routing mapping-server advertise-local
[RouterB-ospf-1] quit
# Configure a prefix-SID mapping.
[RouterB] segment-routing
[RouterB-segment-routing] mapping-server prefix-sid-map 3.3.3.3 32 100
[RouterB-segment-routing] quit
4. Configure Router C:
# Configure OSPF to achieve network level connectivity.
<RouterC> system-view
[RouterC] ospf 1 router-id 3.3.3.3
[RouterC-ospf-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] ospf 1 area 0
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] ospf 1 area 0
[RouterC-LoopBack1] quit
# Configure the LSR ID.
[RouterC] mpls lsr-id 3.3.3.3
# Configure LDP.
[RouterC] mpls ldp
[RouterC-ldp] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] mpls ldp enable
[RouterC-HundredGigE1/0/1] quit
Verifying the configuration
# Display OSPF SRLSP information on Router A.
[RouterA] display mpls lsp protocol ospf
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
3.3.3.3/32 OSPF 16100/16100 HGE1/0/1
3.3.3.3/32 OSPF -/16100 HGE1/0/1
The output shows that the outgoing label of the OSPF SRLSP entry for Router C is using the SID assigned to Router C.
Example: Configuring SR-MPLS over LDP
Network configuration
As shown in Figure 29, complete the following tasks so the two SR networks can communicate across the LDP network:
· Configure Router A, Router B, Router C, Router D, and Router E to run IS-IS.
· Configure Router B, Router C, and Router D to run LDP.
· Configure Router A, Router B, Router D, and Router E to run SR-MPLS.
Table 12 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Router A |
Loop1 |
1.1.1.1/32 |
Router B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
Router C |
Loop1 |
3.3.3.3/32 |
|
HGE1/0/2 |
11.0.0.1/24 |
|
HGE1/0/1 |
11.0.0.2/24 |
Router D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/2 |
12.0.0.1/24 |
|
HGE1/0/1 |
12.0.0.2/24 |
Router E |
Loop1 |
5.5.5.5/32 |
|
HGE1/0/2 |
13.0.0.1/24 |
|
HGE1/0/1 |
13.0.0.2/24 |
|
|
|
Prerequisites
Configure IP addresses and masks for interfaces.
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IS-IS on the routers to achieve network level connectivity and set the IS-IS cost style to wide:
# Configure Router A.
<RouterA> system-view
[RouterA] isis 1
[RouterA-isis-1] network-entity 00.0000.0000.0001.00
[RouterA-isis-1] cost-style wide
[RouterA-isis-1] quit
[RouterA] interface hundredgige 1/0/1
[RouterA-HundredGigE1/0/1] isis enable 1
[RouterA-HundredGigE1/0/1] quit
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis enable 1
[RouterA-LoopBack1] quit
# Configure Router B.
<RouterB> system-view
[RouterB] isis 1
[RouterB-isis-1] network-entity 00.0000.0000.0002.00
[RouterB-isis-1] cost-style wide
[RouterB-isis-1] quit
[RouterB] interface hundredgige 1/0/1
[RouterB-HundredGigE1/0/1] isis enable 1
[RouterB-HundredGigE1/0/1] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] isis enable 1
[RouterB-HundredGigE1/0/2] quit
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis enable 1
[RouterB-LoopBack1] quit
# Configure Router C.
<RouterC> system-view
[RouterC] isis 1
[RouterC-isis-1] network-entity 00.0000.0000.0003.00
[RouterC-isis-1] cost-style wide
[RouterC-isis-1] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] isis enable 1
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] isis enable 1
[RouterC-HundredGigE1/0/2] quit
[RouterC] interface loopback 1
[RouterC-LoopBack1] isis enable 1
[RouterC-LoopBack1] quit
# Configure Router D.
<RouterD> system-view
[RouterD] isis 1
[RouterD-isis-1] network-entity 00.0000.0000.0004.00
[RouterD-isis-1] cost-style wide
[RouterD-isis-1] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] isis enable 1
[RouterD-HundredGigE1/0/1] quit
[RouterD] interface hundredgige 1/0/2
[RouterD-HundredGigE1/0/2] isis enable 1
[RouterD-HundredGigE1/0/2] quit
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis enable 1
[RouterD-LoopBack1] quit
# Configure Router E.
<RouterE> system-view
[RouterE] isis 1
[RouterE-isis-1] network-entity 00.0000.0000.0005.00
[RouterE-isis-1] cost-style wide
[RouterE-isis-1] quit
[RouterE] interface hundredgige 1/0/1
[RouterE-HundredGigE1/0/1] isis enable 1
[RouterE-HundredGigE1/0/1] quit
[RouterE] interface loopback 1
[RouterE-LoopBack1] isis enable 1
[RouterE-LoopBack1] quit
2. Configure LSR IDs on the routers:
# Configure Router A.
[RouterA] mpls lsr-id 1.1.1.1
# Configure Router B.
[RouterB] mpls lsr-id 2.2.2.2
# Configure Router C.
[RouterC] mpls lsr-id 3.3.3.3
# Configure Router D.
[RouterD] mpls lsr-id 4.4.4.4
# Configure Router E.
[RouterE] mpls lsr-id 5.5.5.5
3. Configure LDP on Router B, Router C, and Router D:
# Configure Router B.
[RouterB] mpls ldp
[RouterB-ldp] quit
[RouterB] interface hundredgige 1/0/2
[RouterB-HundredGigE1/0/2] mpls enable
[RouterB-HundredGigE1/0/2] mpls ldp enable
[RouterB-HundredGigE1/0/2] quit
# Configure Router C.
[RouterC] mpls ldp
[RouterC-ldp] quit
[RouterC] interface hundredgige 1/0/1
[RouterC-HundredGigE1/0/1] mpls enable
[RouterC-HundredGigE1/0/1] mpls ldp enable
[RouterC-HundredGigE1/0/1] quit
[RouterC] interface hundredgige 1/0/2
[RouterC-HundredGigE1/0/2] mpls enable
[RouterC-HundredGigE1/0/2] mpls ldp enable
[RouterC-HundredGigE1/0/2] quit
# Configure Router D.
[RouterD] mpls ldp
[RouterD-ldp] quit
[RouterD] interface hundredgige 1/0/1
[RouterD-HundredGigE1/0/1] mpls enable
[RouterD-HundredGigE1/0/1] mpls ldp enable
[RouterD-HundredGigE1/0/1] quit
4. Enable SR-MPLS on Router A, Router B, Router D, and Router E:
# Configure Router A.
[RouterA] isis 1
[RouterA-isis-1] address-family ipv4
[RouterA-isis-1-ipv4] segment-routing mpls
[RouterA-isis-1-ipv4] quit
[RouterA-isis-1] quit
# Configure Router B.
[RouterB] isis 1
[RouterB-isis-1] address-family ipv4
[RouterB-isis-1-ipv4] segment-routing mpls
[RouterB-isis-1-ipv4] quit
[RouterB-isis-1] quit
# Configure Router D.
[RouterD] isis 1
[RouterD-isis-1] address-family ipv4
[RouterD-isis-1-ipv4] segment-routing mpls
[RouterD-isis-1-ipv4] quit
[RouterD-isis-1] quit
# Configure Router E.
[RouterE] isis 1
[RouterE-isis-1] address-family ipv4
[RouterE-isis-1-ipv4] segment-routing mpls
[RouterE-isis-1-ipv4] quit
[RouterE-isis-1] quit
5. Configure IS-IS prefix SIDs for Router A, Router B, Router D, and Router E:
# Configure Router A.
[RouterA] interface loopback 1
[RouterA-LoopBack1] isis prefix-sid index 10
[RouterA-LoopBack1] quit
# Configure Router B.
[RouterB] interface loopback 1
[RouterB-LoopBack1] isis prefix-sid index 20
[RouterB-LoopBack1] quit
# Configure Router D.
[RouterD] interface loopback 1
[RouterD-LoopBack1] isis prefix-sid index 40
[RouterD-LoopBack1] quit
# Configure Router E.
[RouterE] interface loopback 1
[RouterE-LoopBack1] isis prefix-sid index 50
[RouterE-LoopBack1] quit
Verifying the configuration
# Display LDP LSP information on Router B.
[RouterB] display mpls ldp lsp
Status Flags: * - stale, L - liberal, B - backup, N/A - unavailable
FECs: 5 Ingress: 3 Transit: 3 Egress: 2
FEC In/Out Label Nexthop OutInterface/LSINDEX
1.1.1.1/32 2173/-
-/2173(L)
2.2.2.2/32 3/-
-/2175(L)
3.3.3.3/32 -/3 11.0.0.2 HGE1/0/2
2175/3 11.0.0.2 HGE1/0/2
4.4.4.4/32 -/2174 11.0.0.2 HGE1/0/2
2174/2174 11.0.0.2 HGE1/0/2
5.5.5.5/32 -/2172 11.0.0.2 HGE1/0/2
2172/2172 11.0.0.2 HGE1/0/2
# Display IS-IS SRLSP information on Router B.
[RouterB] display mpls lsp protocol isis
FEC Proto In/Out Label Out Inter/NHLFE/LSINDEX
1.1.1.1/32 ISIS 16010/3 HGE1/0/1
1.1.1.1/32 ISIS -/3 HGE1/0/1
2.2.2.2/32 ISIS 16020/- -
4.4.4.4/32 ISIS 16040/2174 HGE1/0/2
4.4.4.4/32 ISIS -/2174 HGE1/0/2
5.5.5.5/32 ISIS 16050/2172 HGE1/0/2
5.5.5.5/32 ISIS -/2172 HGE1/0/2
The output shows that the IS-IS SRLSP entries for Router D and Router E are using LDP outgoing labels.
Example: Configuring IS-IS TI-LFA FRR
Network configuration
As shown in Figure 30, complete the following tasks to implement TI-LFA FRR:
· Configure IS-IS on Device A, Device B, and Device C to achieve network level connectivity.
· Configure SR-MPLS on Device A, Device B, and Device C.
· Configure TI-LFA FRR to remove the loop that exists on Link B and to implement fast traffic switchover to Link B when Link A fails.
Table 13 Interface and IP address assignment
Device |
Interface |
IP address |
Device |
Interface |
IP address |
Device A |
Loop1 |
1.1.1.1/32 |
Device B |
Loop1 |
2.2.2.2/32 |
|
HGE1/0/1 |
12.12.12.1/24 |
|
HGE1/0/1 |
24.24.24.1/24 |
|
HGE1/0/2 |
13.13.13.1/24 |
|
HGE1/0/2 |
13.13.13.2/24 |
Device C |
Loop1 |
3.3.3.3/32 |
|
|
|
|
HGE1/0/1 |
12.12.12.2/24 |
|
|
|
|
HGE1/0/2 |
24.24.24.2/24 |
|
|
|
Prerequisites
Configure IP addresses and masks for interfaces.
Procedure
IMPORTANT: By default, interfaces on the device are disabled (in ADM or Administratively Down state). To have an interface operate, you must use the undo shutdown command to enable that interface. |
1. Configure IS-IS on the switches to achieve network level connectivity and set the IS-IS cost style to wide:
# Configure Device A.
<DeviceA> system-view
[DeviceA] isis 1
[DeviceA-isis-1] network-entity 00.0000.0000.0001.00
[DeviceA-isis-1] cost-style wide
[DeviceA-isis-1] quit
[DeviceA] interface hundredgige 1/0/1
[DeviceA-HundredGigE1/0/1] isis enable 1
[DeviceA-HundredGigE1/0/1] isis cost 10
[DeviceA-HundredGigE1/0/1] quit
[DeviceA] interface hundredgige 1/0/2
[DeviceA-HundredGigE1/0/2] isis enable 1
[DeviceA-HundredGigE1/0/2] isis cost 10
[DeviceA-HundredGigE1/0/2] quit
[DeviceA] interface loopback 1
[DeviceA-LoopBack1] isis enable 1
[DeviceA-LoopBack1] quit
# Configure Device B.
<DeviceB> system-view
[DeviceB] isis 1
[DeviceB-isis-1] network-entity 00.0000.0000.0002.00
[DeviceB-isis-1] cost-style wide
[DeviceB-isis-1] quit
[DeviceB] interface hundredgige 1/0/1
[DeviceB-HundredGigE1/0/1] isis enable 1
[DeviceB-HundredGigE1/0/1] isis cost 20
[DeviceB-HundredGigE1/0/1] quit
[DeviceB] interface hundredgige 1/0/2
[DeviceB-HundredGigE1/0/2] isis enable 1
[DeviceB-HundredGigE1/0/2] isis cost 10
[DeviceB-HundredGigE1/0/2] quit
[DeviceB] interface loopback 1
[DeviceB-LoopBack1] isis enable 1
[DeviceB-LoopBack1] quit
# Configure Device C.
<DeviceC> system-view
[DeviceC] isis 1
[DeviceC-isis-1] network-entity 00.0000.0000.0003.00
[DeviceC-isis-1] cost-style wide
[DeviceC-isis-1] quit
[DeviceC] interface hundredgige 1/0/1
[DeviceC-HundredGigE1/0/1] isis enable 1
[DeviceC-HundredGigE1/0/1] isis cost 10
[DeviceC-HundredGigE1/0/1] quit
[DeviceC] interface hundredgige 1/0/2
[DeviceC-HundredGigE1/0/2] isis enable 1
[DeviceC-HundredGigE1/0/2] isis cost 20
[DeviceC-HundredGigE1/0/2] quit
[DeviceC] interface loopback 1
[DeviceC-LoopBack1] isis enable 1
[DeviceC-LoopBack1] quit
2. Configure MPLS TE:
# Configure Device A.
[DeviceA] mpls lsr-id 1.1.1.1
[DeviceA] mpls te
[DeviceA-te] quit
[DeviceA] interface hundredgige 1/0/1
[DeviceA-HundredGigE1/0/1] mpls enable
[DeviceA-HundredGigE1/0/1] mpls te enable
[DeviceA-HundredGigE1/0/1] quit
[DeviceA] interface hundredgige 1/0/2
[DeviceA-HundredGigE1/0/2] mpls enable
[DeviceA-HundredGigE1/0/2] mpls te enable
[DeviceA-HundredGigE1/0/2] quit
# Configure Device B.
[DeviceB] mpls lsr-id 2.2.2.2
[DeviceB] mpls te
[DeviceB-te] quit
[DeviceB] interface hundredgige 1/0/1
[DeviceB-HundredGigE1/0/1] mpls enable
[DeviceB-HundredGigE1/0/1] mpls te enable
[DeviceB-HundredGigE1/0/1] quit
[DeviceB] interface hundredgige 1/0/2
[DeviceB-HundredGigE1/0/2] mpls enable
[DeviceB-HundredGigE1/0/2] mpls te enable
[DeviceB-HundredGigE1/0/2] quit
# Configure Device C.
[DeviceC] mpls lsr-id 3.3.3.3
[DeviceC] mpls te
[DeviceC-te] quit
[DeviceC] interface hundredgige 1/0/1
[DeviceC-HundredGigE1/0/1] mpls enable
[DeviceC-HundredGigE1/0/1] mpls te enable
[DeviceC-HundredGigE1/0/1] quit
[DeviceC] interface hundredgige 1/0/2
[DeviceC-HundredGigE1/0/2] mpls enable
[DeviceC-HundredGigE1/0/2] mpls te enable
[DeviceC-HundredGigE1/0/2] quit
3. Enable SR-MPLS and SR-MPLS adjacency label allocation:
# Configure Device A.
[DeviceA] isis 1
[DeviceA-isis-1] address-family ipv4
[DeviceA-isis-1-ipv4] segment-routing mpls
[DeviceA-isis-1-ipv4] segment-routing adjacency enable
[DeviceA-isis-1-ipv4] quit
[DeviceA-isis-1] quit
# Configure Device B.
[DeviceB] isis 1
[DeviceB-isis-1] address-family ipv4
[DeviceB-isis-1-ipv4] segment-routing mpls
[DeviceB-isis-1-ipv4] segment-routing adjacency enable
[DeviceB-isis-1-ipv4] quit
[DeviceB-isis-1] quit
# Configure Device C.
[DeviceC] isis 1
[DeviceC-isis-1] address-family ipv4
[DeviceC-isis-1-ipv4] segment-routing mpls
[DeviceC-isis-1-ipv4] segment-routing adjacency enable
[DeviceC-isis-1-ipv4] quit
[DeviceC-isis-1] quit
4. Configure IS-IS prefix SIDs for Device A, Device B, and Device C:
# Configure Device A.
[DeviceA] interface loopback 1
[DeviceA-LoopBack1] isis prefix-sid index 10
[DeviceA-LoopBack1] quit
# Configure Device B.
[DeviceB] interface loopback 1
[DeviceB-LoopBack1] isis prefix-sid index 20
[DeviceB-LoopBack1] quit
# Configure Device C.
[DeviceC] interface loopback 1
[DeviceC-LoopBack1] isis prefix-sid index 30
[DeviceC-LoopBack1] quit
5. Configure TI-LFA FRR:
# Configure Device A.
[DeviceA] isis 1
[DeviceA-isis-1] address-family ipv4
[DeviceA-isis-1-ipv4] fast-reroute lfa
[DeviceA-isis-1-ipv4] fast-reroute ti-lfa
[DeviceA-isis-1-ipv4] fast-reroute microloop-avoidance enable
[DeviceA-isis-1-ipv4] segment-routing microloop-avoidance enable
[DeviceA-isis-1-ipv4] quit
[DeviceA-isis-1] quit
# Configure Device B.
[DeviceB] isis 1
[DeviceB-isis-1] address-family ipv4
[DeviceB-isis-1-ipv4] fast-reroute lfa
[DeviceB-isis-1-ipv4] fast-reroute ti-lfa
[DeviceB-isis-1-ipv4] fast-reroute microloop-avoidance enable
[DeviceB-isis-1-ipv4] segment-routing microloop-avoidance enable
[DeviceB-isis-1-ipv4] quit
[DeviceB-isis-1] quit
# Configure Device C.
[DeviceC] isis 1
[DeviceC-isis-1] address-family ipv4
[DeviceC-isis-1-ipv4] fast-reroute lfa
[DeviceC-isis-1-ipv4] fast-reroute ti-lfa
[DeviceC-isis-1-ipv4] fast-reroute microloop-avoidance enable
[DeviceC-isis-1-ipv4] segment-routing microloop-avoidance enable
[DeviceC-isis-1-ipv4] quit
[DeviceC-isis-1] quit
Verifying the configuration
# Display IPv4 IS-IS routing information for 2.2.2.2/32.
[DeviceA] display isis route ipv4 2.2.2.2 32 verbose level-1 1
Route information for IS-IS(1)
-----------------------------
Level-1 IPv4 Forwarding Table
-----------------------------
IPv4 Dest : 2.2.2.2/32 Int. Cost : 10 Ext. Cost : NULL
Admin Tag : - Src Count : 1 Flag : R/L/-
InLabel : 16020 InLabel Flag: -/N/-/-/-/-
NextHop : Interface : ExitIndex :
13.13.13.2 HGE1/0/2 0x00000103
Nib ID : 0x14000005 OutLabel : 16020 OutLabelFlag: I
LabelSrc : SR
TI-LFA:
Interface : HGE1/0/1
BkNextHop : 12.12.12.2 LsIndex : 0x00000002
Backup label stack(top->bottom): {16030, 2175}
Route label: 16020
Flags: D-Direct, R-Added to Rib, L-Advertised in LSPs, U-Up/Down Bit Set
InLabel flags: R-Readvertisement, N-Node SID, P-no PHP
E-Explicit null, V-Value, L-Local
OutLabelFlags: E-Explicit null, I-Implicit null, N-Normal, P-SR label prefer
The output shows TI-LFA backup next hop information.