- Table of Contents
- Related Documents
-
Title | Size | Download |
---|---|---|
02-MPLS Basics Commands | 196.33 KB |
1 MPLS Basics Configuration Commands
MPLS Basic Configuration Commands
display mpls statistics interface·
graceful-restart (MPLS LDP view)
graceful-restart timer neighbor-liveness
graceful-restart timer reconnect
graceful-restart timer recovery
reset mpls statistics interface·
l Currently, only VLAN interface supports MPLS capability and LDP capability.
l Except for the command for the LDP GR feature, all commands in MPLS LDP view are available in MPLS LDP VPN instance view. The difference is that the commands serves the public network LDP in MPLS LDP view but serves the MPLS LDP VPN instance in MPLS LDP VPN instance view.
l For information about GR commands, refer to GR Commands in the System Volume.
MPLS Basic Configuration Commands
display mpls ilm
Syntax
display mpls ilm [ label ] [ slot slot-number ] [ include text ]
View
Any view
Default Level
1: Monitor level
Parameters
label: Incoming label, in the range 16 to 4294967295.
include text: Specifies incoming label mapping (ILM) entries containing a specified string.
slot slot-number: Specifies the ILM entries of the board in a slot.
Description
Use the display mpls ilm command to display information about ILM entries.
With no incoming label specified, the command displays the ILM entries of all incoming labels.
Examples
# Display the ILM entry with a specified incoming label.
<Sysname> display mpls ilm 1024
Inlabel In-Interface Token VRF-Index Oper LSP-Type Swap-Label
--------------------------------------------------------------------------
1024 Vlan2 2 0 POP NORMAL ----
# Display all ILM entries.
Inlabel In-Interface Token VRF-Index Oper LSP-Type Swap-Label
--------------------------------------------------------------------------
1024 Vlan2 2 0 POP NORMAL ----
Table 1-1 display mpls ilm command output description
Field |
Description |
Inlabel |
Incoming label |
In-Interface |
Incoming interface |
Token |
NHLFE entry index |
VRF-Index |
VRF index |
Oper |
Operation type |
LSP-Type |
LSP type |
Swap-Label |
Label for swapping |
display mpls interface
Syntax
display mpls interface [ interface-type interface-number ] [ verbose ]
View
Any view
Default Level
1: Monitor level
Parameters
interface-type interface-number: Specifies an interface by its type and number.
verbose: Displays detailed information.
Description
Use the display mpls interface command to display information about one or all interfaces with MPLS enabled.
Related commands: display mpls statistics interface, mpls.
Examples
# Display information about all interfaces with MPLS enabled.
<Sysname> display mpls interface
Interface Status TE Attr LSP Count CRLSP Count
Vlan1 Up En 0 0
Vlan2 Up En 0 0
# Display detailed information about MPLS-enabled interface Vlan-interface 2.
<Sysname> display mpls interface vlan-interface 2 verbose
No : 1
Interface : Vlan2
Status : Down
TE Attribute : Disable
LSPCount : 0
CR-LSPCount : 0
FRR : Disabled
Table 1-2 display mpls interface command output description
Field |
Description |
TE Attr/TE Attribute |
Whether TE is enabled on the interface |
LSPCount |
Number of LSPs on the interface |
CR-LSPCount |
Number of CR-LSPs on the interface |
FRR |
Whether FRR is enabled on the interface. If FRR is enabled, the output will also include the bound tunnels. |
display mpls label
Syntax
display mpls label { label-value1 [ to label-value2 ] | all }
Any view
Default Level
1: Monitor level
Parameters
label-value1: Specifies a label or, when used with the label-value2 argument, the start label of a range of labels. The value of this argument ranges from 16 to 8191.
to label-value2: Specifies the end label of a range of labels, in the range 16 to 8191.
all: Specifies all labels.
Description
Use the display mpls label command to display information about specified labels or all labels.
Examples
# Display information about labels in the range 900 to 1500.
<Sysname> display mpls label 900 to 1500
Label alloc state: '.' means not used, '$' means used
------------------------------Static Label--------------------------------
900:........ ........ ........ ........ ........ ........ ........ ........
964:........ ........ ........ ........ ........ ........ ........ ....
------------------------------Dynamic Label-------------------------------
1024:...$.... ........ ........ ........ ........ ........ ........ ........
1088:........ ........ ........ ........ ........ ........ ........ ........
1152:........ ........ ........ ........ ........ ........ ........ ........
1216:........ ........ ........ ........ ........ ........ ........ ........
1280:........ ........ ........ ........ ........ ........ ........ ........
1344:........ ........ ........ ........ ........ ........ ........ ........
1408:........ ........ ........ ........ ........ ........ ........ ........
1472:........ ........ ........ .....
display mpls ldp
Syntax
display mpls ldp [ all [ verbose ] ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
all: Displays all information about LDP .
verbose: Displays detailed information.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp command to display information about LDP.
If you do not specify any parameter, the command will display all information about LDP in detail.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Display all information about LDP in detail.
<Sysname> display mpls ldp all verbose
LDP Global Information
---------------------------------------------------------------
Protocol Version : V1 Neighbor Liveness : 60 Sec
Graceful Restart : Off FT Reconnect Timer : 60 Sec
MTU Signaling : Off Recovery Timer : 60 Sec
LDP Instance Information
---------------------------------------------------------------
Instance ID : 0 VPN-Instance :
Instance Status : Active LSR ID : 1.1.1.1
Hop Count Limit : 32 Path Vector Limit : 32
Loop Detection : Off
DU Re-advertise Timer : 30 Sec DU Re-advertise Flag : On
DU Explicit Request : Off Request Retry Flag : On
Label Distribution Mode: Ordered Label Retention Mode : Liberal
-----------------------------------------------------------------
Table 1-3 display mpls ldp command output description
Field |
Description |
Protocol Version |
Version of the LDP protocol |
Neighbor Liveness |
Setting of the GR neighbor liveness timer |
Graceful Restart |
Whether GR is enabled |
FT Reconnect Timer |
Setting of the GR’s FT reconnect timer |
Recovery Timer |
Setting of the GR’s recovery timer |
MTU Signaling |
Whether MTU signaling is supported. Currently, the device does not support MTU signaling. |
Instance ID |
Sequence number of the LDP instance |
VPN-Instance |
Name of the LDP-enabled VPN instance. For the default instance, nothing is displayed. |
Hop Count Limit |
Maximum hop count |
Path Vector Limit |
Maximum path vector length |
Loop Detection |
Whether loop detection is enabled |
DU Re-advertise Flag |
Whether label readvertisement is enabled for DU mode |
DU Re-advertise Timer |
Label readvertisement timer for DU mode |
Request Retry Flag |
Whether request retransmission is enabled |
DU Explicit Request |
Whether explicit request transmission is enabled for DU mode |
Label Retention Mode |
Label retention mode of the instance |
Label Distribution Mode |
Label distribution mode of the instance |
display mpls ldp interface
Syntax
display mpls ldp interface [ all [ verbose ] | [ vpn-instance vpn-instance-name ] [ interface-type interface-number | verbose ] ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
all: Displays all information.
verbose: Displays detailed information.
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters.
interface-type interface-number: Specifies an interface by its type and number.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp interface command to display information about LDP-enabled interfaces.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Display information about all LDP-enabled interfaces.
<Sysname> display mpls ldp interface
LDP Interface Information in Public Network
------------------------------------------------------------------------
IF-Name Status LAM Transport-Address Hello-Sent/Rcv
------------------------------------------------------------------------
Vlan2 Inactive DU 1.1.1.1 0/0
------------------------------------------------------------------------
LAM: Label Advertisement Mode IF-Name: Interface name
# Display detailed information about all LDP-enabled interfaces.
<Sysname> display mpls ldp interface verbose
LDP Interface Information in Public Network
--------------------------------------------------------------------------
Interface Name : Vlan-interface2
LDP ID : 1.1.1.1:0 Transport Address : 1.1.1.1
Entity Status : Inactive Interface MTU : 1500
Configured Hello Timer : 15 Sec
Negotiated Hello Timer : 15 Sec
Configured Keepalive Timer : 45 Sec
Label Advertisement Mode : Downstream Unsolicited
Hello Message Sent/Rcvd : 0/0 (Message Count)
-------------------------------------------------------------------------
display mpls ldp Isp
Syntax
display mpls ldp lsp [ all | [ vpn-instance vpn-instance-name ] [ destination-address mask-length ] ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
all: Specifies all LSPs established by LDP.
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters.
dest-addr: Destination address of the LSP.
mask-length: Length of the mask for the destination address, in the range 0 to 32.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp lsp command to display information about LSPs established by LDP.
Related commands: display mpls ldp.
Examples
# Display information about all LSPs established by LDP.
<Sysname> display mpls ldp lsp
LDP LSP Information
--------------------------------------------------------------------------
SN DestAddress/Mask In/OutLabel Next-Hop In/Out-Interface
-------------------------------------------------------------------------
1 1.1.1.1/32 3/NULL 127.0.0.1 -------/InL0
2 10.1.1.0/24 3/NULL 10.1.1.1 -------/Eth1/1
*3 100.1.1.1/32 Liberal(1025)
-------------------------------------------------------------------------- A '*' before an LSP means the LSP is not established
A '*' before a Label means the USCB or DSCB is stale
display mpls ldp peer
Syntax
display mpls ldp peer [ all [ verbose ] | [ vpn-instance vpn-instance-name ] [ peer-id | verbose ] ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
all: Display information about all peers.
verbose: Displays detailed information.
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters.
peer-id: LSR ID of the peer.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp peer command to display information about specified peers or all peers.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Display information about all peers.
<Sysname> display mpls ldp peer
LDP Peer Information in Public network
Total number of peers: 3
--------------------------------------------------------------
Peer-ID Transport-Address Discovery-Source
--------------------------------------------------------------
172.17.1.2:0 172.17.1.2 Vlan-interface1
168.1.1.1:0 168.1.1.1 Vlan-interface2
100.10.1.1:0 100.10.1.1 Vlan-interface3
--------------------------------------------------------------
# Display detailed information about all peers.
<Sysname> display mpls ldp peer verbose
LDP Peer Information in Public network
---------------------------------------------------------------
Peer LDP ID : 172.17.1.2:0
Peer Max PDU Length : 4096 Peer Transport Address : 172.17.1.2
Peer Loop Detection : Off Peer Path Vector Limit : 0
Peer FT Flag : Off Peer Keepalive Timer : 45 Sec
Recovery Timer : ---- Reconnect Timer : ----
Peer Label Advertisement Mode : Downstream Unsolicited
Peer Discovery Source : Vlan-interface1
------------------------------------------------------------
Peer LDP ID : 168.1.1.1:0
Peer Max PDU Length : 4096 Peer Transport Address : 168.1.1.1
Peer Loop Detection : Off Peer Path Vector Limit : 0
Peer FT Flag : Off Peer Keepalive Timer : 45 Sec
Recovery Timer : ---- Reconnect Timer : ----
Peer Label Advertisement Mode : Downstream Unsolicited
Peer Discovery Source : Vlan-interface2
-------------------------------------------------------------
Peer LDP ID : 100.10.1.1:0
Peer Max PDU Length : 4096 Peer Transport Address : 100.10.1.1
Peer Loop Detection : Off Peer Path Vector Limit : 0
Peer FT Flag : Off Peer Keepalive Timer : 45 Sec
Recovery Timer : ---- Reconnect Timer : ----
Peer Label Advertisement Mode : Downstream Unsolicited
Peer Discovery Source : Vlan-interface3
------------------------------------------------------------
display mpls ldp remote-peer
Syntax
display mpls ldp remote-peer [ remote-name remote-peer-name ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
remote-peer-name: Name of the remote peer, a case-insensitive string of 1 to 32 characters.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp remote-peer command to display information about remote LDP peers.
Related commands: mpls ldp (system view), mpls ldp (interface view), remote-ip.
Examples
# Display information about remote peer BJI.
<Sysname> display mpls ldp remote-peer remote-name BJI
LDP Remote Entity Information --------------------------------------------------------------------------
Remote Peer Name : BJI
Remote Peer IP : 3.3.3.3 LDP ID : 1.1.1.1:0
Transport Address : 1.1.1.1
Configured Keepalive Timer : 45 Sec
Configured Hello Timer : 45 Sec
Negotiated Hello Timer : 45 Sec
Hello Message Sent/Rcvd : 3/2 (Message Count)
--------------------------------------------------------------------------
display mpls ldp session
Syntax
display mpls ldp session [ all [ verbose ] | [ vpn-instance vpn-instance-name ] [ peer-id | verbose ] ] [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
all: Displays all information.
verbose: Displays detailed information.
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters. Specify this argument to display information about all LDP sessions of a specified VPN.
peer-id: LSR ID of the peer.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp session command to display information about LDP sessions.
If you do not specify any parameter, the command displays information about all public network LDP sessions.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Display information about all public network LDP sessions.
<Sysname> display mpls ldp session
LDP Session(s) in Public Network
Total number of sessions: 1
--------------------------------------------------------------------------
Peer-ID Status LAM SsnRole FT MD5 KA-Sent/Rcv
--------------------------------------------------------------------------
1.1.1.1:0 Operational DU Active Off Off 4582/4582
--------------------------------------------------------------------------
LAM : Label Advertisement Mode FT : Fault Tolerance
Table 1-4 display mpls ldp session command output description
Field |
Description |
SsnRole |
Role of the current LSR in the session, Active or Passive |
KA-Sent/Rcv |
Number of sent Keepalives and that of received Keepalives during the session |
# Display detailed information about all public network LDP sessions.
<Sysname> display mpls ldp session verbose
LDP Session(s) in Public Network
--------------------------------------------------------------------------
Peer LDP ID : 1.1.1.1:0 Local LDP ID : 3.3.3.3:0
TCP Connection : 3.3.3.3 -> 1.1.1.1
Session State : Operational Session Role : Active
Session FT Flag : Off MD5 Flag : Off
Reconnect Timer : --- Recovery Timer : ---
Negotiated Keepalive Timer : 45 Sec
Keepalive Message Sent/Rcvd : 6/6 (Message Count)
Label Advertisement Mode : Downstream Unsolicited
Label Resource Status(Peer/Local) : Available/Available
Peer Discovery Mechanism : Extended
Session existed time : 000:00:01 (DDD:HH:MM)
LDP Extended Discovery Source : Remote peer: 1
Addresses received from peer: (Count: 2)
10.1.1.1 1.1.1.1
--------------------------------------------------------------------------
Peer LDP ID : 2.2.2.2:0 Local LDP ID : 3.3.3.3:0
TCP Connection : 3.3.3.3 -> 2.2.2.2
Session State : Operational Session Role : Active
Session FT Flag : Off MD5 Flag : Off
Reconnect Timer : --- Recovery Timer : ---
Negotiated Keepalive Timer : 45 Sec
Keepalive Message Sent/Rcvd : 25/25 (Message Count)
Label Advertisement Mode : Downstream Unsolicited
Label Resource Status(Peer/Local) : Available/Available
Peer Discovery Mechanism : Basic
Session existed time : 000:00:06 (DDD:HH:MM)
LDP Basic Discovery Source : Ethernet1/1
Addresses received from peer: (Count: 3)
10.1.1.2 20.1.1.1 2.2.2.2
--------------------------------------------------------------------------
Table 1-5 display mpls ldp session verbose output description
Field |
Description |
Session Role |
Role of the current LSR in the session, Active or Passive |
Session FT Flag |
Whether GR FT is enabled on the peer for the session |
MD5 Flag |
Whether MD5 authentication is enabled on the peer |
Reconnect Timer |
GR reconnect timer |
Recovery Timer |
GR recovery timer |
Label Resource Status(Peer/Local) |
Whether there are free labels locally and on the peer |
Peer Discovery Mechanism |
Discovery mechanism of the peer: Basic or Extended |
Session existed time |
Length of time that elapsed since the session is established |
LDP Basic Discovery Source |
Interface where the session is established. The value is the name of the interface for basic discovery and name of the remote peer for extended discovery. |
LDP Extended Discovery Source |
|
Addresses received from peer |
Addresses received from the peer during the session |
display mpls ldp vpn-instance
Syntax
display mpls ldp vpn-instance vpn-instance-name [ | { begin | exclude | include } regular-expression ]
View
Any view
Default Level
1: Monitor level
Parameters
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters.
|: Uses a regular expression to filter the output information. For details about regular expression, refer to Basic System Configuration in the System Volume.
begin: Displays all lines starting with the line that matches the regular expression.
exclude: Displays all lines other than those matching the regular expression..
include: Displays all lines matching the regular expression.
regular-expression: Regular expression, a case-sensitive string of 1 to 80 characters.
Description
Use the display mpls ldp vpn-instance command to display information about a specified LDP instance.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Display information about the LDP instance corresponding to VPN instance vpn1.
<Sysname> display mpls ldp vpn-instance vpn1
LDP Global Information
--------------------------------------------------------------------
Protocol Version : V1 Neighbor Liveness : 60 Sec
Graceful Restart : Off FT Reconnect Timer : 60 Sec
MTU Signaling : Off Recovery Timer : 60 Sec
LDP Instance Information
--------------------------------------------------------------------
Instance ID : 1 VPN-Instance : vpn1
Instance Status : Active LSR ID : 1.1.1.9
Hop Count Limit : 32 Path Vector Limit : 32
Loop Detection : Off
DU Re-advertise Timer : 30 Sec DU Re-advertise Flag : On
DU Explicit Request : Off Request Retry Flag : On
Label Distribution Mode : Ordered Label Retention Mode : Liberal
For description on the fields of the command output, see Table 1-3.
display mpls lsp
Syntax
display mpls lsp [ incoming-interface interface-type interface-number ] [ outgoing-interface interface-type interface-number ] [ in-label in-label-value ] [ out-label out-label-value ] [ asbr | [ vpn-instance vpn-instance-name ] [ protocol { bgp | bgp-ipv6 | ldp | static } ] ] [ egress | ingress | transit ] [ { exclude | include } dest-addr mask-length ] [ verbose ]
View
Any view
Default Level
1: Monitor level
Parameters
incoming-interface interface-type interface-number: Specifies LSPs using the given interface as the incoming interface. The interface-type interface-number combination specifies an interface by its type and number.
outgoing-interface interface-type interface-number: Specifies LSPs using the given interface as the outgoing interface. The interface-type interface-number combination specifies an interface by its type and number.
in-label in-label-value: Specifies LSPs using the given incoming label. The value of the label ranges 0 to 1048575.
out-label out-label-value: Specifies LSPs using the given outgoing label. The value of the label ranges 0 to 1048575.
asbr: Specifies LSPs established by ASBRs.
vpn-instance vpn-instance-name: Specifies LSPs of a VPN instance. The VPN instance name is a case-sensitive string of 1 to 31 characters.
protocol: Specifies LSPs established by a given protocol.
bgp: Specifies BGP LSPs.
bgp-ipv6: Specifies IPv6 BGP LSPs, that is, BGP4+ LSPs.
ldp: Specifies LDP LSPs.
static: Specifies static LSPs.
egress: Specifies LSPs taking the current LSR as the egress.
ingress: Specifies LSPs taking the current LSR as the ingress.
transit: Specifies LSPs taking the current LSR as a transit LSR.
exclude: Specifies LSPs other than the one for the given FEC.
include: Specifies the LSP for the given FEC.
dest-addr mask-length: Specifies a FEC by its destination address and the length of the mask. The mask length is in the range 0 to 32.
verbose: Displays detailed information.
Description
Use the display mpls lsp command to display information about LSPs.
With no parameters specified, the command displays information about all LSPs.
Related commands: display mpls lsp, display mpls statistics lsp, display mpls static-lsp.
This command supports only VLAN interface.
Examples
# Display information about all LSPs.
<Sysname> display mpls lsp
-----------------------------------------------------------------------
LSP Information: L3VPN LSP
-----------------------------------------------------------------------
FEC In/Out Label In/Out IF Route-Distinguisher Vrf Name
100.1.1.1/32 1025/1024 -/- 100:1 ASBRLSP
-----------------------------------------------------------------------
LSP Information: LDP LSP
-----------------------------------------------------------------------
FEC In/Out Label In/Out IF Vrf Name
100.10.1.0/24 3/NULL -/-
100.10.1.0/24 3/NULL -/-
168.1.0.0/16 3/NULL -/-
172.17.0.0/16 3/NULL -/-
Table 1-6 display mpls lsp command output description
Field |
Description |
FEC |
Forwarding equivalence class, in either of the following two forms: l IP address/mask: Assigning labels based on destination addresses. l IP address: Assigning labels based on the addresses of the next hops. |
# Display detailed information about all LSPs.
<Sysname> display mpls lsp verbose
-------------------------------------------------------------
LSP Information: LDP LSP
-------------------------------------------------------------
No. : 1
VrfIndex :
Fec : 1.1.1.9/32
Nexthop : 127.0.0.1
In-Label : 3
Out-Label : NULL
In-Interface : Vlan-interface3
Out-Interface : ----------
LspIndex : 10241
Tunnel ID : 0x0
LsrType : Egress
Outgoing Tunnel ID : 0x0
Label Operation : POP
Table 1-7 display mpls lsp verbose command output description
Field |
Description |
FEC |
Forwarding equivalence class, in either of the following two forms: l IP address/mask: Assigning labels based on destination addresses. l IP address: Assigning labels based on the addresses of the next hops. |
Tunnel ID |
Tunnel ID (the public network) |
LsrType |
Role of the LSR for the LSP |
Outgoing Tunnel ID |
Tunnel ID (inter-AS VPN) |
display mpls lsp statistics
Syntax
display mpls lsp statistics
View
Any view
Default Level
1: Monitor level
Parameters
None
Description
Use the display mpls lsp statistics command to display LSP statistics.
Examples
# Display LSP statistics.
<Sysname> display mpls lsp statistics
Lsp Type Total Ingress Transit Egress
STATIC LSP 1 1 0 0
STATIC CRLSP 1 1 0 0
LDP LSP 0 0 0 0
CRLDP CRLSP 0 0 0 0
RSVP CRLSP 1 1 0 0
BGP LSP 0 0 0 0
ASBR LSP 0 0 0 0
BGP IPV6 LSP 0 0 0 0
---------------------------------------------------------------
LSP 1 1 0 0
CRLSP 2 2 0 0
Table 1-8 display mpls lsp statistics command output description
Field |
Description |
Ingress |
Number of LSPs taking the current LSR as ingress |
Transit |
Number of LSPs taking the current LSR as transit LSR |
Egress |
Number of LSPs taking the current LSR as egress |
Currently, the S7500E series switches do not support static CR-LSPs, CR-LDP generated CR-LSPs, or RSVP generated CR-LSPs.
display mpls nhlfe
Syntax
display mpls nhlfe [ token ] [ slot slot-number ] [ include text ]
View
Any view
Default Level
1: Monitor level
Parameters
token: NHLFE entry index. The value range varies by device.
include text: Specifies NHLFE entries including a specified string.
slot slot-number: Specifies the NHLFE entries of the board in a slot.
Description
Use the display mpls nhlfe command to display information about NHLFE entries.
With the token argument not specified, the command displays information about all NHLFE entries.
Examples
# Display information about a specified NHLFE entry.
<Sysname> display mpls nhlfe 2
Out-Interface Token Oper Nexthop Deep Stack
----------------------------------------------------------------------
Vlan2 2 PUSH 88.1.1.2 1 1024
# Display information about all NHLFE entries.
<Sysname> display mpls nhlfe
Out-Interface Token Oper Nexthop Deep Stack
----------------------------------------------------------------------
Vlan2 2 PUSH 88.1.1.2 1 1024
Table 1-9 display mpls nhlfe command output description
Field |
Description |
Token |
NHLFE entry index |
Oper |
Operation type |
Deep |
Depth of the MPLS label stack |
Stack |
MPLS label |
display mpls route-state
Syntax
display mpls route-state [ vpn-instance vpn-instance-name ] [ dest-addr mask-length ]
View
Any view
Default Level
1: Monitor level
Parameters
vpn-instance vpn-instance-name: Specifies routes of a VPN instance. The VPN instance name is a case-sensitive string of 1 to 31 characters.
dest-addr mask-length: Specifies routes to a destination address. The mask length is in the range 0 to 32.
Description
Use the display mpls route-state command to display LSP-related route information.
With no VPN instance specified, the command displays information about the routes of the public network instance.
Examples
# Display LSP-related information about all routes.
<Sysname> display mpls route-state
DEST/MASK NEXT-HOP OUT-INTERFACE STATE LSP-COUNT VPN-INDEX
-----------------------------------------------------------------
1.1.1.1/32 10.0.0.1 Vlan2 ESTA 1 0
Table 1-10 display mpls route-state command output description
Field |
Description |
LSP-COUNT |
Number of LSPs |
VPN-INDEX |
Index number of the VPN instance |
display mpls static-lsp
Syntax
display mpls static-lsp [ lsp-name lsp-name ] [ { exclude | include } dest-addr mask-length ] [ verbose ]
View
Any view
Default Level
1: Monitor level
Parameters
lsp-name lsp-name: Specifies an LSP by its name, which is a string of 1 to 15 characters.
exclude: Specifies LSPs other than the one for the given FEC.
include: Specifies the LSP for the given FEC.
dest-addr mask-length: Specifies a FEC by its destination address and the length of the mask. The mask length is in the range 0 to 32.
verbose: Displays detailed information.
Description
Use the display mpls static-lsp command to display information about static LSPs.
Related commands: display mpls lsp, display mpls statistics lsp.
Examples
# Display brief information about all static LSPs.
<Sysname> display mpls static-lsp
Name FEC I/O Label I/O If State
lsp1 3.3.3.9/32 NULL/100 -/Vlan1 Up
# Display detailed information about all static LSPs.
<Sysname> display mpls static-lsp verbose
No : 1
LSP-Name : lsp1
LSR-Type : Ingress
FEC : 3.3.3.9/32
In-Label : NULL
Out-Label : 100
In-Interface : -
Out-Interface : Vlan-interface1
NextHop : 30.1.1.2
Static-Lsp Type: IPTN
Lsp Status : Up
Table 1-11 display mpls static-lsp verbose command output description
Field |
Description |
LSR-Type |
Role of the LSR for the LSP, which can be ingress, egress, or transit |
Static-Lsp Type |
Type of the static LSP |
display mpls statistics interface
Syntax
display mpls statistics interface { interface-type interface-number | all }
View
Any view
Default Level
1: Monitor level
Parameters
interface-type interface-number: Specifies an interface by its type and number.
all: Specifies all interfaces.
Description
Use the display mpls statistics interface command to display MPLS statistics for one or all interfaces.
Note that:
To display statistics on a device, set the statistics interval first. By default, the interval is 0 and the system does not collect MPLS statistics. In this case, the value of every statistic is 0.
Related commands: statistics interval, mpls statistics enable.
Examples
# Display MPLS statistics for all interfaces.
<Sysname> display mpls statistics interface all
Statistics for Interface IN :
Incoming Interface Vlan-interface1
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Failed Label Lookup : 0
Start Time : 2008/04/28 10:23:55
End Time : 2008/04/28 10:23:55
Statistics for Interface OUT :
Outgoing Interface Vlan-interface2
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Start Time : 2008/04/28 10:23:55
End Time : 2008/04/28 10:23:55
Statistics for Interface IN :
Incoming Interface Vlan-interface3
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Failed Label Lookup : 0
Start Time : 2008/04/28 10:24:04
End Time : 2008/04/28 10:24:04
Statistics for Interface OUT :
Outgoing Interface Vlan-interface4
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Start Time : 2008/04/28 10:24:04
End Time : 2008/04/28 10:24:04
Statistics for Interface IN :
Incoming Interface Vlan-interface53
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Failed Label Lookup : 0
Start Time : 2008/04/28 10:24:10
End Time : 2008/04/28 10:24:10
Statistics for Interface OUT :
Outgoing Interface Vlan-interface73
Octets : 0
Packets : 0
Errors : 0
Disables : 0
Start Time : 2008/04/28 10:24:10
End Time : 2008/04/28 10:24:10
Table 1-12 display mpls statistics interface command output description
Field |
Description |
Statistics for Interface IN |
Statistics for an interface in the incoming direction |
Statistics for Interface OUT |
Statistics for an interface in the outgoing direction |
Octets |
Number of bytes processed |
Packets |
Number of packets processed |
Errors |
Number of errors |
Disables |
Number of MPLS disables |
Start Time |
Start time of the statistics |
End Time |
End time of the statistics |
display mpls statistics lsp
Syntax
display mpls statistics lsp { index | all | name lsp-name }
View
Any view
Default Level
1: Monitor level
Parameters
index: Index number of the LSP, in the range 0 to 4294967295.
all: Specifies all LSPs.
lsp-name: Name of the LSP, a string of 1 to 15 characters.
Description
Use the display mpls statistics lsp command to display MPLS statistics for all LSPs or the LSP with a specified index or name.
To display MPLS statistics, set the statistics interval first. By default, the interval is 0 and the system does not collect LSP statistics. In this case, the value of every statistic is 0.
Related commands: statistics interval.
Examples
# Display MPLS statistics for all LSPs.
<Sysname> display mpls statistics lsp all
Statistics for Lsp IN : LSP Name /LSP Index : DynamicLsp/9217
InSegment
Octets : 0
Packets : 0
Errors : 0
Down : 0
Start Time : 2006/05/20 15:52:30
End Time : 2006/05/20 15:52:30
Statistics for Lsp OUT : LSP Name /LSP Index : DynamicLsp/9217
OutSegment
Octets : 0
Packets : 0
Errors : 0
Down : 0
Start Time : 0000/00/00 00:00:00
End Time : 0000/00/00 00:00:00
Statistics for Lsp IN : LSP Name /LSP Index : DynamicLsp/9218
InSegment
Octets : 0
Packets : 0
Errors : 0
Down : 0
Start Time : 0000/00/00 00:00:00
End Time : 0000/00/00 00:00:00
Statistics for Lsp OUT : LSP Name /LSP Index : DynamicLsp/9218
OutSegment
Octets : 0
Packets : 0
Errors : 0
Down : 0
Start Time : 2006/05/20 15:52:30
End Time : 2006/05/20 15:52:30
Table 1-13 display mpls statistics lsp command output description
Field |
Description |
Statistics for Lsp IN : LSP Name /LSP Index : DynamicLsp/10241 |
Statistics for LSP DynamicLsp/10241 in the incoming direction |
InSegment |
Information about the LSP in the incoming direction |
OutSegment |
Information about the LSP in the outgoing direction |
Octets |
Bytes of data processed |
Packets |
Number of packets processed |
Errors |
Number of errors |
Down |
Number of packets discarded |
Start Time |
Start time of the statistics |
End Time |
End time of the statistics |
l For an ingress, no statistics is collected in the incoming direction and the start time and end time in the InSegment part of the command output are both 0.
l Similarly, for an egress, no statistics is collected in the outgoing direction and the start time and end time in the OutSegment part of the command output are both 0.
du-readvertise
Syntax
du-readvertise
undo du-readvertise
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
None
Description
Use the du-readvertise command to enable label readvertisement for DU mode.
Use the undo du-readvertise command to disable the feature.
By default, label readvertisement is enabled in DU mode.
Examples
# Enable DU mode label readvertisement for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] du-readvertise
# Enable DU mode label readvertisement for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] du-readvertise
du-readvertise timer
Syntax
du-readvertise timer value
undo du-readvertise timer
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
value: Label readvertisement interval, in the range 1 to 65535 seconds.
Description
Use the du-readvertise timer command to set the interval for label readvertisement in DU mode.
Use the undo du-readvertise timer command to restore the default.
By default, the interval for label readvertisement in DU mode is 30 seconds.
Examples
# Set the DU mode label readvertisement interval to 100 seconds for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] du-readvertise timer 100
# Set the DU mode label readvertisement interval to 100 seconds for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] du-readvertise timer 100
graceful-restart (MPLS LDP view)
Syntax
graceful-restart
undo graceful-restart
View
MPLS LDP view
Default Level
1: Monitor level
Parameters
None
Description
Use the graceful-restart command to enable MPLS LDP Graceful Restart (GR).
Use the undo graceful-restart command to disable MPLS LDP GR.
By default, MPLS LDP GR is disabled.
Note that enabling or disabling GR will cause all LDP sessions and all LSPs based on the sessions to be removed and then reestablished.
Examples
# Enable MPLS LDP GR.
<Sysname> system-view
[Sysname] mpls lsr-id 1.1.1.1
[Sysname] mpls
[Sysname-mpls] quit
[Sysname] mpls ldp
[Sysname-mpls-ldp] graceful-restart
graceful-restart mpls ldp
Syntax
graceful-restart mpls ldp
View
User view
Default Level
2: System level
Parameters
None
Description
Use the graceful-restart mpls ldp command to restart MPLS LDP gracefully.
Note that:
l This command is used to test MPLS LDP GR without main/backup switchover. It is not recommended in normal cases.
l The MPLS LDP GR capability is required for this command to take effect.
Related commands: graceful-restart (MPLS LDP view).
Examples
# Restart MPLS LDP gracefully.
<Sysname> graceful-restart mpls ldp
graceful-restart timer neighbor-liveness
Syntax
graceful-restart timer neighbor-liveness timer
undo graceful-restart timer neighbor-liveness
View
MPLS LDP view
Default Level
1: Monitor level
Parameters
timer: LDP neighbor liveness time, in the range 60 to 300 seconds.
Description
Use the graceful-restart timer neighbor-liveness command to set the LDP neighbor liveness time.
Use the undo graceful-restart timer neighbor-liveness command to restore the default.
By default, the LDP neighbor liveness time is 120 seconds.
Note that:
l Modifying the LDP neighbor liveness time will cause all LDP sessions and all LSPs based on the sessions to be removed and then reestablished.
l For LDP sessions with MD5 authentication configured, you need to give the LDP neighbor liveness time a greater value so that the TCP connection can be reestablished.
Examples
# Set the LDP neighbor liveness time to 100 seconds.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] graceful-restart timer neighbor-liveness 100
graceful-restart timer reconnect
Syntax
graceful-restart timer reconnect timer
undo graceful-restart timer reconnect
View
MPLS LDP view
Default Level
1: Monitor level
Parameters
timer: Fault Tolerance (FT) reconnect time, in the range 60 to 300 seconds.
Description
Use the graceful-restart timer reconnect command to set the FT reconnect time.
Use the undo graceful-restart timer reconnect command to restore the default.
By default, the FT reconnect time is 300 seconds.
Note that:
l The FT reconnect time refers to the maximum time that the stale state flag will be preserved by the LSR after the TCP connection fails.
l Modifying the FT reconnect time will cause all LDP sessions and all LSPs based on the sessions to be removed and then reestablished.
Examples
# Set the FT reconnect time to 100 seconds.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] graceful-restart timer reconnect 100
graceful-restart timer recovery
Syntax
graceful-restart timer recovery timer
undo graceful-restart timer recovery
View
MPLS LDP view
Default Level
1: Monitor level
Parameters
timer: LDP recovery time, in the range 3 to 300 seconds.
Description
Use the graceful-restart timer recovery command to set the LDP recovery time.
Use the undo graceful-restart timer recovery command to restore the default.
By default, the LDP recovery time is 300 seconds.
Note that:
l The LDP recovery time refers to the maximum time that the stale state label will be kept by the LSR after a TCP reconnection.
l Modifying the LDP recovery time will cause all LDP sessions and all LSPs based on the sessions to be removed and then reestablished.
Examples
# Set the LDP recovery time to 45 seconds.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] graceful-restart timer recovery 45
hops-count
Syntax
hops-count hop-number
undo hops-count
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
hop-number: Hop count, in the range 1 to 32.
Description
Use the hops-count command to set the maximum hop count for loop detection.
Use the undo hops-count command to restore the default.
By default, the maximum hop count for loop detection is 32.
Note that:
l You need to configure this command before enabling LDP on any interface.
l The maximum hop count dictates how fast LDP detects a loop. Adjust this argument as required.
Related commands: loop-detect, path-vectors.
Examples
# Set the maximum hop count for loop detection to 25 for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] hops-count 25
# Set the maximum hop count for loop detection to 25 for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] hops-count 25
label advertise
Syntax
label advertise { explicit-null | implicit-null | non-null }
undo label advertise
View
MPLS view
Default Level
2: System level
Parameters
explicit-null: Specifies that the egress supports PHP and distributes to the penultimate hop an explicit null label, whose value is 0.
implicit-null: Specifies that the egress supports PHP and distributes to the penultimate hop an implicit null label, whose value is 3.
non-null: Specifies that the egress does not support PHP and distributes to the penultimate hop a normal label, whose value is not less than 1024.
Description
Use the label advertise command to specify whether the egress should support PHP and what type of label the egress should distribute to the penultimate hop.
Use the undo label advertise command to restore the default.
By default, an egress supports PHP and distributes to the penultimate hop an implicit null label.
l The type of label for an egress to distribute depends on whether the penultimate hop supports PHP.
l If LDP sessions have been established, you need to use the reset mpls ldp command to reset the sessions to bring the label advertise command into effect.
Examples
# Configure the egress to distribute an explicit null label to the penultimate hop.
<Sysname> system-view
[Sysname] mpls
[Sysname-mpls] label advertise explicit-null
label-distribution
Syntax
label-distribution { independent | ordered }
undo label-distribution
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
independent: Works in independent mode, advertising label bindings anytime.
ordered: Works in ordered mode, advertising to its upstream a label binding for a FEC only when it receives a specific label binding message from the next hop of the FEC or it is the egress of the FEC.
Description
Use the label-distribution command to specify the label distribution control mode.
Use the undo label-distribution command to restore the default.
The default mode is ordered.
If LDP sessions have been established, you must use the reset mpls ldp command to reset LDP sessions for this command to take effect.
Examples
# Set the label distribution control mode to independent for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] label-distribution independent
# Set the label distribution control mode to independent for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] label-distribution independent
loop-detect
Syntax
loop-detect
undo loop-detect
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
None
Description
Use the loop-detect command to enable loop detection.
Use the undo loop-detect command to disable loop detection.
By default, loop detection is disabled.
Note that you need to enable loop detection before enabling LDP on any interface.
Related commands: hops-count, path-vectors.
Examples
# Enable loop detection for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] loop-detect
# Enable loop detection for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] loop-detect
lsp-trigger
Syntax
lsp-trigger { all | ip-prefix prefix-name }
undo lsp-trigger { all | ip-prefix prefix-name }
View
MPLS view
Default Level
2: System level
Parameters
all: Specifies all FECs, that is, all static routes and IGP routes.
prefix-name: Name of the IP address prefix list, a string of 1 to 19 characters.
Description
Use the lsp-trigger command to configure the LSP establishment triggering policy.
Use the undo lsp-trigger command to restore the default.
By default, only loopback addresses with 32-bit masks can trigger LDP to establish LSPs.
Note that:
l With the all keyword specified in the lsp-trigger command, all static and IGP routes can trigger LDP to establish LSPs.
l With the ip-prefix prefix-name keyword and argument combination specified in the lsp-trigger command, only static and IGP routes permitted by the IP address prefix list can trigger LDP to establish LSPs.
l An IP address prefix list affects only static routes and IGP routes.
l For an LSP to be established, an exactly matching routing entry must exist on the LSR. With loopback addresses using 32-bit masks, only exactly matching host routing entries can trigger LDP to establish LSPs.
l For information about IP address prefix list, refer to Routing Policy Configuration in the IP Routing Volume.
Examples
# Configure LDP to allow all static and IGP routes to trigger LSP establishment.
<Sysname> system-view
[Sysname] mpls
[Sysname-mpls] lsp-trigger all
lsr-id
Syntax
lsr-id lsr-id
undo lsr-id
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
lsr-id: LDP LSR ID.
Description
Use the lsr-id command to configure an LDP LSR ID.
Use the undo lsr-id command to remove a configured LDP LSR ID and all LDP sessions.
By default, the LDP LSR ID takes the value of the MPLS LSR ID.
Examples
# Configure the LDP LSR ID of the public network LDP.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] lsr-id 2.2.2.3
# Configure the LDP LSR ID of LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] lsr-id 4.2.2.3
md5-password
Syntax
md5-password { cipher | plain } peer-lsr-id password
undo md5-password peer-lsr-id
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
cipher: Displays the password in cipher text.
plain: Displays the password in plain text.
peer-lsr-id: MPLS LSR ID of the peer. An LSR and its peer must use the same password.
password: Password string, case sensitive. If you specify the plain keyword, it must be a string of 1 to 16 characters in plain text. If you specify the cipher keyword, it can be either a string of 1 to 16 characters in plain text or a string of 24 characters in cipher text.
Description
Use the md5-password command to enable LDP MD5 authentication and set the password, which must be the same as that configured on the peer.
Use the undo md5-password command to disable LDP MD5 authentication.
By default, LDP MD5 authentication is disabled.
Changing the password will cause the sessions and all LSPs based on the sessions to be removed.
This command takes effect only after MPLS LDP is enabled in the corresponding view.
Examples
# Enable MD5 authentication for the public network LDP instance, setting the password display mode to plain text.
[Sysname] mpls ldp
[Sysname-mpls-ldp] md5-password plain 3.3.3.3 beijingpass
# Enable MD5 authentication for LDP instance vpn1, setting the password display mode to plain text.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] md5-password plain 3.3.3.3 beijingpass
mpls
Syntax
mpls
undo mpls
View
System view, interface view
Default Level
2: System level
Parameters
None
Description
Use the mpls command in system view to enable MPLS globally and enter MPLS view.
Use the undo mpls command in system view to disable MPLS globally.
Use the mpls command in interface view to enable MPLS for the interface.
Use the undo mpls command in interface view to disable MPLS for the interface.
By default, MPLS capability is not enabled.
Note that:
l You need to configure the LSR ID before enabling MPLS capability.
l You need to enable MPLS globally before enabling it for an interface.
Related commands: mpls lsr-id.
Examples
# Enable MPLS globally.
<Sysname> system-view
[Sysname] mpls lsr-id 1.1.1.1
[Sysname] mpls
[Sysname-mpls] quit
# Enable MPLS for interface VLAN-interface 1.
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] mpls
mpls ldp (system view)
Syntax
mpls ldp [ vpn-instance vpn-instance-name ]
undo mpls ldp [ vpn-instance vpn-instance-name ]
View
System view
Default Level
1: Monitor level
Parameters
vpn-instance-name: Name of the VPN instance, a case-sensitive string of 1 to 31 characters.
Description
Use the mpls ldp command to enable LDP globally and enter MPLS LDP view.
Use the undo mpls ldp command to disable LDP globally and remove all LDP instances.
Use the mpls ldp vpn-instance command to enable LDP for a VPN instance, create an LDP instance, and enter MPLS LDP VPN instance view.
Use the undo mpls ldp vpn-instance command to disable LDP for a VPN instance and remove the LDP instance.
By default, MPLS LDP is disabled.
Configure the mpls ldp command after configuring the MPLS LSR ID and enabling MPLS globally.
Examples
# Enable LDP globally and enter MPLS LDP view.
<Sysname> system-view
[Sysname] mpls lsr-id 1.1.1.1
[Sysname] mpls
[Sysname-mpls] quit
[Sysname] mpls ldp
[Sysname-mpls-ldp]
# Enable LDP for VPN instance vpn1 and enter MPLS LDP VPN instance view.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1]
mpls ldp (interface view)
Syntax
mpls ldp
undo mpls ldp
View
Interface view
Default Level
1: Monitor level
Parameters
None
Description
Use the mpls ldp command to enable LDP on an interface.
Use the undo mpls ldp command to disable LDP on an interface.
By default, LDP is disabled on an interface.
After you enable LDP on an interface, the interface will periodically send Hello messages.
Before enabling LDP in interface view, be sure to complete the following tasks:
l Use the mpls lsr-id command in system view to configure the LSR ID.
l Use the mpls command in system view to enable MPLS.
l Use the mpls ldp command in system view to enable MPLS LDP globally.
l Use the mpls command in interface view to enable MPLS for the interface.
If the interface is bound to a VPN instance, you need to use the mpls ldp vpn-instance command to enable LDP for the VPN instance before enabling LDP on the interface.
Currently, this command supports only VLAN interface.
Examples
# Enable LDP for interface VLAN-interface 1.
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] mpls
[Sysname-Vlan-interface1] mpls ldp
mpls ldp remote-peer
Syntax
mpls ldp remote-peer remote-peer-name
undo mpls ldp remote-peer remote-peer-name
View
System view
Default Level
1: Monitor level
Parameters
remote-peer-name: Name of the remote peer, a case-insensitive string of 1 to 32 characters.
Description
Use the mpls ldp remote-peer command to create a remote peer entity and enter MPLS LDP remote peer view.
Use the undo mpls ldp remote-peer command to remove a remote peer entity.
Related commands: remote-ip.
Examples
# Create a remote peer entity named BJI and enter MPLS LDP remote peer view.
<Sysname> system-view
[Sysname] mpls ldp remote-peer BJI
[Sysname-mpls-ldp-remote-bji]
mpls ldp timer hello-hold
Syntax
mpls ldp timer hello-hold value
undo mpls ldp timer hello-hold
View
Interface view, MPLS LDP remote peer view
Default Level
1: Monitor level
Parameters
value: Length of time for the Hello timer, in the range 1 to 65535 seconds.
Description
Use the mpls ldp timer hello-hold command to set a Hello timer.
Use the undo mpls ldp timer hello-hold command to restore the default.
In interface view, you can set the link Hello timer; in MPLS LDP remote peer view, you can set the targeted Hello timer.
By default, the value of the link Hello timer is 15 seconds, and that of the targeted Hello timer is 45 seconds.
Changing the values of the Hello timers does not affect any existing session.
Related commands: mpls ldp (system view), mpls ldp (interface view).
Examples
# Set the link Hello timer to 100 seconds on interface VLAN-interface 1.
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] mpls
[Sysname-Vlan-interface1] mpls ldp
[Sysname-Vlan-interface1] mpls ldp timer hello-hold 100
# Set the targeted Hello timer to 1000 seconds.
<Sysname> system-view
[Sysname] mpls ldp remote-peer BJI
[Sysname-mpls-ldp-remote-bji] remote-ip 3.3.3.3
[Sysname-mpls-ldp-remote-bji] mpls ldp timer hello-hold 1000
mpls ldp timer keepalive-hold
Syntax
mpls ldp timer keepalive-hold value
undo mpls ldp timer keepalive-hold
View
Interface view, MPLS LDP remote peer view
Default Level
1: Monitor level
Parameters
value: Length of time for the Keepalive timer, in the range 1 to 65535 seconds.
Description
Use the mpls ldp timer keepalive-hold command to set a keepalive timer.
Use the undo mpls ldp timer keepalive-hold command to restore the default.
In interface view, you can set the link Keepalive timer; in MPLS LDP remote peer view, you can set the targeted Keepalive timer.
By default, both the link Keepalive timer and targeted Keepalive timer are set to 45 seconds.
l If more than one link with LDP enabled exists between two LSRs (for example, when the two LSRs are connected through multiple interfaces), the Keepalive timers of all the links must be identical for the sessions to be stable.
l Changing the values of the Keepalive timers will cause all LDP sessions and the LSPs based on the sessions to be removed and then reestablished.
Examples
# Set the link Keepalive timer to 50 seconds on interface VLAN-interface 1.
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] mpls
[Sysname-Vlan-interface1] mpls ldp
[Sysname-Vlan-interface1] mpls ldp timer keepalive-hold 50
# Set the targeted Keepalive timer to 1000 seconds.
<Sysname> system-view
[Sysname] mpls ldp remote-peer BJI
[Sysname-mpls-ldp-remote-bji] remote-ip 3.3.3.3
[Sysname-mpls-ldp-remote-bji] mpls ldp timer keepalive-hold 1000
mpls ldp transport-address
Syntax
mpls ldp transport-address { ip-address | interface }
undo mpls ldp transport-address
View
Interface view, MPLS LDP remote peer view
Default Level
1: Monitor level
Parameters
ip-address: IP address for LDP to use as the TCP transport address.
interface: Specifies that LDP use the IP address of the current interface as the TCP transport address. This keyword is available only in interface view.
Description
Use the mpls ldp transport-address command to configure an LDP transport address.
Use the undo mpls ldp transport-address command to restore the default.
By default, a transport address takes the value of the MPLS LSR ID.
In interface view, you configure the link Hello transport address; in MPLS LDP remote peer view, you configure the targeted Hello transport address.
Examples
# On interface VLAN-interface 1, configure the link Hello transport address as the IP address of the current interface.
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] mpls
[Sysname-Vlan-interface1] mpls ldp
[Sysname-Vlan-interface1] mpls ldp transport-address interface
# Configure the targeted Hello transport address to be 10.1.1.1.
<Sysname> system-view
[Sysname] mpls ldp remote-peer BJI
[Sysname-mpls-ldp-remote-bji] remote-ip 3.3.3.3
[Sysname-mpls-ldp-remote-bji] mpls ldp transport-address 10.1.1.1
mpls lsr-id
Syntax
mpls lsr-id lsr-id
undo mpls lsr-id
View
System view
Default Level
2: System level
Parameters
lsr-id: ID for identifying the LSR, in dotted decimal notation.
Description
Use the mpls lsr-id command to configure the ID of an LSR.
Use the undo mpls lsr-id command to remove the ID of an LSR.
By default, no LSR ID is configured.
Your need to configure the LSR ID of an LSR before configuring any other MPLS commands.
You are recommended to use the address of a loopback interface on the LSR as the ID.
Related commands: display mpls interface.
Examples
# Set the LSR ID to 3.3.3.3.
<Sysname> system-view
[Sysname] mpls lsr-id 3.3.3.3
path-vectors
Syntax
path-vectors pv-number
undo path-vectors
View
MPLS LDP view, MPLS LDP VPN instance view
Default Level
1: Monitor level
Parameters
pv-number: Maximum path vector length, in the range 1 to 32.
Description
Use the path-vectors command to set the maximum path vector length.
Use the undo path-vectors command to restore the default.
By default, the maximum path vector length for an instance is 32.
Note that this command must be configured before you enable MPLS LDP on any interface.
Related commands: loop-detect, hops-count.
Examples
# Set the maximum path vector length to 3 for the public network LDP instance.
<Sysname> system-view
[Sysname] mpls ldp
[Sysname-mpls-ldp] path-vectors 3
# Set the maximum path vector length to 3 for LDP instance vpn1.
<Sysname> system-view
[Sysname] mpls ldp vpn-instance vpn1
[Sysname-mpls-ldp-vpn-instance-vpn1] path-vectors 3
ping lsp
Syntax
ping lsp [ -a source-ip | -c count | -exp exp-value | -h ttl-value | -m wait-time | -r reply-mode | -s packet-size | -t time-out | -v ] * ipv4 dest-addr mask-length [ destination-ip-addr-header ]
View
Any view
Default Level
0: Visit level
Parameters
-a source-ip: Specifies the source address for the echo request messages.
-c count: Specifies the number of request messages to be sent. The count argument ranges from 1 to 4294967295.
-exp exp-value: Specifies the EXP value for the echo request message. The exp-value argument ranges from 0 to 7.
-h ttl-value: Specifies the TTL value for the echo request message. The ttl-value argument ranges from 1 to 255.
-m wait-time: Specifies the interval for sending echo request messages. The wait-time argument ranges from 1 to 10,000 ms.
-r reply-mode: Specifies the reply mode in response to an echo request message. The reply-mode argument can be 1 or 2. A value of 1 means “Do not response”, while a value of 2 means “Respond using a UDP packet”.
-s packet-size: Specifies the payload length of the echo request message. The packet-size argument ranges from 64 to 8100 bytes.
-t time-out: Specifies the timeout interval for the response to an echo request message. The time-out argument ranges from 0 to 65535 milliseconds.
-v: Displays detailed response information.
ipv4 dest-addr mask-length: Specifies the IPv4 destination address of the LSP and the mask. The mask-length argument ranges from 0 to 32.
destination-ip-addr-header: Specifies the IP header destination address for the MPLS echo request messages. It can be any address on segment 127.0.0.0/8, that is, any local loopback address.
Description
Use the ping lsp command to check the validity and reachability of an LSP.
Examples
# Ping a specified address, sending five packets.
<Sysname> ping lsp –c 5 ipv4 3.3.3.9 32
LSP PING FEC: LDP IPV4 PREFIX 3.3.3.9/32 : 100 data bytes, press CTRL_C to break
Reply from 100.1.2.1: bytes=100 Sequence=0 time = 31 ms
Reply from 100.1.2.1: bytes=100 Sequence=1 time = 62 ms
Reply from 100.1.2.1: bytes=100 Sequence=2 time = 62 ms
Reply from 100.2.3.1: bytes=100 Sequence=3 time = 62 ms
Reply from 100.1.2.1: bytes=100 Sequence=4 time = 62 ms
--- FEC: LDP IPV4 PREFIX 3.3.3.9/32 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 31/55/62 ms
remote-ip
Syntax
remote-ip ip-address
undo remote-ip
View
MPLS LDP remote peer view
Default Level
1: Monitor level
Parameters
ip-address: Remote peer IP address.
Description
Use the remote-ip command to configure the remote peer IP address.
Use the undo remote-ip command to remove the configuration.
Note that the remote peer IP address must be the MPLS LSR ID of the remote peer. Two peers use their MPLS LSR IDs as the transport addresses to establish the TCP connection.
Related commands: mpls ldp remote-peer.
Examples
# Configure the remote peer IP address.
<Sysname> system-view
[Sysname] mpls ldp remote-peer BJI
[Sysname-mpls-ldp-remote-bji] remote-ip 3.3.3.3
reset mpls ldp
Syntax
reset mpls ldp [ all | [ vpn-instance vpn-instance-name ] [ fec mask | peer peer-id ] ]
View
User view
Default Level
2: System level
Parameters
all: Specifies all LDP instances, including the public one and private ones.
vpn-instance vpn-instance-name: Specifies a VPN instance by its name, a case-sensitive string of 1 to 31 characters.
fec mask: Specifies a FEC by the destination IP address and mask.
peer peer-id: Specifies a peer by its LSR ID.
Description
Use the reset mpls ldp command to reset LDP sessions.
With no parameters specified, the command resets all sessions of the public network LDP instance.
Examples
# Reset all sessions of the public network LDP instance.
<Sysname> reset mpls ldp
# Reset the sessions of all LDP instances.
<Sysname> reset mpls ldp all
# Reset the sessions of LDP instance vpn1.
<Sysname> reset mpls ldp vpn-instance vpn1
# Reset the sessions of a specified FEC.
<Sysname> reset mpls ldp 2.2.2.2 24
# Reset the sessions with a specified peer.
<Sysname> reset mpls ldp peer 2.2.2.9
reset mpls statistics interface
Syntax
reset mpls statistics interface { interface-type interface-number | all }
View
User view
Default Level
2: System level
Parameters
interface-type interface-number: Specifies an interface by its type and number.
all: Specifies all interfaces.
Description
Use the reset mpls statistics interface command to clear MPLS statistics for one or all MPLS interfaces.
Related commands: display mpls statistics interface.
Examples
# Clear MPLS statistics for interface VLAN-interface 1.
<Sysname> reset mpls statistics interface vlan-interface 1
reset mpls statistics lsp
Syntax
reset mpls statistics lsp { index | all | name lsp-name }
View
User view
Default Level
2: System level
Parameters
index: Index number of the LSP, in the range 0 to 4294967295.
all: Specifies all LSPs.
lsp-name: Name of the LSP, a string of 1 to 15 characters.
Description
Use the reset mpls statistics lsp command to clear MPLS statistics for all LSPs or the LSP with a specified index or name.
Related commands: display mpls statistics lsp.
Examples
# Clear MPLS statistics for LSP lsp1.
<Sysname> reset mpls statistics lsp lsp1
static-lsp egress
Syntax
static-lsp egress lsp-name incoming-interface interface-type interface-number in-label in-label
undo static-lsp egress lsp-name
View
System view
Default Level
2: System level
Parameters
lsp-name: Name for the LSP, a string of 1 to 15 characters.
interface-type interface-number: Specifies an interface by its type and number.
in-label: Incoming label value, in the range 16 to 1023.
Description
Use the static-lsp egress command to configure a static LSP taking the current LSR as the egress.
Use the undo static-lsp egress command to remove a static LSP taking the current LSR as the egress.
Related commands: static-lsp ingress, static-lsp transit, display mpls static-lsp.
Examples
# Configure a static LSP named bj-sh, taking the current LSR as the egress.
<Sysname> system-view
[Sysname] static-lsp egress bj-sh incoming-interface vlan-interface 2 in-label 233
static-lsp ingress
Syntax
static-lsp ingress lsp-name destination dest-addr { mask | mask-length } nexthop next-hop-addr out-label out-label
undo static-lsp ingress lsp-name
View
System view
Default Level
2: System level
Parameters
lsp-name: Name for the LSP, a string of 1 to 15 characters.
dest-addr: Destination IP address of the LSP.
mask: Mask of the destination IP address.
mask-length: Length of the mask for the destination address, in the range 0 to 32.
next-hop-addr: Address of the next hop.
out-label: Outgoing label, in the range 16 to 1023.
Description
Use the static-lsp ingress command to configure a static LSP taking the current LSR as the ingress.
Use the undo static-lsp ingress command to remove a static LSP taking the current LSR as the ingress.
Note that:
l If you specify the next hop when configuring a static LSP, and the address of the next hop is present in the routing table, you also need to specify the next hop when configuring the static IP route.
l If you specify the outgoing interface when configuring a static LSP, you also need to specify the outgoing interface when configuring the static IP route.
l The address of the next hop cannot be any local public network IP address.
Related commands: static-lsp egress, static-lsp transit, display mpls static-lsp.
Examples
# Configure a static LSP to destination address 202.25.38.1, taking the current LSR as the ingress.
<Sysname> system-view
[Sysname] static-lsp ingress bj-sh destination 202.25.38.1 24 nexthop 202.55.25.33 out-label 237
static-lsp transit
Syntax
static-lsp transit lsp-name incoming-interface interface-type interface-number in-label in-label nexthop next-hop-addr out-label out-label
undo static-lsp transit lsp-name
View
System view
Default Level
2: System level
Parameters
lsp-name: Name for the LSP, a string of 1 to 15 characters.
incoming-interface interface-type interface-number: Specifies an incoming interface by its type and number.
in-label: Incoming label, in the range 16 to 1023.
next-hop-addr: Address of the next hop.
out-label: Outgoing label, in the range 16 to 1023.
Description
Use the static-lsp transit command to configure a static LSP taking the current LSR as a transit LSR.
Use the undo static-lsp transit command to remove a static LSP taking the current LSR as a transit LSR.
Note that:
l If you specify the next hop when configuring a static LSP, and the address of the next hop is present in the routing table, you also need to specify the next hop when configuring the static IP route.
l If you specify the outgoing interface when configuring a static LSP, you also need to specify the outgoing interface when configuring the static IP route.
l The address of the next hop cannot be any local public network IP address.
Related commands: static-lsp egress, static-lsp ingress.
Examples
# Configure a static LSP, taking interface Vlan-interface 2 as the incoming interface and setting the incoming label as 123 and the outgoing label as 253.
<Sysname> system-view
[Sysname] static-lsp transit bj-sh incoming-interface Vlan-interface 2 in-label 123 nexthop 202.34.114.7 out-label 253
statistics interval
Syntax
statistics interval interval-time
undo statistics interval
View
MPLS view
Default Level
2: System level
Parameters
interval-time: Statistics Interval, in the range 30 to 65535 seconds.
Description
Use the statistics interval command to set the statistics interval, that is, the interval for collecting statistics.
Use the undo statistics interval command to restore the default.
By default, the interval is 0, that is, the system does not collect statistics.
Related commands: display mpls statistics interface, display mpls statistics lsp.
Examples
# Set the statistics interval to 30 seconds.
<Sysname> system-view
[Sysname] mpls
[Sysname-mpls] statistics interval 30
tracert lsp
Syntax
tracert lsp [-a source-ip | -exp exp-value | -h ttl-value | -r reply-mode |-t time-out ] * ipv4 dest-addr mask-length [ destination-ip-addr-header ]
View
Any view
Default Level
0: Visit level
Parameters
-a source-ip: Specifies the source address for the echo request messages.
-exp exp-value: Specifies the EXP value for the echo request messages. The exp-value argument ranges from 0 to 7.
-h ttl-value: Specifies the TTL value for the echo request messages. The ttl-value argument ranges from 1 to 255.
-r reply-mode: Specifies the reply mode in response to an echo request message. The reply-mode argument can be 1 or 2. A value of 1 means “Do not response”, while a value of 2 means “Respond using a UDP packet”.
-t time-out: Specifies the timeout interval for the response to an echo request message. The time-out argument ranges from 0 to 65535 milliseconds.
ipv4 dest-addr mask: Specifies the LDP IPv4 destination address and the mask. The mask argument ranges from 0 to 32.
destination-ip-addr-header: Specifies the IP header destination address for the MPLS echo request messages. It can be any address on segment 127.0.0.0/8, that is, any local loopback address.
Description
Use the tracert lsp command to locate an MPLS LSP error.
Examples
# Locate an error along the LSP to 3.3.3.9 on host 1.1.1.1.
<Sysname> tracert lsp ipv4 3.3.3.9 32
LSP Trace Route FEC: LDP IPV4 PREFIX 3.3.3.9/32 , press CTRL_C to break.
TTL Replier Time Type Downstream
0 Ingress 10.4.5.1/[1025]
1 10.4.5.1 1 Transit 100.3.4.1/[1024]
2 100.1.4.2 63 Transit 100.1.2.1/[3]
3 100.1.2.1 129 Egress
ttl expiration pop
Syntax
ttl expiration pop
undo ttl expiration pop
View
MPLS view
Default Level
2: System level
Parameters
None
Description
Use the ttl expiration pop command to specify that ICMP responses travel along the IP route when the TTL of an MPLS packet expires.
Use the undo ttl expiration pop command to specify that ICMP responses travel along the LSP when the TTL of an MPLS packet expires.
By default, ICMP responses of an MPLS packet with a one-level label stack travel along the IP route.
Note that configuring the undo mpls command will remove the configurations of the ttl expiration pop command.
Related commands: ttl propagate.
Examples
# Specify that ICMP responses travel along the LSP when the TTL of an MPLS packet expires.
<Sysname> system-view
[Sysname] mpls
[Sysname-mpls] undo ttl expiration pop
ttl propagate
Syntax
ttl propagate { public | vpn }
undo ttl propagate { public | vpn }
View
MPLS view
Default Level
2: System level
Parameters
public: Specifies public network packets.
vpn: Specifies VPN packets.
Description
Use the ttl propagate command to enable MPLS IP TTL propagation for public network packets or VPN packets.
Use the undo ttl propagate command to disable the function.
By default, MPLS IP TTL propagation is enabled for only public network packets.
Related commands: ttl expiration pop.
Examples
# Enable MPLS IP TTL propagation for VPN packets.
<Sysname> system-view
[Sysname] mpls
[Sysname-mpls] ttl propagate vpn