- Table of Contents
-
- H3C S12500R Ethernet Switch Router Series Config Examples-Release 36xx-6W100
- 01-Login Management Configuration Examples
- 02-RBAC Configuration Examples
- 03-Software Upgrade Examples
- 04-Ethernet Link Aggregation Configuration Examples
- 05-Port Isolation Configuration Examples
- 06-Spanning Tree Configuration Examples
- 07-VLAN Configuration Examples
- 08-VLAN Tagging Configuration Examples
- 09-DHCP Snooping Configuration Examples
- 10-Cross-Subnet Dynamic IP Address Allocation Configuration Examples
- 11-IPv6 over IPv4 Tunneling with OSPFv3 Configuration Examples
- 12-GRE Tunnel Configuration Examples
- 13-GRE with OSPF Configuration Examples
- 14-OSPF Configuration Examples
- 15-IS-IS Configuration Examples
- 16-BGP Configuration Examples
- 17-Policy-Based Routing Configuration Examples
- 18-OSPFv3 Configuration Examples
- 19-IPv6 IS-IS Configuration Examples
- 20-Routing Policy Configuration Examples
- 21-IGMP Snooping Configuration Examples
- 22-IGMP Configuration Examples
- 23-MLD Snooping Configuration Examples
- 24-Basic MPLS Configuration Examples
- 25-MPLS L3VPN Configuration Examples
- 26-ACL Configuration Examples
- 27-Control Plane-Based QoS Policy Configuration Examples
- 28-Traffic Policing Configuration Examples
- 29-GTS and Rate Limiting Configuration Examples
- 30-Priority Mapping and Queue Scheduling Configuration Examples
- 31-Traffic Filtering Configuration Examples
- 32-AAA Configuration Examples
- 33-SSH Configuration Examples
- 34-IP Source Guard Configuration Examples
- 35-Ethernet OAM Configuration Examples
- 36-CFD Configuration Examples
- 37-DLDP Configuration Examples
- 38-VRRP Configuration Examples
- 39-BFD Configuration Examples
- 40-NTP Configuration Examples
- 41-SNMP Configuration Examples
- 42-NQA Configuration Examples
- 43-Mirroring Configuration Examples
- 44-sFlow Configuration Examples
- 45-OpenFlow Configuration Examples
- 46-MAC Address Table Configuration Examples
- 47-Static Multicast MAC Address Entry Configuration Examples
- 48-IP Unnumbered Configuration Examples
- 49-Congestion Avoidance and Queue Scheduling Configuration Examples
- 50-Attack Protection Configuration Examples
- 51-Smart Link Configuration Examples
- 52-RRPP Configuration Examples
- 53-BGP Route Selection Configuration Examples
- 54-IS-IS Route Summarization Configuration Examples
- 55-MPLS OAM Configuration Examples
- 56-MPLS TE Configuration Examples
- 57-VXLAN Configuration Examples
- 58-NetStream Configuration Examples
- 59-EVPN-DCI over an MPLS L3VPN Network Configuration Examples
- 60-PTP Configuration Examples
- 61-S-MLAG Configuration Examples
- 62-MPLS SR Configuration Examples
- 63-Puppet Configuration Examples
- Related Documents
-
Title | Size | Download |
---|---|---|
62-MPLS SR Configuration Examples | 86.85 KB |
|
H3C S12500R Switch Router Series |
MPLS SR Configuration Examples |
|
Copyright © 2021 New H3C Technologies Co., Ltd. All rights reserved.
No part of this manual may be reproduced or transmitted in any form or by any means without prior written consent of New H3C Technologies Co., Ltd.
Except for the trademarks of New H3C Technologies Co., Ltd., any trademarks that may be mentioned in this document are the property of their respective owners.
The information in this document is subject to change without notice.
Introduction
This document provides MPLS SR configuration examples.
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 the 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.
Prerequisites
The configuration examples in this document were created and verified in a lab environment, and all the devices were started with the factory default configuration. When you are working on a live network, make sure you understand the potential impact of every command on your network.
This document assumes that you have basic knowledge of MPLS SR.
Example: Configuring MPLS SR over LDP
Network configuration
As shown in Figure 1, configure the devices so the two SR networks can communicate across the LDP network.
Table 1 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 |
10.0.0.1/24 |
|
HGE1/0/1 |
10.0.0.2/24 |
Device C |
Loop1 |
3.3.3.3/32 |
|
HGE1/0/2 |
11.0.0.1/24 |
|
HGE1/0/1 |
12.0.0.1/24 |
Device D |
Loop1 |
4.4.4.4/32 |
|
HGE1/0/2 |
11.0.0.2/24 |
|
HGE1/0/2 |
12.0.0.2/24 |
Device E |
Loop1 |
5.5.5.5/32 |
|
HGE1/0/1 |
13.0.0.1/24 |
|
HGE1/0/1 |
13.0.0.2/24 |
|
|
|
Analysis
To enable the two SR networks to communicate across the LDP network, you must perform the following tasks:
· Configure Device A, Device B, Device C, Device D, and Device E to run IS-IS.
· Configure Device B, Device C, and Device D to run LDP.
· Configure Device A, Device B, Device D, and Device E to run MPLS SR.
Software versions used
This configuration example was created and verified on Release 3606.
Procedures
Configuring Device A
# Configure IP addresses and masks for interfaces. (Details not shown.)
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<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] quit
[DeviceA] interface loopback 1
[DeviceA-LoopBack1] isis enable 1
[DeviceA-LoopBack1] quit
# Set the LSR ID.
[DeviceA] mpls lsr-id 1.1.1.1
# Enable MPLS SR.
[DeviceA] isis 1
[DeviceA-isis-1] address-family ipv4
[DeviceA-isis-1-ipv4] segment-routing mpls
[DeviceA-isis-1-ipv4] quit
# Configure the SRGB.
[DeviceA-isis-1] segment-routing global-block 16000 16999
[DeviceA-isis-1] quit
# Configure IS-IS prefix SID.
[DeviceA] interface loopback 1
[DeviceA-LoopBack1] isis prefix-sid index 10
[DeviceA-LoopBack1] quit
Configuring Device B
# Configure IP addresses and masks for interfaces. (Details not shown.)
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<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] quit
[DeviceB] interface hundredgige 1/0/2
[DeviceB-HundredGigE1/0/2] isis enable 1
[DeviceB-HundredGigE1/0/2] quit
[DeviceB] interface loopback 1
[DeviceB-LoopBack1] isis enable 1
[DeviceB-LoopBack1] quit
# Set the LSR ID.
[DeviceB] mpls lsr-id 2.2.2.2
# Configure LDP.
[DeviceB] mpls ldp
[DeviceB-ldp] quit
[DeviceB] interface hundredgige 1/0/2
[DeviceB-HundredGigE1/0/2] mpls enable
[DeviceB-HundredGigE1/0/2] mpls ldp enable
[DeviceB-HundredGigE1/0/2] quit
# Enable MPLS SR.
[DeviceB] isis 1
[DeviceB-isis-1] address-family ipv4
[DeviceB-isis-1-ipv4] segment-routing mpls
[DeviceB-isis-1-ipv4] quit
# Configure the SRGB.
[DeviceB-isis-1] segment-routing global-block 17000 17999
[DeviceB-isis-1] quit
# Configure IS-IS prefix SID.
[DeviceB] interface loopback 1
[DeviceB-LoopBack1] isis prefix-sid index 20
[DeviceB-LoopBack1] quit
Configuring Device C
# Configure IP addresses and masks for interfaces. (Details not shown.)
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<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] quit
[DeviceC] interface hundredgige 1/0/2
[DeviceC-HundredGigE1/0/2] isis enable 1
[DeviceC-HundredGigE1/0/2] quit
[DeviceC] interface loopback 1
[DeviceC-LoopBack1] isis enable 1
[DeviceC-LoopBack1] quit
# Set the LSR ID.
[DeviceC] mpls lsr-id 3.3.3.3
# Configure LDP.
[DeviceC] mpls ldp
[DeviceC-ldp] quit
[DeviceC] interface hundredgige 1/0/1
[DeviceC-HundredGigE1/0/1] mpls enable
[DeviceC-HundredGigE1/0/1] mpls ldp enable
[DeviceC-HundredGigE1/0/1] quit
[DeviceC] interface hundredgige 1/0/2
[DeviceC-HundredGigE1/0/2] mpls enable
[DeviceC-HundredGigE1/0/2] mpls ldp enable
[DeviceC-HundredGigE1/0/2] quit
Configuring Device D
# Configure IP addresses and masks for interfaces. (Details not shown.)
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<DeviceD> system-view
[DeviceD] isis 1
[DeviceD-isis-1] network-entity 00.0000.0000.0004.00
[DeviceD-isis-1] cost-style wide
[DeviceD-isis-1] quit
[DeviceD] interface hundredgige 1/0/1
[DeviceD-HundredGigE1/0/1] isis enable 1
[DeviceD-HundredGigE1/0/1] quit
[DeviceD] interface hundredgige 1/0/2
[DeviceD-HundredGigE1/0/2] isis enable 1
[DeviceD-HundredGigE1/0/2] quit
[DeviceD] interface loopback 1
[DeviceD-LoopBack1] isis enable 1
[DeviceD-LoopBack1] quit
# Set the LSR ID.
[DeviceD] mpls lsr-id 4.4.4.4
# Configure LDP.
[DeviceD] mpls ldp
[DeviceD-ldp] quit
[DeviceD] interface hundredgige 1/0/1
[DeviceD-HundredGigE1/0/1] mpls enable
[DeviceD-HundredGigE1/0/1] mpls ldp enable
[DeviceD-HundredGigE1/0/1] quit
# Enable MPLS SR.
[DeviceD] isis 1
[DeviceD-isis-1] address-family ipv4
[DeviceD-isis-1-ipv4] segment-routing mpls
[DeviceD-isis-1-ipv4] quit
# Configure the SRGB.
[DeviceD-isis-1] segment-routing global-block 18000 18999
[DeviceD-isis-1] quit
# Configure IS-IS prefix SID.
[DeviceD] interface loopback 1
[DeviceD-LoopBack1] isis prefix-sid index 40
[DeviceD-LoopBack1] quit
Configuring Device E
# Configure IP addresses and masks for interfaces. (Details not shown.)
# Configure IS-IS to achieve network level connectivity and set the IS-IS cost style to wide.
<DeviceE> system-view
[DeviceE] isis 1
[DeviceE-isis-1] network-entity 00.0000.0000.0005.00
[DeviceE-isis-1] cost-style wide
[DeviceE-isis-1] quit
[DeviceE] interface hundredgige 1/0/1
[DeviceE-HundredGigE1/0/1] isis enable 1
[DeviceE-HundredGigE1/0/1] quit
[DeviceE] interface loopback 1
[DeviceE-LoopBack1] isis enable 1
[DeviceE-LoopBack1] quit
# Set the LSR ID.
[DeviceE] mpls lsr-id 5.5.5.5
# Enable MPLS SR.
[DeviceE] isis 1
[DeviceE-isis-1] address-family ipv4
[DeviceE-isis-1-ipv4] segment-routing mpls
[DeviceE-isis-1-ipv4] quit
# Configure the SRGB.
[DeviceE-isis-1] segment-routing global-block 19000 19999
[DeviceE-isis-1] quit
# Configure IS-IS prefix SID.
[DeviceE] interface loopback 1
[DeviceE-LoopBack1] isis prefix-sid index 50
[DeviceE-LoopBack1] quit
Verifying the configuration
# Display LDP LSP information on Device B.
[DeviceB] 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 24116/-
-/24117(L)
2.2.2.2/32 3/-
-/24120(L)
3.3.3.3/32 -/3 11.0.0.2 HGE1/0/2
24121/3 11.0.0.2 HGE1/0/2
4.4.4.4/32 -/24119 11.0.0.2 HGE1/0/2
24118/24119 11.0.0.2 HGE1/0/2
5.5.5.5/32 -/24118 11.0.0.2 HGE1/0/2
24117/24118 11.0.0.2 HGE1/0/2
# Display IS-IS SRLSP information on Device B.
[DeviceB] display mpls lsp protocol isis
FEC Proto In/Out Label Interface/Out NHLFE
1.1.1.1/32 ISIS 17010/3 HGE1/0/1
1.1.1.1/32 ISIS -/3 HGE1/0/1
2.2.2.2/32 ISIS 17020/- -
4.4.4.4/32 ISIS 17040/24119 HGE1/0/2
4.4.4.4/32 ISIS -/24119 HGE1/0/2
5.5.5.5/32 ISIS 17050/24118 HGE1/0/2
5.5.5.5/32 ISIS -/24118 HGE1/0/2
The output shows that the IS-IS SRLSP entries for Device D and Device E are using LDP labels.
Configuration files
#
isis 1
cost-style wide
segment-routing global-block 16000 16999
network-entity 00.0000.0000.0001.00
#
address-family ipv4 unicast
segment-routing mpls
#
mpls lsr-id 1.1.1.1
#
interface LoopBack1
ip address 1.1.1.1 255.255.255.255
isis enable 1
isis prefix-sid index 10
#
interface HundredGigE1/0/1
port link-mode route
ip address 10.0.0.1 255.255.255.0
isis enable 1
#
· Device B:
#
isis 1
cost-style wide
segment-routing global-block 17000 17999
network-entity 00.0000.0000.0002.00
#
address-family ipv4 unicast
segment-routing mpls
#
mpls lsr-id 2.2.2.2
#
mpls ldp
#
interface LoopBack1
ip address 2.2.2.2 255.255.255.255
isis enable 1
isis prefix-sid index 20
#
interface HundredGigE1/0/1
port link-mode route
ip address 10.0.0.2 255.255.255.0
isis enable 1
#
interface HundredGigE1/0/2
port link-mode route
ip address 11.0.0.1 255.255.255.0
isis enable 1
mpls enable
mpls ldp enable
#
· Device C:
#
isis 1
cost-style wide
network-entity 00.0000.0000.0003.00
#
mpls lsr-id 3.3.3.3
#
mpls ldp
#
interface LoopBack1
ip address 3.3.3.3 255.255.255.255
isis enable 1
#
interface HundredGigE1/0/1
port link-mode route
ip address 12.0.0.1 255.255.255.0
isis enable 1
mpls enable
mpls ldp enable
#
interface HundredGigE1/0/2
port link-mode route
ip address 11.0.0.2 255.255.255.0
isis enable 1
mpls enable
mpls ldp enable
#
· Device D:
#
isis 1
cost-style wide
segment-routing global-block 18000 18999
network-entity 00.0000.0000.0004.00
#
address-family ipv4 unicast
segment-routing mpls
#
mpls lsr-id 4.4.4.4
#
mpls ldp
#
interface LoopBack1
ip address 4.4.4.4 255.255.255.255
isis enable 1
isis prefix-sid index 40
#
interface HundredGigE1/0/1
port link-mode route
ip address 13.0.0.1 255.255.255.0
isis enable 1
#
interface HundredGigE1/0/2
port link-mode route
ip address 12.0.0.2 255.255.255.0
isis enable 1
mpls enable
mpls ldp enable
#
· Device E:
#
isis 1
cost-style wide
segment-routing global-block 19000 19999
network-entity 00.0000.0000.0005.00
#
address-family ipv4 unicast
segment-routing mpls
#
mpls lsr-id 5.5.5.5
#
interface LoopBack1
ip address 5.5.5.5 255.255.255.255
isis enable 1
isis prefix-sid index 50
#
interface HundredGigE1/0/1
port link-mode route
ip address 13.0.0.2 255.255.255.0
isis enable 1
#
Related documentation
· H3C S12500R Switch Router Series Segment Routing Command Reference-R3606
· H3C S12500R Switch Router Series Segment Routing Configuration Guide-R3606