08-MPLS Command Reference

HomeSupportSwitchesH3C S12500 Switch SeriesReference GuidesCommand ReferencesH3C S12500 Command References-Release7374-6W73108-MPLS Command Reference
10-MPLS OAM commands
Title Size Download
10-MPLS OAM commands 109.63 KB

MPLS OAM commands

bfd discriminator

Use bfd discriminator to set local and remote discriminators for the BFD session used to verify PW connectivity.

Use undo bfd discriminator to restore the default.

Syntax

bfd discriminator local local-id remote remote-id

undo bfd discriminator

Default

No local or remote discriminators are configured for the BFD session used to verify PW connectivity. The system automatically assigns local and remote discriminators to the BFD session.

Views

Cross-connect backup PW view

Cross-connect PW view

VSI LDP backup PW view

VSI LDP PW view

VSI static backup PW view

VSI static PW view

Predefined user roles

network-admin

mdc-admin

Parameters

local local-id: Specifies the local discriminator value for the BFD session, in the range of 1 to 1024.

remote remote-id: Specifies the remote discriminator value for the BFD session, in the range of 1 to 4294967295.

Usage guidelines

A BFD session for PW connectivity verification can be established in one of the following modes:

·     Static modeManually specify the local and remote discriminator values by using the bfd discriminator command. You must specify the discriminators on both the local and remote PEs. Make sure the local discriminator and remote discriminator on the local PE are the same as the remote discriminator and local discriminator on the remote PE. Otherwise, the BFD session cannot be established for the PW.

·     Dynamic mode—If you do not specify local and remote discriminators, the system automatically runs MPLS ping to negotiate the discriminator values.

Examples

# In VSI LDP PW view, set both the local and remote discriminator values to 1 for the BFD session used to verify PW connectivity.

<Sysname> system-view

[Sysname] vsi ttt

[Sysname-vsi-ttt] pwsignaling ldp 

[Sysname-vsi-ttt-ldp] peer 22.22.2.2 pw-id 1 pw-class ttt

[Sysname-vsi-ttt-ldp-22.22.2.2-1] bfd discriminator local 1 remote 1

Related commands

·     display l2vpn pw bfd

·     mpls bfd enable

·     vccv bfd

·     vccv cc

display l2vpn pw bfd

Use display l2vpn pw bfd to display BFD information for PWs.

Syntax

display l2vpn pw bfd [ peer peer-ip pw-id pw-id ]

Views

Any view

Predefined user roles

network-admin

network-operator

mdc-admin

mdc-operator

Parameters

peer peer-ip pw-id pw-id: Specifies a PW. The peer-ip argument specifies the LSR ID of the peer PE on the PW. The pw-id argument specifies the PW ID in the range of 1 to 4294967295. If you do not specify a PW, this command displays BFD information for all PWs.

Examples

# Display BFD information for all PWs.

<Sysname> display l2vpn pw bfd

 Total number of sessions: 1, 1 up, 0 down, 0 init

 

 FEC Type: PW FEC-128

 FEC Info:

   Peer IP: 22.22.2.2

   PW ID: 1

 VSI Index: 0                        Link ID: 8

 Local Discr: 514                    Remote Discr: 514

 Source IP: 11.11.1.1                Destination IP: 127.0.0.2

 Session State: Up                   Session Role: Active

 Template Name: -

Table 1 Command output

Field

Description

Peer IP

LSR ID of the peer PE of the PW.

VSI Index

Index of the VSI to which the PW belongs. This field is displayed when the PW is a VPLS PW.

Connection ID

ID of the cross-connect to which the PW belongs. This field is displayed when the PW is a VPWS PW.

Link ID

Link ID of the PW.

Local Discr

Local discriminator of the BFD session.

Remote Discr

Remote discriminator of the BFD session.

Source IP

Source IP of the BFD session, which is the MPLS LSR ID of the local PE.

Destination IP

Destination IP address of the BFD session, which is on subnet 127.0.0.0/8.

Session State

BFD session state:

·     Init—BFD session is in initialization state.

·     Up—BFD session is up.

·     Down—BFD session is down.

Session Role

Role of the local PE in the BFD session:

·     Active—Initiator of the BFD session.

·     Passive—Responder of the BFD session.

Template Name

Name of the BFD session parameter template.

 

Related commands

·     vccv bfd

·     vccv cc

mpls bfd enable

Use mpls bfd enable to enable BFD for MPLS.

Use undo mpls bfd enable to disable BFD for MPLS.

Syntax

mpls bfd enable

undo mpls bfd enable

Default

BFD for MPLS is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Examples

# Enable BFD for MPLS.

<Sysname> system-view

[Sysname] mpls bfd enable

mpls periodic-tracert (for LSP)

Use mpls periodic-tracert to enable periodic tracert of LSPs for an FEC.

Use undo mpls periodic-tracert to disable periodic tracert of LSPs for an FEC.

Syntax

mpls periodic-tracert dest-addr mask-length [ -a source-ip | -exp exp-value | -h ttl-value | -m wait-time | -rtos tos-value | -t time-out | -u retry-attempt | fec-check ] *

undo mpls periodic-tracert dest-addr mask-length

Default

Periodic tracert of LSPs for an FEC is disabled.

Views

System view

Predefined user roles

network-admin

mdc-admin

Parameters

dest-addr mask-length: Specifies an FEC by a destination address and the destination address mask length in the range of 0 to 32.

-a source-ip: Specifies the source address for MPLS echo request packets. If you do not specify this option, the device uses the MPLS LSR ID as the source address for MPLS echo requests.

-exp exp-value: Specifies the EXP value for MPLS echo request packets, in the range of 0 to 7. The default is 0.

-h ttl-value: Specifies the maximum TTL value for MPLS echo request packets (the maximum number of hops to be inspected). The value range for the ttl-value argument is 1 to 255, and the default is 30.

-m wait-time: Specifies the interval at which tracert is performed. The value range is 15 to 120 minutes. The default is 60 minutes.

-rtos tos-value: Specifies the ToS value in the IP header of an MPLS echo reply packet. The value range is 0 to 7, and the default value is 6.

-t time-out: Specifies the timeout interval for the reply to an MPLS echo request. The value range is 0 to 65535 milliseconds, and the default is 2000 milliseconds.

-u retry-attempt: Specifies the maximum number of retransmissions of an MPLS echo request if no reply is received. The value range is 1 to 9, and the default value is 3.

fec-check: Checks the FEC stack at transit nodes.

Usage guidelines

The periodic MPLS tracert function automatically traces an LSP tunnel at intervals. It locates errors on the LSP tunnel, verifies the consistency of the data plane and control plane, and records the detected errors into system logs. You can check the logs to monitor LSP connectivity.

If both BFD and periodic MPLS tracert are configured for an LSP and the periodic tracert function detects a data plane and control plane inconsistency, the device performs the following operations:

1.     Deletes the BFD session for the LSP.

2.     Re-establishes the BFD session based on the control plane.

Examples

# Enable periodic tracert for LSPs to destination 11.11.1.1/32.

<Sysname> system-view

[Sysname] mpls periodic-tracert 11.11.1.1 32

Related commands

mpls bfd (for LSP)

ping mpls ipv4

Use ping mpls ipv4 to verify MPLS LSP connectivity for an IPv4 prefix.

Syntax

ping mpls [ -a source-ip | -c count | -exp exp-value | -h ttl-value | -m wait-time | -r reply-mode | -rtos tos-value | -s packet-size | -t time-out | -v ] * ipv4 dest-addr mask-length [ destination start-address [ end-address [ address-increment ] ] ]

Views

Any view

Predefined user roles

network-admin

mdc-admin

Parameters

-a source-ip: Specifies the source address for MPLS echo request packets. If you do not specify this option, the device uses the primary IP address of the outgoing interface as the source address for MPLS echo requests.

-c count: Specifies the number of MPLS echo request packets to be sent with the same destination address in the IP header. The value range is 1 to 4294967295. The default is 5.

-exp exp-value: Specifies the EXP value for MPLS echo request packets, in the range of 0 to 7. The default is 0.

-h ttl-value: Specifies the TTL value for MPLS echo request packets, in the range of 1 to 255. The default is 255.

-m wait-time: Specifies the interval for sending MPLS echo request packets, in the range of 1 to 10000 milliseconds. The default is 200 milliseconds.

-r reply-mode: Specifies the reply mode of the receiver in response to MPLS echo request packets. The reply-mode argument can be 1, 2, or 3. 1 means "Do not reply," 2 means "Reply by using a UDP packet," and 3 means "Reply by using a UDP packet that carries the Router Alert option." The default is 2.

-rtos tos-value: Specifies the ToS value in the IP header of an MPLS echo reply packet. The value range is 0 to 7, and the default value is 6.

-s packet-size: Specifies the length (excluding the IP header and UDP header) of an MPLS echo request packet. The value for the packet-size argument is 65 to 8100 bytes, and the default is 100 bytes.

-t time-out: Specifies the timeout interval for the reply to an MPLS echo request. The value range is 0 to 65535 milliseconds, and the default is 2000 milliseconds.

-v: Displays detailed reply information. If you do not specify this keyword, the command displays brief reply information.

dest-addr mask-length: Specifies an FEC by an IPv4 destination address and a mask length. The value range for the mask-length argument is 0 to 32.

destination: Specifies the destination address in the IP header of MPLS echo requests. The default is 127.0.0.1.

start-address: Specifies the destination address or the start destination address. This address must be an address on subnet 127.0.0.0/8—a local loopback address. If you specify the start-address argument without the end-address argument, the start-address is the destination address in the IP header. The number of MPLS echo requests to be sent is determined by the -c count keyword. If you specify both the start-address argument and the end-address argument, you specify a range of destination addresses and the destination addresses increase in turn by the address-increment, starting from the start-address to the end-address. The number of MPLS echo requests to be sent with each of the destination addresses is determined by the -c count keyword.

end-address: Specifies the end destination address. This address must be an address on subnet 127.0.0.0/8—a local loopback address.

address-increment: Specifies the increment value by which the destination address in the IP header increases in turn. The value range is 1 to 16777215 and the default value is 1.

Examples

# Verify the connectivity of LSPs to destination 3.3.3.9/32.

<Sysname> ping mpls ipv4 3.3.3.9 32

MPLS ping FEC 3.3.3.9/32 with 100 bytes of data:

100 bytes from 100.1.2.1: Sequence=1 time=49 ms

100 bytes from 100.1.2.1: Sequence=2 time=44 ms

100 bytes from 100.1.2.1: Sequence=3 time=60 ms

100 bytes from 100.1.2.1: Sequence=4 time=60 ms

100 bytes from 100.1.2.1: Sequence=5 time=76 ms

 

--- Ping statistics for FEC 3.3.3.9/32 ---

5 packets transmitted, 5 packets received, 0.0% packet loss

Round-trip min/avg/max = 44/57/76 ms

# Verify the connectivity of LSPs to destination 3.3.3.9/32, and specify the following parameters:

·     Set the number of MPLS echo requests to be sent with the same destination address to 3.

·     Display detailed reply information.

·     Specify the range of destination addresses in IP headers as 127.0.0.1 to 127.0.0.3, and set the destination address increment value to 2. With this configuration, the destination addresses are 127.0.0.1 and 127.0.0.3.

<Sysname> ping mpls –c 3 –v ipv4 3.3.3.9 32 destination 127.0.0.1 127.0.0.3 2

MPLS ping FEC 3.3.3.9/32 with 100 bytes of data:

Destination address 127.0.0.1

100 bytes from 100.1.2.1: Sequence=1 time=49 ms Return Code=3(1)

 

Destination address 127.0.0.3

100 bytes from 100.1.2.1: Sequence=2 time=44 ms Return Code=3(1)

 

Destination address 127.0.0.1

100 bytes from 100.1.2.1: Sequence=3 time=60 ms Return Code=3(1)

 

Destination address 127.0.0.3

100 bytes from 100.1.2.1: Sequence=4 time=60 ms Return Code=3(1)

 

Destination address 127.0.0.1

100 bytes from 100.1.2.1: Sequence=5 time=76 ms Return Code=3(1)

 

Destination address 127.0.0.3

100 bytes from 100.1.2.1: Sequence=6 time=57 ms Return Code=3(1)

 

--- Ping statistics for FEC 3.3.3.9/32 ---

6 packets transmitted, 6 packets received, 0.0% packet loss

Round-trip min/avg/max = 44/57/76 ms

Table 2 Command output

Field

Description

MPLS Ping FEC: 3.3.3.9/32 : 100 data bytes

Verify LSP connectivity for FEC 3.3.3.9/32 by sending 100-byte MPLS echo requests.

Destination address

Destination IP address in the IP header.

100 bytes from 100.1.2.1

Received a 100-byte reply from 100.1.2.1.

Sequence

Sequence number of the reply, for determination of packet loss, disorder, or duplicate.

time

Packet round-trip delay.

Return Code

Return code. The number in parentheses represents a return subcode.

Ping statistics for FEC 3.3.3.9/32

LSP verification statistics.

packets transmitted

Number of MPLS echo requests sent.

packets received

Number of MPLS echo replies received.

packet loss

Percentage of unreplied packets to total request packets.

Round-trip min/avg/max

Minimum, average, and maximum round-trip delay.

 

ping mpls pw

Use ping mpls pw to verify LDP PW or static PW connectivity.

Syntax

ping mpls [ -a source-ip | -c count | -exp exp-value | -h ttl-value | -m wait-time | -r reply-mode | -rtos tos-value | -s packet-size | -t time-out | -v ] * pw ip-address pw-id pw-id

Views

Any view

Predefined user roles

network-admin

mdc-admin

Parameters

-a source-ip: Specifies the source address for MPLS echo request packets. If you do not specify this option, the device uses the primary IP address of the outgoing interface as the source address for MPLS echo requests.

-c count: Specifies the number of MPLS echo request packets to be sent. The value range is 1 to 4294967295. The default is 5.

-exp exp-value: Specifies the EXP value for MPLS echo request packets, in the range of 0 to 7. The default is 0.

-h ttl-value: Specifies the TTL value for MPLS echo request packets, in the range of 1 to 255. The default is 255.

-m wait-time: Specifies the interval for sending MPLS echo request packets, in the range of 1 to 10000 milliseconds. The default is 200 milliseconds.

-r reply-mode: Specifies the reply mode of the receiver in response to MPLS echo request packets. The reply-mode argument can be 1, 2, or 3. 1 means "Do not reply," 2 means "Reply by using a UDP packet," and 3 means "Reply by using a UDP packet that carries the Router Alert option." The default is 2.

-rtos tos-value: Specifies the ToS value in the IP header of an MPLS echo reply packet. The value range is 0 to 7, and the default value is 6.

-s packet-size: Specifies the length (excluding the IP header and UDP header) of an MPLS echo request packet. The value for the packet-size argument is 65 to 8100 bytes, and the default is 100 bytes.

-t time-out: Specifies the timeout interval for the reply to an MPLS echo request. The value range is 0 to 65535 milliseconds, and the default is 2000 milliseconds.

-v: Displays detailed reply information. If you do not specify this keyword, the command displays brief reply information.

ip-address: Specifies the IP address of the peer PE.

pw-id pw-id: Specifies the ID of the PW to the peer PE, in the range of 1 to 4294967295.

Examples

# Verify the connectivity of PW 301 to peer PE 3.3.3.9.

<Sysname> ping mpls pw 3.3.3.9 pw-id 301

MPLS ping PW 3.3.3.9 301 with 100 bytes of data:

100 bytes from 100.1.2.1: Sequence=1 time=49 ms

100 bytes from 100.1.2.1: Sequence=2 time=44 ms

100 bytes from 100.1.2.1: Sequence=3 time=60 ms

100 bytes from 100.1.2.1: Sequence=4 time=60 ms

100 bytes from 100.1.2.1: Sequence=5 time=76 ms

 

--- Ping statistics for PW 3.3.3.9 301 ---

5 packets transmitted, 5 packets received, 0.0% packet loss

Round-trip min/avg/max = 44/57/76 ms

For the command output, see Table 2.

tracert mpls ipv4

Use tracert mpls ipv4 to trace MPLS LSPs from the ingress node to the egress node for an IPv4 prefix. You can locate the error node according to the reply information.

Syntax

tracert mpls [ -a source-ip | -exp exp-value | -h ttl-value | -r reply-mode | -rtos tos-value | -t time-out | -v | fec-check ] * ipv4 dest-addr mask-length [ destination start-address [ end-address [ address-increment ] ] ]

Views

Any view

Predefined user roles

network-admin

mdc-admin

Parameters

-a source-ip: Specifies the source address for MPLS echo request packets. If you do not specify this option, the command uses the primary IP address of the outgoing interface as the source address for MPLS echo requests.

-exp exp-value: Specifies the EXP value for MPLS echo request packets, in the range of 0 to 7. The default is 0.

-h ttl-value: Specifies the maximum TTL value for MPLS echo request packets (the maximum number of hops to be inspected). The value range for the ttl-value argument is 1 to 255, and the default is 30.

-r reply-mode: Specifies the reply mode of the receiver in response to MPLS echo request packets. The reply-mode argument can be 1, 2, or 3. 1 means "Do not reply," 2 means "Reply by using a UDP packet," and 3 means "reply by using a UDP packet that carries the Router Alert option." The default is 2.

-rtos tos-value: Specifies the ToS value in the IP header of an MPLS echo reply packet. The value range is 0 to 7, and the default value is 6.

-t time-out: Specifies the timeout interval for the reply to an MPLS echo request. The value range is 0 to 65535 milliseconds, and the default is 2000 milliseconds.

-v: Displays detailed reply information. If you do not specify this keyword, the command displays brief reply information.

fec-check: Checks the FEC stack at transit nodes.

dest-addr mask-length: Specifies an FEC by an IPv4 destination address and a mask length. The value range for the mask-length argument is 0 to 32.

destination: Specifies the destination address in the IP header of MPLS echo requests. The default is 127.0.0.1.

start-address: Specifies the destination address or the start destination address. This address must be an address on subnet 127.0.0.0/8—a local loopback address. If you specify the start-address argument without the end-address argument, the start-address is the destination address in the IP header. If you specify both the start-address argument and the end-address argument, you specify a range of destination addresses and the destination addresses increase in turn by the address-increment, starting from the start-address to the end-address. The command performs a tracert for each of the destination addresses.

end-address: Specifies the end destination address. This address must be an address on subnet 127.0.0.0/8—a local loopback address.

address-increment: Specifies the increment value by which the destination address in the IP header increases in turn. The value range is 1 to 16777215 and the default value is 1.

Examples

# Trace the path that the LSP (for FEC 5.5.5.9/32) traverses from the ingress node to the egress node. Specify the IP header destination address range as 127.1.1.1 to 127.1.1.2 and set the address increment value to 1. With the configurations, the device performs a tracert for 127.1.1.1 and 127.1.1.2.

<Sysname> tracert mpls ipv4 5.5.5.9 32 destination 127.1.1.1 127.1.1.2 1

MPLS trace route FEC 5.5.5.9/32

  Destination address 127.1.1.1

  TTL   Replier            Time    Type      Downstream

  0                                Ingress   100.1.2.1/[1025]

  1     100.1.2.1          1 ms    Transit   100.2.4.1/[1024]

  2     100.2.4.1          63 ms   Transit   100.4.5.1/[3]

  3     100.4.5.1          129 ms  Egress

 

  Destination address 127.1.1.2

  TTL   Replier            Time    Type      Downstream

  0                                Ingress   100.1.3.1/[1030]

  1     100.1.3.1          1 ms    Transit   100.3.4.1/[1024]

  2     100.3.4.1          51 ms   Transit   100.4.5.1/[3]

  3     100.4.5.1          80 ms   Egress

# Trace the path that the LSP (for FEC 5.5.5.9/32) traverses from the ingress node to the egress node. Display detailed reply information, specify the IP header destination address range as 127.1.1.1 to 127.1.1.2, and set the address increment value to 1. With the configurations, the device performs a tracert for 127.1.1.1 and 127.1.1.2.

<Sysname> tracert mpls –v ipv4 5.5.5.9 32 destination 127.1.1.1 127.1.1.2 1

MPLS trace route FEC 5.5.5.9/32

  Destination address 127.1.1.1

  TTL   Replier            Time    Type      Downstream

  0                                Ingress   100.1.2.1/[1025]

  1     100.1.2.1          1 ms    Transit   100.2.4.1/[1024] ReturnCode 8(1)

  2     100.2.4.1          63 ms   Transit   100.4.5.1/[3] ReturnCode 8(1)

  3     100.4.5.1          129 ms  Egress    ReturnCode 3(1)

 

  Destination address 127.1.1.2

  TTL   Replier            Time    Type      Downstream

  0                                Ingress   100.1.3.1/[1030]

  1     100.1.3.1          1 ms    Transit   100.3.4.1/[1024] ReturnCode 8(1)

  2     100.3.4.1          51 ms   Transit   100.4.5.1/[3] ReturnCode 8(1)

  3     100.4.5.1          80 ms   Egress    ReturnCode 3(1)

Table 3 Command output

Field

Description

MPLS trace route FEC

Trace the LSPs for the specified FEC.

Destination address

Destination IP address in the IP header.

TTL

Number of hops.

Replier

Address of the LSR that replied the request.

Time

Time used to receive the reply, in milliseconds.

Type

LSR type: Ingress, Transit, or Egress.

Downstream

Address of the downstream LSR and the label assigned by the downstream LSR.

ReturnCode

Return code. The number in parentheses represents a return subcode.

 

vccv bfd

Use vccv bfd to configure BFD to verify PW connectivity.

Use undo vccv bfd to disable BFD for PWs.

Syntax

vccv bfd [ template template-name ]

undo vccv bfd

Default

BFD is not used to verify PW connectivity.

Views

PW class view

Predefined user roles

network-admin

mdc-admin

Parameters

template template-name: Specifies a BFD session parameter template by its name, a case-sensitive string of 1 to 31 characters. If you do not specify a template, BFD uses the multihop BFD session parameters configured in system view. This option is not supported in the current software version.

Usage guidelines

After you execute this command and specify the PW class for a PW, the PEs use the specified encapsulation type to verify PW connectivity when the following conditions are met:

·     Both PEs of the PW have configured BFD for the PW.

·     The PEs use the same encapsulation type for BFD packets.

Otherwise, the PEs do not use BFD to verify PW connectivity.

To use BFD for PW connectivity verification, you must execute the vccv bfd and mpls bfd enable commands on both ends of the PW.

Examples

# Configure BFD to verify PW connectivity.

<Sysname> system-view

[Sysname] pw-class test

[Sysname-pw-test] vccv bfd

Related commands

·     display l2vpn pw bfd

·     mpls bfd enable

·     vccv cc

vccv cc

Use vccv cc to specify the VCCV control channel (CC) type.

Use undo vccv cc to restore the default.

Syntax

vccv cc router-alert

undo vccv cc

Default

No VCCV CC type is specified.

Views

PW class view

Predefined user roles

network-admin

mdc-admin

Parameters

router-alert: Specifies the VCCV CC type as MPLS Router Alert Label.

Usage guidelines

The packets used to verify PW connectivity are collectively referred to as VCCV packets. A PE transfers VCCV packets through a control channel (CC).

The router-alert type identifies a VCCV packet by adding an MPLS router alert label before the PW label.

After you execute this command and specify the PW class for a PW, the specified CC is used if both PEs have specified the same VCCV CC type. Otherwise, the PEs do not use any CC and they cannot establish a BFD session for the PW.

Examples

# Specify the VCCV CC type as MPLS Router Alert Label.

<Sysname> system-view

[Sysname] pw-class test

[Sysname-pw-test] vccv cc router-alert

Related commands

·     display l2vpn pw bfd

·     mpls bfd enable

·     vccv bfd

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网