# US 2023/0155928 A1 · In-Situ Flow Detection Method and Related Device

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2023/0155928 A1
- Document ID: US20230155928A1
- Status: Published application
- Kind: A1
- Application number: 18/155,011
- Filed: 2023-01-16
- Published: 2023-05-18
- Earliest claimed: 2020-07-17
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Zhiyong Ben; Weidong Li
- Web page: https://patentgrep.com/patent/US20230155928A1

## CPC

- H04L 43/026: using flow identification
- H04L 45/38: {Flow based routing}
- H04L 12/4633: {Interconnection of networks using encapsulation techniques, e.g. tunneling}
- H04L 43/0876: Network utilisation, e.g. volume of load or congestion level
- H04L 45/50: using label swapping, e.g. multi-protocol label switch [MPLS]
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

An in-situ flow detection method and a related device are disclosed pertaining to the field of communication technologies. The method includes, when a tunnel type of an uplink tunnel of a first node is inconsistent with a tunnel type of a downlink tunnel of the first node, the first node generates a second traffic detection header based on a first traffic detection header. Therefore, the first node can continue to send, to a next hop without using an IFIT indication delivered by a control node, a packet that carries a traffic detection header, so that in-situ flow detection across tunnels of different types is implemented.

## Claims

### Claim 1

A network device, comprising:
a first node in a transmission path of a to-be-detected data flow, wherein the transmission path comprises the first node, a second node, and a third node;
wherein the network device further comprises:
a processor; and
a non-transitory computer-readable storage medium storing a program to be executed by the processor, the program including instructions to:
receive a packet sent by the second node;
generate, based on the packet comprising a first traffic detection header and based on a tunnel type of an uplink tunnel of the packet being inconsistent with a tunnel type of a downlink tunnel of the packet, a second traffic detection header based on the first traffic detection header;
replace the first traffic detection header in the packet with the second traffic detection header; and
send the packet comprising the second traffic detection header to the third node;
wherein the second traffic detection header is a traffic detection header supported by the downlink tunnel, the uplink tunnel is a tunnel between the second node and the first node, and the downlink tunnel is a tunnel between the first node and the third node.

### Claim 2 (depends on 1)

The network device according to claim 1, wherein the instructions further include to:
determine, after the packet sent by the second node is received, whether the packet comprises the first traffic detection header; and
determine, based on the packet comprising the first traffic detection header, whether the tunnel type of the uplink tunnel of the packet is consistent with the tunnel type of the downlink tunnel of the packet.

### Claim 3 (depends on 2)

The network device according to claim 2, wherein the packet comprises a first flag field, and a value of the first flag field indicates whether in-situ flow detection is in-situ flow detection across tunnels of different types; and
wherein the instructions further include instructions to determine, based on the value of the first flag field indicating that the in-situ flow detection is the in-situ flow detection across tunnels of different types, whether the tunnel type of the uplink tunnel of the packet is consistent with the tunnel type of the downlink tunnel of the packet.

### Claim 4 (depends on 3)

The network device according to claim 3, wherein the instructions further include instructions to:
skip performing, based on the value of the first flag field indicating that the in-situ flow detection is in-situ flow detection for tunnels of a same type, an operation of determining whether the tunnel type of the uplink tunnel of the packet is consistent with the tunnel type of the downlink tunnel of the packet; and
update a value of a time to live TTL field in the first traffic detection header; and
send a packet comprising the updated first traffic detection header to the third node.

### Claim 5 (depends on 3)

The network device according to claim 3, wherein the first flag field is a field in the first traffic detection header.

### Claim 6 (depends on 5)

The network device according to claim 5, wherein, based on the first traffic detection header indicating that the in-situ flow detection is in-situ flow information telemetry (IFIT) detection, the first flag field is a field in a flow instruction extension header (FIEH) comprised in the first traffic detection header.

### Claim 7 (depends on 2)

The network device according to claim 2, wherein the instructions further include instructions to:
add an internal forwarding header to the packet, wherein the internal forwarding header comprises a second flag field, and a value of the second flag field indicates whether the packet comprises a traffic detection header; and
determine, based on the value of the second flag field, whether the packet comprises the first traffic detection header.

### Claim 8 (depends on 7)

The network device according to claim 7, wherein the internal forwarding header further comprises a third flag field, and a value of the third flag field indicates the tunnel type of the uplink tunnel based on the value of the second flag field indicating the packet comprises the first traffic detection header; and
wherein the instructions further include instructions to determine, based on the value of the third flag field, whether the tunnel type of the uplink tunnel of the packet is consistent with the tunnel type of the downlink tunnel of the packet.

### Claim 9 (depends on 2)

The network device according to claim 2, wherein the instructions further include instructions to:
update, after whether the tunnel type of the uplink tunnel of the packet is consistent with the tunnel type of the downlink tunnel of the packet is determined, a value of a time to live TTL field in the first traffic detection header base on the tunnel type of the uplink tunnel of the packet being consistent with the tunnel type of the downlink tunnel of the packet; and
send a packet comprising the updated first traffic detection header to the third node.

### Claim 10 (depends on 1)

The network device according to claim 1, wherein the instructions further include instructions to:
determine, based on the packet comprising the first traffic detection header and the tunnel type of the uplink tunnel of the packet being inconsistent with the tunnel type of the downlink tunnel of the packet, a link state packet based on the first traffic detection header, wherein the link state packet comprises a fourth flag field, and wherein a value of the fourth flag field indicates that an uplink tunnel type of the first node and a downlink tunnel type of the first node are inconsistent; and
send the link state packet to a control node.

### Claim 11 (depends on 1)

The network device according to claim 1, wherein the instructions further include instructions to:
determine a difference between a value of a time to live TTL field in the first traffic detection header and a reference value as a value of a TTL field in the second traffic detection header; and
copy a value of another field that is in the first traffic detection header and that is the same as a field in the second traffic detection header to the second traffic detection header.

### Claim 12 (depends on 1)

The network device according to claim 1, wherein the first traffic detection header indicates to perform in-situ flow information telemetry (IFIT) detection or internet protocol flow performance measurement (IPFPM) detection on the to-be-detected data flow.

### Claim 13 (depends on 1)

The network device according to claim 1, wherein the tunnel type comprises a multiprotocol label switching (MPLS) tunnel and a segment routing over internet protocol version 6 (SRv6) tunnel.

### Claim 14

A network device, comprising:
an ingress node of a to-be-detected data flow in a network system, wherein a first node, a second node, and a third node are three nodes in a transmission path of the to-be-detected data flow, and where the network device further comprises:
a processor; and
a non-transitory computer-readable storage medium storing a program to be executed by the processor, the program including instructions to:
receive an in-situ flow detection request delivered by a control node, wherein when in-situ flow detection for the to-be-detected data flow is in-situ flow detection across tunnels of different types, wherein the in-situ flow detection request indicates that the in-situ flow detection is the in-situ flow detection across tunnels of different types, wherein across tunnels of different types means that a tunnel type of an uplink tunnel of a node in the transmission path of the to-be-detected data flow is inconsistent with a tunnel type of a downlink tunnel of the node in the transmission path of the to-be-detected data flow, and wherein a hybrid in-situ flow detection request comprises a flow identifier of the to-be-detected data flow; and
add, based on a packet indicated by the flow identifier being received, a first traffic detection header to the packet, wherein the first traffic detection header indicates to perform the in-situ flow detection on the data flow indicated by the flow identifier.

### Claim 15 (depends on 14)

The network device according to claim 14, wherein the first traffic detection header indicates to perform in-situ flow information telemetry (IFIT) detection or internet protocol flow performance measurement (IPFPM) detection on the to-be-detected data flow.

### Claim 16 (depends on 14)

The network device according to claim 14, wherein a packet obtained through processing by the ingress node comprises a first flag field, and a value of the first flag field indicates that the in-situ flow detection is the in-situ flow detection across tunnels of different types, based on the in-situ flow detection request indicating that the in-situ flow detection is the in-situ flow detection across tunnels of different types.

### Claim 17 (depends on 16)

The network device according to claim 16, wherein the value of the first flag field added to the packet indicates that the in-situ flow detection is the in-situ flow detection for tunnels of a same type, based on the in-situ flow detection request indicating that the in-situ flow detection is in-situ flow detection for tunnels of a same type.

### Claim 18 (depends on 16)

The network device according to claim 16, wherein the first flag field is a field in the first traffic detection header.

### Claim 19 (depends on 18)

The network device according to claim 18, wherein, based on the first traffic detection header indicating that the in-situ flow detection is in-situ flow information telemetry (IFIT) detection, the first flag field is a field in a flow instruction extension header (FIEH) comprised in the first traffic detection header.

### Claim 20

An in-situ flow detection system, comprising:
a control node configured to send an in-situ flow detection request to an ingress node;
the ingress node of a data flow configured to:
receive the in-situ flow detection request delivered by the control node, wherein the in-situ flow detection request comprises a flow identifier of a to-be-detected data flow; and
add, based on receiving a packet indicated by the flow identifier, a first traffic detection header to the packet, wherein the first traffic detection header indicates to perform the in-situ flow detection on the data flow indicated by the flow identifier
a first node, wherein the first node is a next-hop node of the ingress node, and wherein the first node is configured to:
receive a packet sent by the ingress node;
generate, based on the packet comprising a first traffic detection header and a tunnel type of an uplink tunnel of the packet being inconsistent with a tunnel type of a downlink tunnel of the packet, a second traffic detection header based on the first traffic detection header,
replace the first traffic detection header in the packet with the second traffic detection header, wherein the second traffic detection header is a traffic detection header supported by the downlink tunnel, the uplink tunnel is a tunnel between the ingress node and the first node, the downlink tunnel is a tunnel between the first node and a third node, and the third node is a next hop for the first node to forward the packet; and
send a packet comprising the second traffic detection header to the third node;
wherein when in-situ flow detection for the data flow is in-situ flow detection across tunnels of different types, the in-situ flow detection request indicates that the in-situ flow detection is the in-situ flow detection across tunnels of different types, and being across tunnels of different types means that a tunnel type of an uplink tunnel of a node in a transmission path of a to-be-detected data flow is inconsistent with a tunnel type of a downlink tunnel of the node.
