Table Of Contents
MPLS OAM Commands on Cisco IOS XR Software
MPLS OAM Commands on Cisco IOS XR Software
This chapter describes Multiprotocol Label Switching (MPLS) label switched path (LSP) verification commands. These commands provide a means to detect and diagnose data plane failures and are the first set of commands in the MPLS Operations, Administration, and Maintenance (OAM) solution.
For detailed information about MPLS concepts, configuration tasks, and examples, refer to the
Cisco IOS XR MPLS Configuration Guide.clear mpls oam counters
To clear MPLS OAM counters, use the clear mpls oam counters command in EXEC mode.
clear mpls oam counters {global | interface [interface-id | all] | packet}
Syntax Description
global
Clears global counters.
interface interface-id
Clears counters on a specified interface.
packet
Clears global packet counters.
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to clear all global MPLS OAM counters:
RP/0/RP0/CPU0:router# clear mpls oam counters globalclear mpls oam echo
To clear MPLS OAM echo requests, use the clear mpls oam echo command in EXEC mode.
clear mpls oam echo {disable-vendor-extension | revision {1 | 2 | 3 | 4}}
Syntax Description
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to disable sending TLV vendor extensions with echo requests:
RP/0/RP0/CPU0:router# clear mpls oam echo disable-vendor-extensionecho disable-vendor-extension
To disable sending the vendor extension type length and value (TLV) in the echo request, use the echo disable-vendor extension command in MPLS OAM configuration submode. To return to the default behavior, use the no form of this command.
echo disable-vendor-extension
no echo disable-vendor-extension
Syntax Description
This command has no arguments or keywords.
Defaults
By default, the vendor extension TLV is sent in each request. The default value is 4.
Command Modes
MPLS OAM configuration submode
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to disable inclusion of the vendor extensions TLV in the echo requests:
RP/0/RP0/CPU0:router# configureRP/0/RP0/CPU0:router(config)# mpls oamRP/0/RP0/CPU0:router(config-oam)# echo disable-vendor-extensionecho revision
To set the echo packet revision, use the echo revision command in MPLS OAM configuration submode. To return to the default behavior, use the no form of this command.
echo revision {1 | 2 | 3 | 4}
no echo revision
Syntax Description
Defaults
The default echo revision is 4 (in draft 9).
Command Modes
MPLS OAM configuration submode
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to set the echo packet default revision:
RP/0/RP0/CPU0:router# configureRP/0/RP0/CPU0:router(config)# mpls oamRP/0/RP0/CPU0:router(config-oam)# echo revision 1mpls oam
To enable MPLS OAM LSP verification, use the mpls oam command in global configuration mode. To return to the default behavior, use the no form of this command.
mpls oam
no mpls oam
Syntax Description
This command has no arguments or keywords.
Defaults
By default, MPLS OAM functionality is disabled.
Command Modes
Global configuration
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The mpls oam command and OAM functionality is described in the IETF LSP ping draft.
Task ID
Examples
The following example shows how to enable MPLS OAM:
RP/0/RP0/CPU0:router# configureRP/0/RP0/CPU0:router(config)# mpls oamRP/0/RP0/CPU0:router(config-oam)#ping mpls ipv4
To check MPLS host reachability and network connectivity by specifying the destination type as a Label Distribution Protocol (LDP) IPv4 address, use the ping mpls ipv4 command in EXEC mode.
ping mpls {ipv4 addr/mask} [destination {start address} {end address} {address increment}] | [dsmap] | [exp exp bits in MPLS header] | [force-explicit-null] | [interval send interval between requests in msec] | [output interface echo request output interface] [pad pad TLV pattern] | [repeat repeat count] | [reply dscp differentiated services codepoint value] | [reply mode [ipv4 | router-alert | no-reply] | [reply pad-tlv]] | [revision echo packet tlv versioning] | [{size packet size} | [source source specified as an IP address] | {sweep {min value} {max value} {increment}] | [timeout timeout in seconds] | [ttl time to live] | [verbose]
Syntax Description
Defaults
exp exp bits in MPLS header: 0
interval send interval between requests in msec: 0
repeat repeat count: 5
reply-mode: ipv4
timeout timeout in seconds: 2 seconds
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The output interface keyword specifies the output interface on which the MPLS echo request packets are sent. If the specified output interface is not part of the LSP, the packets are not transmitted.
In cases where the sweep keyword is used, values larger than the outgoing interface's MTU are not transmitted.
The ping command sends an echo request packet to an address, and then awaits a reply. Ping output can help you evaluate path-to-host reliability, delays over the path, and whether the host can be reached or is functioning.
![]()
Note
The ping mpls command is not supported on optical LSPs. If an optical LSP is encountered along the LSP's path, it is treated as a physical interface.
For detailed configuration information about the MPLS ping command, see the section entitled "Configuring IP SLA MPLS LSP Ping and Trace Operations" in Implementing IP Service Level Agreements on Cisco IOS XR Software.
Task ID
Examples
The following example shows the destination type as a Label Distribution Protocol (LDP) prefix and specifies a range of sizes for the echo packets sent:
RP/0/RP0/CPU0:router# ping mpls ipv4 140.140.140.140/32 verbose sweep 100 200 15 repeat 1Sending 1, [100..200]-byte MPLS Echos to 140.140.140.140/32,timeout is 2 seconds, send interval is 0 msec:Codes: '!' - success, 'Q' - request not sent, '.' - timeout,'L' - labeled output interface, 'B' - unlabeled output interface,'D' - DS Map mismatch, 'F' - no FEC mapping, 'f' - FEC mismatch,'M' - malformed request, 'm' - unsupported tlvs, 'N' - no rx label,'P' - no rx intf label prot, 'p' - premature termination of LSP,'R' - transit router, 'I' - unknown upstream index,'X' - unknown return code, 'x' - return code 0Type escape sequence to abort.! size 100, reply addr 196.100.1.26, return code 3! size 115, reply addr 196.100.1.26, return code 3! size 130, reply addr 196.100.1.26, return code 3! size 145, reply addr 196.100.1.26, return code 3! size 160, reply addr 196.100.1.26, return code 3! size 175, reply addr 196.100.1.26, return code 3! size 190, reply addr 196.100.1.26, return code 3Success rate is 100 percent (7/7), round-trip min/avg/max = 5/6/8 msping mpls pseudowire
To verify connectivity between provider edge (PE) LSRs in an Any Transport over MPLS (AToM) setup, use the ping mpls pseudowire command in EXEC mode.
ping mpls pseudowire {remote-PE address} {pw-id} [exp exp bits in MPLS header] | [interval send interval between requests in msec] [pad pad TLV pattern] | [repeat repeat count] | [reply dscp differentiated services codepoint value] | [reply mode {ipv4 | router-alert | no-reply | control-channel}] | [reply pad-tlv] | [revision echo packet tlv versioning] | [{size packet size} | [source source specified as an IP address] | {sweep {min value} {max value} {increment}] | [timeout timeout in seconds] | [ttl time to live] | [verbose]
Syntax Description
Defaults
exp exp bits in MPLS header: 0
interval send interval between requests in msec: 0
repeat repeat count: 5
reply-mode: ipv4
timeout timeout in seconds: 2 seconds
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
In cases in which the sweep keyword is used, values larger than the outgoing interface's MTU are not transmitted.
The ping command sends an echo request packet to an address, and then awaits a reply. Ping output can help you evaluate path-to-host reliability, delays over the path, and whether the host can be reached or is functioning.
![]()
Note
The ping mpls command is not supported on optical LSPs. If an optical LSP is encountered along the LSP's path, it is treated as a physical interface.
AToM VCCV allows the sending of control packets inband of an AToM pseudowire (PW) from the originating provider edge (PE) router. The transmission is intercepted at the destination PE router, instead of being forwarded to the customer edge (CE) router. This lets you use MPLS LSP ping to test the pseudowire section of AToM virtual circuits (VCs).
The no interactive version of the ping mpls pseudowire command is supported.
Task ID
Examples
The following example shows how the ping mpls pseudowire command is used to verify PE to PE connectivity in which the remote PE address is 150.150.150.150. Only one echo request packet is sent and the remote PE is to answer using IPv4 instead of the control channel.
RP/0/RP0/CPU0:router# ping mpls pseudowire 150.150.150.150 21 repeat 1 reply mode ipv4Sending 1, 100-byte MPLS Echos to 150.150.150.150 VC: 21,timeout is 2 seconds, send interval is 0 msec:Codes: '!' - success, 'Q' - request not sent, '.' - timeout,'L' - labeled output interface, 'B' - unlabeled output interface,'D' - DS Map mismatch, 'F' - no FEC mapping, 'f' - FEC mismatch,'M' - malformed request, 'm' - unsupported tlvs, 'N' - no rx label,'P' - no rx intf label prot, 'p' - premature termination of LSP,'R' - transit router, 'I' - unknown upstream index,'X' - unknown return code, 'x' - return code 0Type escape sequence to abort.!Success rate is 100 percent (1/1), round-trip min/avg/max = 23/23/23 msping mpls traffic-eng
To specify the destination type as an MPLS-TE tunnel and tunnel interface, use the ping mpls traffic-eng command in EXEC mode.
ping mpls {tunnel intf num} [dsmap] | [exp exp bits in MPLS header] | [force-explicit-null] | [interval send interval between requests in msec] | [pad pad TLV pattern] | [repeat repeat count] | [reply dscp differentiated services codepoint value] | [reply mode [ipv4 | router-alert | no-reply] | [reply pad-tlv] | [revision echo packet tlv versioning] | [{size packet size} | [source source specified as an IP address] | {sweep {min value} {max value} {increment}] | [timeout timeout in seconds] | [ttl time to live] | [verbose]
Syntax Description
Defaults
exp exp bits in MPLS header: 0
interval send interval between requests in msec: 0
repeat repeat count: 5
reply-mode: ipv4
timeout timeout in seconds: 2 seconds
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The output interface keyword specifies the output interface on which the MPLS echo request packets are sent. If the specified output interface is not part of the LSP, the packets are not transmitted.
In cases where the sweep keyword is used, values larger than the outgoing interface's MTU are not transmitted.
The ping command sends an echo request packet to an address, and then awaits a reply. Ping output can help you evaluate path-to-host reliability, delays over the path, and whether the host can be reached or is functioning.
![]()
Note
The ping mpls command is not supported on optical LSPs. If an optical LSP is encountered along the LSP's path, it is treated as a physical interface.
Task ID
Examples
The following example shows how to check connectivity by using the ping mpls traffic-eng command when a TE tunnel 10 is present. Return code, reply address, and packet size are displayed due to the verbose keyword.
RP/0/RP0/CPU0:router# ping mpls traffic-eng tunnel 10 repeat 1 verboseSending 1, 100-byte MPLS Echos to tunnel-te10,timeout is 2 seconds, send interval is 0 msec:Codes: '!' - success, 'Q' - request not sent, '.' - timeout,'L' - labeled output interface, 'B' - unlabeled output interface,'D' - DS Map mismatch, 'F' - no FEC mapping, 'f' - FEC mismatch,'M' - malformed request, 'm' - unsupported tlvs, 'N' - no rx label,'P' - no rx intf label prot, 'p' - premature termination of LSP,'R' - transit router, 'X' - unknown return code, 'x' - return code 0Type escape sequence to abort.! size 100, reply addr 196.100.1.18, return code 3Success rate is 100 percent (1/1), round-trip min/avg/max = 15/15/15 msshow mpls oam
To display MPLS OAM information, use the show mpls oam command in EXEC mode.
show mpls oam {client | counters {global | packet} | interface interface-id}
Syntax Description
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Release ModificationRelease 3.5.0
This command was introduced on the Cisco CRS-1 and Cisco XR 12000 Series Router.
Release 3.6.0
No modification.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to display MPLS OAM client information:
RP/0/RP0/CPU0:router# show mpls oam clientClient Process: l2vpn_mgr Node: 0/0/SP Pid: 418014Client Process: te_control Node: 0/0/SP Pid: 639227Table 85 describes the significant fields shown in the display.
Table 85 show mpls oam client Field Descriptions
Field DescriptionClient Process
Displays the client process.
show mpls oam database
To display MPLS OAM database information, use the show mpls oam database command in EXEC mode.
show mpls oam database {replies | requests | tt-requests} {detail | handle}
Syntax Description
replies
Displays replies database.
requests
Displays request database
tt-requests
Displays tree trace request database
detail
Displays displayed information.
handle
Displays handle information.
Defaults
No default behavior or values
Command Modes
EXEC
Command History
Release ModificationRelease 3.5.0
This command was introduced on the Cisco CRS-1 and Cisco XR 12000 Series Router.
Release 3.6.0
No modification.
Release 3.7.0
No modification.
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
Task ID
Examples
The following example shows how to display detailed MPLS OAM database information:
RP/0/RP0/CPU0:router# show mpls oam database request detailtraceroute mpls
To learn the routes that packets follow when travelling to their destinations., use the traceroute mpls command in EXEC mode.
traceroute mpls {{ipv4 addr/mask} | {traffic-eng tunnel tunnel intf num}} [destination {start address} {end address} {address increment}] | [exp exp bits in MPLS header] | [flags fec] | [force-explicit-null] | [output interface echo request output interface] | [reply dscp DSCP bits in reply IP header] | [reply mode [ipv4 | router-alert | no-reply]] [revision echo packet tlv versioning] | [source source specified as an IP address] | [timeout timeout in seconds] | [ttl time to live] | [verbose]
Syntax Description
Defaults
exp exp bits in MPLS header: 0
interval send interval between requests in msec: 0
reply-mode: ipv4
timeout timeout in seconds: 2 seconds
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
![]()
Note
The mpls traceroute command is not supported on optical LSPs. If an optical LSP is encountered along the LSP's path, it is treated as a physical interface.
For detailed configuration information about MPLS LSP trace operations, see the section entitled "Configuring and Scheduling an MPLS LSP Trace Operation" in Implementing IP Service Level Agreements on Cisco IOS XR Software.
Task ID
Examples
The following example shows how to trace a destination:
RP/0/RP0/CPU0:router# tracerouteProtocol [ipv4]: mplsTarget IPv4 or traffic-eng [ipv4]:Target IPv4 address: 140.140.140.140Target mask: 255.255.255.255Timeout in seconds [2]:Extended commands? [no]: yesDestination address or destination start address: 127.0.0.10Destination end address: 127.0.0.15Destination address increment: 1Source address:EXP bits in mpls header [0]:Maximum Time To Live [30]:Reply mode (2-ipv4 via udp, 3-ipv4 via udp with router alert) [2]:LSP ping/trace revision (1-draft 3 initial, 2-draft 3 rev 1, 3-draft 3 rev 2, 4-draft 9 initial) [4]:Force explicit null label? [no]:Reply IP header DSCP bits [0]:Check the FEC stack at transit routers? [no]:Tracing MPLS Label Switched Path to 140.140.140.140/32, timeout is 2 secondsCodes: '!' - success, 'Q' - request not sent, '.' - timeout,'L' - labeled output interface, 'B' - unlabeled output interface,'D' - DS Map mismatch, 'F' - no FEC mapping, 'f' - FEC mismatch,'M' - malformed request, 'm' - unsupported tlvs, 'N' - no rx label,'P' - no rx intf label prot, 'p' - premature termination of LSP,'R' - transit router, 'I' - unknown upstream index,'X' - unknown return code, 'x' - return code 0Type escape sequence to abort.Destination address 127.0.0.100 196.100.1.41 MRU 4470 [Labels: 19 Exp: 0]L 1 196.100.1.42 MRU 4470 [Labels: 86 Exp: 0] 360 msL 2 196.100.1.50 MRU 4470 [Labels: implicit-null Exp: 0] 8 ms! 3 196.100.1.18 9 mstraceroute mpls multipath
To discover all possible paths of an LSP between the ingress and egress routers, use the trace mpls multipath command in EXEC mode.
traceroute mpls multipath {{ipv4 addr/mask} | {traffic-eng tunnel tunnel intf num}} [destination {start address} {end address} {address increment}] | [exp exp bits in MPLS header] | [flags fec] | [force-explicit-null] | [hashkey ipv4 bitmap multipath bit size] | [interval send interval between requests in msec] | [output interface echo request output interface] | [reply dscp DSCP bits in reply IP header] | [reply mode [ipv4 | router-alert | no-reply]] | [retry-count echo request retry count] | [revision echo packet TLV versioning] | [source source specified as an IP address] | [timeout timeout in seconds] | [ttl time to live] | [verbose]
Syntax Description
Defaults
exp exp bits in MPLS header: 0
hashkey ipv4 bitmap multipath bit size: 4
interval send interval between requests in msec: 0
reply-mode: ipv4
retry-count: 3
timeout timeout in seconds: 2 seconds
Command Modes
EXEC
Command History
Usage Guidelines
To use this command, you must be in a user group associated with a task group that includes the proper task IDs. For detailed information about user groups and task IDs, see the Configuring AAA Services on Cisco IOS XR Software module of the Cisco IOS XR System Security Configuration Guide.
The hashkey ipv4 bitmap multipath bit size value controls how many addresses are encoded in the DSMAP multipath field. Larger values allow more coverage of equal cost multiple paths throughout the network, but with more processing at the head, mid, and tail routers.
Task ID
Examples
The following example shows how to specify the destination type as an LDP IPv4 prefix:
RP/0/RP0/CPU0:router# traceroute mpls multi ipv4 140.140.140.140/32 verbose force-explicit-nullStarting LSP Path Discovery for 140.140.140.140/32Codes: '!' - success, 'Q' - request not sent, '.' - timeout,'L' - labeled output interface, 'B' - unlabeled output interface,'D' - DS Map mismatch, 'F' - no FEC mapping, 'f' - FEC mismatch,'M' - malformed request, 'm' - unsupported tlvs, 'N' - no rx label,'P' - no rx intf label prot, 'p' - premature termination of LSP,'R' - transit router, 'I' - unknown upstream index,'X' - unknown return code, 'x' - return code 0Type escape sequence to abort.LL!Path 0 found,output interface POS0/2/0/3 source 196.100.1.61 destination 127.0.0.10 196.100.1.61 196.100.1.62 MRU 4470 [Labels: 18/explicit-null Exp: 0/0] multipaths 0L 1 196.100.1.62 196.100.1.10 MRU 4470 [Labels: 17/explicit-null Exp: 0/0] ret code 8 multipaths 1L 2 196.100.1.10 196.100.1.18 MRU 4470 [Labels: implicit-null/explicit-null Exp: 0/0] ret code 8 multipaths 1! 3 196.100.1.18, ret code 3 multipaths 0LL!Path 1 found,output interface GigabitEthernet0/3/0/0 source 196.100.1.5 destination 127.0.0.10 196.100.1.5 196.100.1.6 MRU 1500 [Labels: 18/explicit-null Exp: 0/0] multipaths 0L 1 196.100.1.6 196.100.1.10 MRU 4470 [Labels: 17/explicit-null Exp: 0/0] ret code 8 multipaths 1L 2 196.100.1.10 196.100.1.18 MRU 4470 [Labels: implicit-null/explicit-null Exp: 0/0] ret code 8 multipaths 1! 3 196.100.1.18, ret code 3 multipaths 0Paths (found/broken/unexplored) (2/0/0)Echo Request (sent/fail) (6/0)Echo Reply (received/timeout) (6/0)Total Time Elapsed 80 ms