< Home

tracert lsp

Function

The tracert lsp command detects the gateways along the LSP from the source to the destination.

Format

tracert lsp [ -a source-ip | -exp exp-value | -h ttl-value | -r reply-mode | -t time-out | -v ] * ip destination-address mask-length [ ip-address ] [ nexthop nexthop-address | draft6 ]

tracert lsp [ -a source-ip | -exp exp-value | -h ttl-value | -r reply-mode | -t time-out ] * te tunnel interface-number [ hot-standby | primary ] [ draft6 ]

tracert lsp [ -a source-ip | -exp exp-value | -h ttl-value | -r reply-mode | -t time-out ] * bgp destination-address mask-length [ ip-address ]

Parameters

Parameter Description Value

-a source-ip

Specifies the source IP address of Echo Request packets to be sent. If no source IP address is specified, the IP address of the outbound interface through which Echo Request packets are sent is used as a source IP address.

NOTE:

If an E2E BGP LSP has been established between two devices and the LSR ID is not used on the ingress, to run the tracert lsp command with bgp specified on the ingress, you must specify -a source-ip as the IP address used for establishing the E2E BGP LSP.

-

-exp exp-value

Specifies the EXP value of Echo Request packets to be sent.

The EXP value represents the priority of Echo Request packets.

NOTE:

If DSCP priority has been configured by running the set priority command, the exp-value parameter does not take effect.

An integer that ranges from 0 to 7. The default value is 0.

-h ttl-value

Specifies the TTL value of MPLS Echo Request packets to be sent.

The TTL field indicates the lifetime of the MPLS Echo Request packet and specifies the maximum number of hops that the packet can pass through. The TTL value is set on the source and reduced by 1 each time the packet passes through a hop. When the TTL value is reduced to 0, the packet is discarded. At the same time, an ICMP Timeout message is sent to notify the source host.

An integer that ranges from 1 to 255. The default value is 30.

-r reply-mode

Specifies the mode in which the peer returns MPLS Echo Reply packets.

An integer that ranges from 1 to 4. The default value is 2. The meaning of each value is as follows:
  • 1: No MPLS Echo Reply packet is returned.
  • 2: The MPLS Echo Reply packet is encapsulated into IPv4/IPv6 UDP packets.
  • 3: MPLS Echo Reply packets are encapsulated into IPv4/IPv6 UDP packets carrying the Router Alert option.
  • 4: MPLS Echo Reply packets are responded using the control channels on the application plane.

If the value of reply-mode is 1, the initiator starts a unidirectional test. If the test succeeds, the initiator prompts that the test times out; if the test fails, the initiator prompts that the LSP does not exist.

-t time-out

Specifies the period of time for waiting for an MPLS Echo Reply packet.

An integer that ranges from 0 to 65535, in milliseconds. The default value is 2000.

-v

Displays the MPLS label carried in the ICMP Time Exceeded packet.

This parameter is used when public network labels need to be displayed after tracert is initiated on the PE.

-

ip destination-address mask-length

Specifies the destination IPv4 address and the mask length.

The destination IPv4 address is in dotted decimal notation.

The mask length is an integer that ranges from 0 to 32.

ip-address

Specifies the destination IP address carried in the IP header of an MPLS Echo Request packet.

The value is in dotted decimal notation.

By default, the destination IP address carried in the IP header of an MPLS Echo Request packet is 127.0.0.1.

nexthop nexthop-address

Specifies the next-hop address.

The value is in dotted decimal notation.

draft6

Specifies the version of the tracert lsp command. If this parameter is specified, the tracert operation is performed according to "draft-ietf-mpls-lsp-ping-06". By default, the tracert operation is performed according to RFC 4379.

-

te tunnel interface-number

Specifies the number of the TE tunnel interface.

-

hot-standby

Indicates that the hot-standby CR-LSP is to be monitored.

-

primary

Indicates that the primary CR-LSP is to be monitored.

-

bgp destination-address mask-length

Specifies the destination IP address and mask length of BGP.

destination-address is in dotted decimal notation.

mask-length is an integer that ranges from 0 to 32.

Views

All views

Default Level

0: Visit level

Usage Guidelines

Usage Scenario

When a fault occurs on the LSPs of an MPLS network, you can run the ping lsp command to check the LSP connectivity based on the reply packet, and then run the tracert lsp command to locate the fault.

The tracert lsp command uses MPLS Echo Request messages and MPLS Echo Reply messages to monitor the connectivity of the LSP. Both MPLS Echo Request and MPLS Echo Reply messages are encapsulated into UDP packets and transmitted through port 3503. The receiver distinguishes MPLS Echo Request and MPLS Echo Reply messages based on the port number. An MPLS Echo Request message carries FEC information to be monitored, and is sent along the same LSP as other packets with the same FEC. In this manner, the connectivity of the LSP is checked. Echo Request messages are transmitted to the destination using MPLS, whereas MPLS Echo Reply messages are transmitted to the source using IP.

The LSP tracert can be used to monitor the following types of links:
  • LDP LSP Tracert: Run the tracert lsp ip destination-address mask-length command on the ingress node to trace the egress node to detect the fault on the LSP.

  • TE Tunnel Tracert: You can run the tracert lsp te tunnel interface-number command on the ingress node to trace the egress node to check the connectivity of a tunnel.
    • To check the connectivity of a hot-standby tunnel, run the tracert lsp te tunnel interface-number hot-standby command.
    • To check the connectivity of a primary tunnel, run the tracert lsp te tunnel interface-number primary command.

Prerequisites

  • The UDP module of each node is working properly; otherwise, the tracert operation fails.
  • The MPLS module of each node is enabled and is working properly.
  • The ICMP module of each node is working properly; otherwise, three asterisks (* * *) are displayed.

Procedure

The execution process of the tracert lsp command is as follows:
  • The source sends an MPLS Echo Request packet with the TTL being 1. After the TTL times out, the first hop sends an MPLS Echo Reply packet to the source.
  • The source sends an MPLS Echo Request packet with the TTL being 2. After the TTL times out, the second hop sends an MPLS Echo Reply packet to the source.
  • The source sends an MPLS Echo Request packet with the TTL being 3. After the TTL times out, the third hop sends an MPLS Echo Reply packet to the source.
  • The preceding process proceeds until the MPLS Echo Request packet reaches the destination.

When the device on the destination hop receives the MPLS Echo Request packet, it returns an MPLS Echo Reply packet, indicating the end of the tracert. The purpose behind this is to record the source of each ICMP Timeout packet to provide a trace of the path the packet took to reach the destination.

Precautions

When you run the tracert lsp te tunnel interface-number command to detect a tunnel, if a transit node is not enabled with LDP, a packet is returned, indicating that the destination is unreachable.

To prevent the egress node from forwarding the received MPLS Echo Request packet to other nodes, you can set the destination address in the IP header of the Echo Request packet to a loopback address with the prefix being 127.0.0.1/8.

Example

# Tracert the LSP to 10.4.4.9/32.
<HUAWEI> tracert lsp ip 10.4.4.9 32
  LSP Trace Route FEC: IPV4 PREFIX 10.4.4.9/32 , press CTRL_C to break.
  TTL   Replier            Time    Type      Downstream
  0                                Ingress   10.1.2.2/[1028 ]
  1     10.1.2.2           94 ms   Transit   10.4.4.9/[3 ]
  2     10.4.4.9           94 ms   Egress
# Tracert the LSP to 10.3.3.9/32 with the MTU value.
<HUAWEI> tracert lsp -v ip 10.3.3.9 32
  LSP Trace Route FEC: IPV4 PREFIX 10.3.3.9/32 , press CTRL_C to break.          
  TTL   Replier            Time    Type      Downstream/Label/MTU               
  0                                Ingress   172.16.1.1/[3 ]/1500                
  1     10.3.3.9          20 ms   Egress     
# Tracert a TE tunnel.
<HUAWEI> tracert lsp te tunnel 1
  LSP Trace Route FEC: TE TUNNEL IPV4 SESSION QUERY Tunnel1 , press CTRL_C to break.
  TTL   Replier            Time    Type      Downstream
  0                                Ingress   10.1.2.2/[13312 ]
  1     10.1.2.2           63 ms   Transit   10.4.4.9/[3 ]
  2     10.6.6.6           93 ms   Egress
Table 1 Description of the tracert lsp command output

Item

Description

TTL

Indicates the TTL value in an Echo Request packet. It represents the number of hops of the tunnel an Echo Request packet passes.

Replier

IP address of a switching node that returns an MPLS Echo Reply packet.

Time

RTT, in milliseconds.

Type

Type of a node. Available node types:
  • Ingress node
  • Transit node
  • Egress node

Downstream

Address of a downstream device.

Label

Label of a downstream device.

MTU

Link Maximum Transmission Unit.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >