The following operations apply to lsp-ping and lsp-trace commands on SR-TE LSPs:
The sender node builds a target FEC stack TLV that contains FEC elements.
For lsp-ping, the target FEC stack TLV contains a single FEC element that corresponds to the last segment, that is, a node SID or an adjacency SID of the destination of the SR-TE LSP.
For lsp-trace, the target FEC stack TLV contains a FEC element for each node SID and for each adjacency SID in the path of the SR-TE LSP, including the SID of the destination of the SR-TE LSP.
A node SID label that is popped at an LSR results in a return code of 3, ‟Replying router is an egress for the FEC at stack-depth <RSC>”.
An adjacency SID label that is popped at an LSR results in a return code of 3, ‟Replying router is an egress for the FEC at stack-depth <RSC>”.
A node SID label that is swapped at an LSR results in a return code of 8, ‟Label switched at stack-depth <RSC>”, per RFC 8029.
An adjacency SID label that is swapped at an LSR results in a return code of 8, ‟Label switched at stack-depth <RSC>”, per RFC 8029.
The lsp-trace command includes the option to specify the downstream mapping TLV format to use in the LSP trace packet: ddmap, dsmap, or none. When none is configured, no map TLV is sent. The downstream interface information is returned along with the egress label for the node SID tunnel or the adjacency SID tunnel of the current segment as well as the protocol that resolved the tunnel at the responder node.
If the target FEC stack TLV contains more than one FEC element, the responder node that is the termination of one node SID or adjacency SID segment pops its own SID in the first operation. When the sender node receives this reply, it adjusts the target FEC stack TLV by stripping the top FEC before sending the probe for the next TTL value. When the responder node receives the next echo request message with the same TTL value from the sender node for the next node SID or adjacency SID segment in the stack, it performs a swap operation to that next segment.
When the path of the SR-TE LSP is computed by the sender node, the hop-to-label translation tool returns the IGP instance that was used to determine the labels for each hop in the path. When the path of the SR-TE LSP is computed by a PCE, the protocol ID is not returned by the PCEP. In this case, the sender node performs a lookup in the SR module for the IGP instance that resolved the first segment of the path. In both cases, the IGP is used to encode the protocol ID field of the node SID or adjacency SID in each of the FEC elements of the target FEC stack TLV.
The responder node validates the top FEC in the target FEC stack TLV, provided that the depth of the incoming label stack in the packet header is greater than the depth of the target FEC stack TLV.
TTL values can be changed.
The ttl parameter in the lsp-ping command can be set to a value lower than 255 and the responder node replies if the FEC element in the target FEC stack TLV corresponds to a node SID resolved at that node. The responder node, however, fails the validation if the FEC element in the target FEC stack TLV is the adjacency of a remote node. The return code in the echo reply message is either ‟rc=4(NoFECMapping)” or ‟rc=10(DSRtrUnmatchLabel)”.
The min-ttl and max-ttl parameters in the lsp-trace command can be set to values other than the default. However, lsp-trace can only properly trace the partial path of an SR-TE LSP if there is no segment termination before the node that corresponds to the minimum TTL value. Otherwise, it fails validation and returns an error because the responder node receives a target FEC stack depth that is greater than the incoming label stack size. The return code in the echo reply message is ‟rc=4(NoFECMapping)”, ‟rc=5(DSMappingMismatched)”, or ‟rc=10(DSRtrUnmatchLabel)”.
This scenario is true whether the downstream-map-tlv option is set to ddmap, dsmap, or none.
The following are output examples for LSP ping and LSP trace on SR-TE LSPs. The first example uses a path with strict hops, each corresponding to an adjacency SID, while the second example uses a path with loose hops, each corresponding to a node SID. The topology for the examples is shown in Figure: Testing MPLS OAM with SR-TE LSPs.
Example 1
The following output is an example of LSP ping and LSP trace on DUT-A for a strict-hop adjacency SID SR-TE LSP, where:
the source is DUT-A
the destination is DUT-F
the path is as follows: A to B, B to C, C to E, E to D, D to F
*A:Dut-A# oam lsp-ping sr-te "srteABCEDF" detail
LSP-PING srteABCEDF: 96 bytes MPLS payload
Seq=1, send from intf int_to_B, reply from 10.20.1.6
udp-data-len=32 ttl=255 rtt=1220325ms rc=3 (EgressRtr)
---- LSP srteABCEDF PING Statistics ----
1 packets sent, 1 packets received, 0.00% packet loss
round-trip min = 1220325ms, avg = 1220325ms, max = 1220325ms, stddev = 0.000ms
*A:Dut-A# oam lsp-trace sr-te "srteABCEDF" downstream-map-tlv ddmap detail
lsp-trace to srteABCEDF: 0 hops min, 0 hops max, 252 byte packets
1 10.20.1.2 rtt=1220323ms rc=3(EgressRtr) rsc=5
1 10.20.1.2 rtt=1220322ms rc=8(DSRtrMatchLabel) rsc=4
DS 1: ipaddr=10.10.33.3 ifaddr=10.10.33.3 iftype=ipv4Numbered MRU=1520
label[1]=3 protocol=6(ISIS)
label[2]=262135 protocol=6(ISIS)
label[3]=262134 protocol=6(ISIS)
label[4]=262137 protocol=6(ISIS)
2 10.20.1.3 rtt=1220323ms rc=3(EgressRtr) rsc=4
2 10.20.1.3 rtt=1220323ms rc=8(DSRtrMatchLabel) rsc=3
DS 1: ipaddr=10.10.5.5 ifaddr=10.10.5.5 iftype=ipv4Numbered MRU=1496
label[1]=3 protocol=6(ISIS)
label[2]=262134 protocol=6(ISIS)
label[3]=262137 protocol=6(ISIS)
3 10.20.1.5 rtt=1220325ms rc=3(EgressRtr) rsc=3
3 10.20.1.5 rtt=1220325ms rc=8(DSRtrMatchLabel) rsc=2
DS 1: ipaddr=10.10.11.4 ifaddr=10.10.11.4 iftype=ipv4Numbered MRU=1496
label[1]=3 protocol=6(ISIS)
label[2]=262137 protocol=6(ISIS)
4 10.20.1.4 rtt=1220324ms rc=3(EgressRtr) rsc=2
4 10.20.1.4 rtt=1220325ms rc=8(DSRtrMatchLabel) rsc=1
DS 1: ipaddr=10.10.9.6 ifaddr=10.10.9.6 iftype=ipv4Numbered MRU=1496
label[1]=3 protocol=6(ISIS)
5 10.20.1.6 rtt=1220325ms rc=3(EgressRtr) rsc=1
Example 2
The following output is an example of LSP ping and LSP trace on DUT-A for a loose-hop node SID SR-TE LSP, where:
the source is DUT-A
the destination is DUT-F
the path is A, B, C, E
*A:Dut-A# oam lsp-ping sr-te "srteABCE_loose" detail
LSP-PING srteABCE_loose: 80 bytes MPLS payload
Seq=1, send from intf int_to_B, reply from 10.20.1.5
udp-data-len=32 ttl=255 rtt=1220324ms rc=3 (EgressRtr)
---- LSP srteABCE_loose PING Statistics ----
1 packets sent, 1 packets received, 0.00% packet loss
round-trip min = 1220324ms, avg = 1220324ms, max = 1220324ms, stddev = 0.000ms
*A:Dut-A# oam lsp-trace sr-te "srteABCE_loose" downstream-map-tlv ddmap detail
lsp-trace to srteABCE_loose: 0 hops min, 0 hops max, 140 byte packets
1 10.20.1.2 rtt=1220323ms rc=3(EgressRtr) rsc=3
1 10.20.1.2 rtt=1220322ms rc=8(DSRtrMatchLabel) rsc=2
DS 1: ipaddr=10.10.3.3 ifaddr=10.10.3.3 iftype=ipv4Numbered MRU=1496
label[1]=26303 protocol=6(ISIS)
label[2]=26305 protocol=6(ISIS)
DS 2: ipaddr=10.10.12.3 ifaddr=10.10.12.3 iftype=ipv4Numbered MRU=1496
label[1]=26303 protocol=6(ISIS)
label[2]=26305 protocol=6(ISIS)
DS 3: ipaddr=10.10.33.3 ifaddr=10.10.33.3 iftype=ipv4Numbered MRU=1496
label[1]=26303 protocol=6(ISIS)
label[2]=26305 protocol=6(ISIS)
2 10.20.1.3 rtt=1220323ms rc=3(EgressRtr) rsc=2
2 10.20.1.3 rtt=1220323ms rc=8(DSRtrMatchLabel) rsc=1
DS 1: ipaddr=10.10.5.5 ifaddr=10.10.5.5 iftype=ipv4Numbered MRU=1496
label[1]=26505 protocol=6(ISIS)
DS 2: ipaddr=10.10.11.5 ifaddr=10.10.11.5 iftype=ipv4Numbered MRU=1496
label[1]=26505 protocol=6(ISIS)
3 10.20.1.5 rtt=1220324ms rc=3(EgressRtr) rsc=1