# US 11,444,864 B2 · Optimized datapath troubleshooting with trace policy engine

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

- Number: US 11,444,864 B2
- Document ID: US11444864B2
- Status: Granted
- Kind: B2
- Application number: 16/759,469
- Filed: 2017-10-27
- Published: 2020-10-29
- Granted: 2022-09-13
- Earliest claimed: 2017-10-27
- Assignees: Telefonaktiebolaget LM Ericsson (publ)
- Applicants: Telefonaktiebolaget Lm Ericsson (Publ)
- Inventors: Faseela K; Vyshakh Krishnan C H
- Web page: https://patentgrep.com/patent/US11444864B2

## CPC

- H04L 43/10: Active monitoring, e.g. heartbeat, ping or trace-route
- H04L 43/12: Network monitoring probes
- H04L 41/0677: Localisation of faults
- H04L 41/0806: for initial configuration or provisioning, e.g. plug-and-play
- H04L 41/40: using virtualisation of network functions or resources, e.g. SDN or NFV entities
- H04L 43/062: related to network traffic
- H04L 43/20: the monitoring system or the monitored elements being virtualised, abstracted or software-defined entities, e.g. SDN or NFV
- H04L 45/38: {Flow based routing}
- H04L 45/70: {Routing based on monitoring results}
- H04L 49/3009: {Header conversion, routing tables or routing tags}
- H04L 49/3063: {Pipelined operation}
- H04L 41/0661: {by reconfiguring faulty entities}
- H04L 43/026: using flow identification
- H04L 45/74: Address processing for routing
- H04L 45/7453: using hashing
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

A system for tracing packets in a Software Defined Networking (SDN) network. The system includes a switch and an SDN controller communicatively coupled to the switch. The SDN controller is configured to program a packet processing pipeline of the switch to cause the switch to determine, at a first flow table of the packet processing pipeline, whether a packet is a trace packet that was recirculated based on content of a first field associated with the packet and in response to a determination that the packet is a trace packet that was recirculated, set a first field associated with the packet to indicate that tracing is disabled for the packet, set a second field associated with the packet to indicate that tracing is enabled for the packet, determine a flow table of the packet processing pipeline from which the packet was recirculated, and direct the packet to that flow table.

## Claims

### Claim 1

A method implemented by a switch in a Software Defined Networking (SDN) network to trace packets, where the switch includes a packet processing pipeline that includes a plurality of flow tables, the method comprising:
receiving a packet;
determining, at a first flow table of the packet processing pipeline, whether the packet is a trace packet that was recirculated based on content of a first field associated with the packet;
in response to the determination that the packet is a trace packet that was recirculated, the method further comprises:
setting a first field associated with the packet to indicate that tracing is disabled for the packet, and
setting a second field associated with the packet to indicate that tracing is enabled for the packet, determining a flow table of the packet processing pipeline from which the packet was recirculated, and directing the packet to the flow table from which the packet was recirculated;
and
in response to the determination that the packet is not a trace packet that was recirculated, the method further comprises:
determining, at the first flow table, whether the packet is to be traced through the packet processing pipeline; and
creating a copy of the packet, setting a first field associated with the copy of the packet to indicate that tracing is enabled for the copy of the packet, outputting the copy of the packet to a recirculate port, and directing the packet to a subsequent flow table of the packet processing pipeline in response to a determination that the packet is to be traced through the packet processing pipeline.

### Claim 2 (depends on 1)

The method of claim 1, wherein the packet that is directed to the subsequent flow table is processed through a remainder of the packet processing pipeline without being traced.

### Claim 3 (depends on 1)

The method of claim 1, further comprising:
determining, at a second flow table of the packet processing pipeline, whether the packet is to be traced based on content of the first field associated with the packet; and
recording an indication that the packet is being recirculated from the second flow table, sending a trace message for the packet to a trace collector, and outputting the packet to a recirculate port in response to a determination at the second flow table that the packet is to be traced.

### Claim 4 (depends on 3)

The method of claim 3, further comprising:
copying, at the second flow table, content of the second field associated with the packet to the first field associated with the packet before directing the packet to a subsequent flow table of the packet processing pipeline in response to a determination at the second flow table that the packet is not to be traced.

### Claim 5 (depends on 3)

The method of claim 3, further comprising:
directing the packet to a trace group, wherein the trace group has a first bucket that specifies instructions to send the trace message for the packet to the trace collector and a second bucket that specifies instructions to output the packet to the recirculate port.

### Claim 6 (depends on 3)

The method of claim 3, wherein the indication that the packet is being recirculated from the second flow table is included in a Virtual Local Area Network (VLAN) header added to the packet.

### Claim 7 (depends on 3)

The method of claim 3, wherein the indication that the packet is being recirculated from the second flow table is included in a metadata field associated with the packet.

### Claim 8 (depends on 1)

The method of claim 1, wherein the flow table from which the packet was recirculated is determined based on reading an indication included in a Virtual Local Area Network (VLAN) header added to the packet.

### Claim 9 (depends on 1)

The method of claim 1, wherein the packet processing pipeline is an OpenFlow packet processing pipeline, wherein the first field associated with the packet is a bit in a metadata field associated with the packet, and wherein the second field associated with the packet is a packet register field associated with the packet.

### Claim 10 (depends on 1)

The method of claim 1, further comprising:
determining whether the packet includes an indication of a flow table of the packet processing pipeline from which the packet was recirculated; and
directing the packet to a subsequent flow table of the packet processing pipeline without altering the first field associated with the packet in response to a determination that the packet is a trace packet that was recirculated and the packet does not include an indication of a flow table of the packet processing pipeline from which the packet was recirculated.

### Claim 11 (depends on 1)

The method of claim 1, further comprising:
determining whether the packet was recirculated from an egress flow table of the packet processing pipeline; and
dropping the packet in response to a determination that the packet is a trace packet that was recirculated and the packet was recirculated from the egress flow table of the packet processing pipeline.

### Claim 12

A system for tracing packets in a Software Defined Network (SDN) network, comprising:
a switch that includes a packet processing pipeline;
an SDN controller communicatively coupled to the switch; and
a trace policy engine communicatively coupled to the SDN controller, wherein the trace policy engine is configured to:
cause the SDN controller to set up a trace infrastructure in the switch that causes the switch to create a copy of a packet in response to a determination that the packet is to be traced and output the copy of the packet to a recirculate port while directing the packet to a subsequent flow table of the packet processing pipeline,
cause the SDN controller to enable tracing at the switch for packets belonging to a flow in response to a determination as at least one of,
a user-request to trace the packets belonging to the flow; and
a packet belonging to the flow has been dropped;
collect trace messages for the packets belonging to the flow,
analyze the trace messages for the packets belonging to the flow to
determine at least one of:
a traversal-path of packet; and
a flow-table of the packet processing pipeline of the switch at which packets are being dropped,
and
store a result of the analysis.

### Claim 13 (depends on 12)

The system of claim 12, wherein the request includes an indication of a packet matching criteria for the packets belonging to the flow.

### Claim 14 (depends on 12)

The system of claim 12, wherein the determination that the packets belonging to the flow should be traced is based on a determination that a packet belonging to the flow has been dropped.

### Claim 15 (depends on 12)

The system of claim 12, wherein the trace policy engine is further configured to generate a sample packet belonging to the flow and send the sample packet to the switch to be traced at the switch.

### Claim 16 (depends on 12)

The system of claim 12, wherein the trace policy engine is further configured to trigger a restart of a module in the SDN controller that is responsible for the flow table at which packets are being dropped, wherein the restart of the module causes flow entries in the flow table at which packets are being dropped to be reinstalled.

### Claim 17 (depends on 12)

The system of claim 12, wherein the trace policy engine is further configured to notify a module in the SDN controller that is responsible for the flow table at which packets are being dropped.

### Claim 18 (depends on 12)

The system of claim 12, wherein the trace policy engine is further configured to analyze the trace messages for the packets belonging to the flow to detect a packet loop within the packet processing pipeline of the switch.
