A message forwarding method and device

By setting up routing and filtering port groups in ultra-low latency switches, and using filtering inspection units to mark packets that need to be filtered and discard them by downstream devices, the problem of ultra-low latency switches being unable to filter specified service flows is solved, saving bandwidth and forwarding resources.

CN116506372BActive Publication Date: 2025-12-02NEW H3C TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310485153.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-28
Publication Date
2025-12-02
Estimated Expiration
2043-04-28

AI Technical Summary

Technical Problem

Ultra-low latency switches cannot filter specified service flows, causing the packets that need to be filtered to consume bandwidth and forwarding resources.

Method used

In an ultra-low latency switch, multiple routing port groups and filtering port groups are set up. The filtering inspection unit checks whether the packets meet the filtering parameters of the port register. A cyclic redundancy check failure flag is set to mark the packets that need to be filtered and their downstream devices discard them.

Benefits of technology

This effectively prevents filtered packets from being forwarded within the network, saving bandwidth and forwarding resources.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116506372B_ABST
    Figure CN116506372B_ABST
Patent Text Reader

Abstract

This application provides a message forwarding method and device; the method includes: setting a portion of the network interface of a switching unit as multiple flow port groups including inlet and outlet flow ports; setting multiple filter port groups for a filtering inspection unit, with the filter inlet port and filter outlet port of each filter port group directly connected to the inlet and outlet flow ports of the same flow port group; setting message filtering parameters in the port register of each filter inlet port; sending each message to be filtered and inspected, whose sending network interface has been determined, to the directly connected filter inlet port through each inlet flow port; if a message received by any filter inlet port has its port register filtering parameters, then the filtering inspection is determined to have failed and a cyclic redundancy check failure flag is set; otherwise, the filtering inspection is determined to have succeeded; sending each message that has completed the filtering inspection to the directly connected outlet flow port through the filter outlet port; and sending each message that has completed the filtering inspection through the determined sending network interface.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to communication technology, specifically a message forwarding method and device. Background Technology

[0002] Currently, the financial securities industry has an increasingly strong demand for high-frequency trading, resulting in an explosive growth in demand for ultra-low latency trading systems composed of ultra-low latency switches. It is against this backdrop that ultra-low latency switches have emerged, offering advantages such as extremely low latency and minimal functionality. Ultra-low latency switches have only one layer of forwarding functionality, enabling ultra-low latency forwarding.

[0003] However, due to the limited switching capabilities of ultra-low latency switches, they are unable to filter specific service flows, resulting in packets of the specified service flows that need to be filtered being forwarded between ultra-low latency switches, consuming bandwidth and forwarding resources. Summary of the Invention

[0004] The purpose of this application is to provide a packet forwarding method and device that enables ultra-low latency switches to forward packets that need to be filtered to downstream devices for discarding.

[0005] To achieve the above objectives, this company provides a message forwarding method, which includes: configuring a portion of the network interfaces of a switching unit based on a filtering port mapping relationship as multiple flow-directing port groups; each flow-directing port group including an inlet flow-directing port and an outlet flow-directing port; configuring the same number of multiple filtering port groups for a filtering inspection unit; the filtering inlet port and filtering outlet port of each filtering port group being directly connected to the inlet flow-directing port and outlet flow-directing port of the same flow-directing port, respectively; setting message filtering parameters in the port register of the filtering inlet port of each filtering port group; and forwarding each message to be filtered and inspected, whose sending network interface has been determined, to the directly connected filtering inlet port through the inlet flow-directing port of each flow-directing port group. When a packet received by the ingress port of any filter port group has the filtering parameters in its port register, the filter check is determined to have failed and the cyclic redundancy check (CRC) failure flag is set. When a packet received by the ingress port of any filter port group does not have the filtering parameters in its port register, the filter check is determined to have succeeded. Each packet that has completed the filter check is sent to the egress port of the same filter port group. Each packet that has completed the filter check is sent through each egress port to the directly connected egress port. Each packet that has completed the filter check is sent through the determined transmission network interface so that packets with the CRC failure flag set are discarded by downstream devices.

[0006] To achieve the above objectives, this application also provides a message forwarding device for use in an ultra-low latency switch, the device comprising: a setting unit, a switching unit, and a filtering and checking unit;

[0007] The configuration unit is used to configure some network interfaces of the switching unit based on the filtering port mapping relationship as multiple flow port groups; each flow port group includes an inlet flow port and an outlet flow port; the same number of multiple filtering port groups are configured for the filtering inspection unit; the filtering inlet port and filtering outlet port of each filtering port group are directly connected to the inlet flow port and outlet flow port of the same flow port respectively; and the packet filtering parameters are set in the port register of the filtering inlet port of each filtering port group.

[0008] The switching unit is used to perform hardware forwarding of packets according to the forwarding table entries to determine the sending network interface; and to send each packet to be filtered and checked with the sent network interface determined through the inlet port of each flow port group to the directly connected filter inlet port.

[0009] The filtering check unit is used to check whether the packets received by the filtering inlet port of any filtering port group have the filtering parameters of its port register. If so, the filtering check is determined to have failed and the cyclic redundancy check failure flag is set; if not, the filtering check is determined to have succeeded. Each packet that has completed the filtering check is sent to the filtering outlet port of the same filtering port group. Each packet that has completed the filtering check is sent through the filtering outlet port directly connected to the outlet port of each flow guide port group.

[0010] The forwarding unit sends each packet that has completed the filtering check through the determined sending network interface, so that packets with the cyclic redundancy check failure flag set are discarded by downstream devices.

[0011] The beneficial effect of this application is that the ultra-low latency switch sets the packets that need to be filtered to cyclic redundancy check failure, so that these packets that need to be filtered are dropped by the downstream devices of the ultra-low latency switch, avoiding the bandwidth resources and forwarding resources occupied by the continued forwarding between ultra-low latency switches in the network. Attached Figure Description

[0012] Figure 1 A flowchart illustrating an embodiment of the message forwarding method provided in this application.

[0013] Figure 2 A schematic diagram illustrating an embodiment of the ultra-low latency switch provided in this application forwarding packets to be filtered;

[0014] Figure 3 A schematic diagram of another embodiment of the ultra-low latency switch provided in this application forwarding packets to be filtered;

[0015] Figure 4 A schematic diagram of an embodiment of the message forwarding device provided in this application. Detailed Implementation

[0016] The following detailed description will be provided with reference to several examples illustrated in the accompanying figures. In this detailed description, numerous specific details are used to provide a comprehensive understanding of the present application. Known methods, steps, components, and circuits are not described in detail in the examples to avoid obscuring their meaning.

[0017] In the terminology used, the term "including" means including but not limited to; the term "containing" means including but not limited to; the terms "above," "within," and "below" include the number itself; the terms "greater than" and "less than" mean not including the number itself. The term "based on" means based on at least a portion of them.

[0018] Figure 1 The flowchart shown is an embodiment of the message forwarding method provided in this application, including:

[0019] Step 101: Based on the filtering port mapping relationship, some network interfaces of the switching unit are set as multiple flow port groups, and each flow port group includes an inlet flow port and an outlet flow port.

[0020] Step 102: Set up multiple filter port groups of the same number for the filter inspection unit; the filter inlet port and filter outlet port of each filter port group are directly connected to the inlet and outlet ports of the same flow guide port, respectively.

[0021] Step 103: Set the packet filtering parameters for the port register of the inlet port of each filter port group;

[0022] Step 104: Send each packet to be filtered and checked from the identified sending network interface to the directly connected filtering inlet port through the inlet port of each flow guide port group.

[0023] Step 105: When the packet received by the filter input port of any filter port group has the filter parameters of its port register, determine that the filter check has failed and set the cyclic redundancy check failure flag.

[0024] Step 106: If the packet received by the filter input port of any filter port group does not have the filter parameters of its port register, the filter check is determined to be successful.

[0025] Step 107: Send each packet that has completed the filtering check to the filter output port of the same filtering port group;

[0026] Step 108: Send each packet that has completed the filtering check to the directly connected outgoing port through each filtering outgoing port;

[0027] Step 109: Send each packet that has completed the filtering check through the determined sending network interface so that packets with the Cyclic Redundancy Check failure flag set are discarded by downstream devices.

[0028] Figure 1The beneficial effect of the embodiment is that the ultra-low latency switch sets the packets that need to be filtered to cyclic redundancy check failure, so that these packets that need to be filtered are dropped by the downstream devices of the ultra-low latency switch, avoiding the bandwidth resources and forwarding resources occupied by the continued forwarding between ultra-low latency switches in the network.

[0029] Figure 2 This is a schematic diagram of an embodiment of an ultra-low latency switch forwarding packets to be filtered provided in this application. This application adds a filtering inspection unit 22 to the ultra-low latency switch 20, which can be implemented by a field-programmable gate array (FPGA) to mark the packets that need to be filtered by the ultra-low latency switch, so that the marked packets are discarded by downstream ultra-low latency switches or other downstream devices.

[0030] Figure 2 In the middle, the CPU of the ultra-low latency switch 20 ( Figure 2 (Not shown) Based on the mapping relationship of mapping the same filtering port group to the same receiving network interface, some network interfaces of the switching unit 21 are set as multiple flow port groups; the first flow port group includes inlet flow port I20 and outlet flow port I21; the second flow port group includes inlet flow port I24 and outlet flow port I23.

[0031] The CPU of the ultra-low latency switch 20 sets up two filter port groups with the same number of ports for the filter inspection unit 22; the filter input port P0 and filter output port P1 of the first filter port group are directly connected to the input port I20 and output port I21 of the same flow guide port group, respectively; the filter input port P4 and filter output port P3 of the second filter port group are directly connected to the input port I24 and output port I23 of another flow guide port group, respectively.

[0032] The CPU of the ultra-low latency switch sets packet filtering parameters for the port registers of the ingress ports P0 and P4 of each filtering port group. For example, the packet filtering parameter of the port register of ingress port P0 is the source IP address 10.10.10.10; and the packet filtering parameter of the port register of ingress port P4 is the destination IP address 30.30.30.30.

[0033] The ultra-low latency switch 20 receives packets 201 and 202 through network interface I0, and receives packet 203 through network interface I4. The source IP address and destination IP address of packet 201 are 10.10.10.10 and 4.4.4.4, respectively; the source IP address and destination IP address of packet 202 are 10.10.10.15 and 30.30.30.35, respectively; and the source IP address and destination IP address of packet 203 are 20.20.20.20 and 30.30.30.30.

[0034] Based on the forwarding table entries found, switching unit 21 determines that the sending network interfaces for messages 201 and 202 are I1 and I2, respectively; and determines that the sending network interface for message 203 is I2. Switching unit 21 adds the receiving network interface and sending network interface of messages 201, 202, and 203 to their respective inter-chip communication headers.

[0035] According to the receiving network interface of messages 201, 202, and 203, the switching unit 21 sends messages 201 and 202, which are to be filtered and checked, received through the same network interface to the inlet port I20 of the same flow guide port group; and sends message 203, which is to be filtered and checked, received through the network interface to the inlet port I24 of another flow guide port group.

[0036] The switching unit 21 sends the packets 201 and 202 to be filtered and checked to the directly connected filtering input port P0 through the input flow port I20; and sends the packet 203 to be filtered and checked to the directly connected filtering input port P4 through the input flow port I24.

[0037] The filtering inspection unit 22 checks that the message 201 received by the filtering inlet port P0 has the filtering parameter source IP address 10.10.10.10 in the port register, determines that the filtering inspection has failed, sets the message 201 to a message 201' with the cyclic redundancy check failure flag, and sends the message 201' that has completed the filtering inspection to the filtering outlet port P1 of the same filtering port group as the filtering inlet port P0.

[0038] The filtering check unit 22 checks that the message 202 received by the filtering inlet port P0 does not have the filtering parameter source IP address 10.10.10.10 in the port register, and determines that the filtering check is successful; the message 202 that has completed the filtering check is sent to the filtering outlet port P1 of the same filtering port group as the filtering inlet port P0.

[0039] The filtering inspection unit 22 checks that the message 203 received by the filtering inlet port P4 has the filtering parameters destination IP address 30.30.30.30 in the port register, determines that the filtering inspection has failed, sets the message 203 to a message 203' with the cyclic redundancy check failure flag, and sends the message 203' that has completed the filtering inspection to the filtering outlet port P3 of the same filtering port group as the filtering inlet port P4.

[0040] The filtering inspection unit 22 sends each message 201', 202, 203' that has completed the filtering inspection through each filtering output port P1, P3 to the directly connected output ports I21, I23 respectively;

[0041] The filtering inspection unit 22 receives filtering inspection messages 201' and 202 through the outgoing port I21; it receives message 203' through the outgoing port I23. It obtains the sending network interface from the inter-chip communication header of these messages and sends message 201' from network interface I1; it also sends messages 202 and 203' from network interface I2. Thus, the downstream devices connected to network interfaces I1 and I2 of the ultra-low latency switch 20 perform discard processing based on the cyclic redundancy check failure flag bits of messages 201' and 203'.

[0042] Figure 3 A schematic diagram illustrating an embodiment of the ultra-low latency switch provided in this application forwarding packets to be filtered.

[0043] Figure 3 In the middle, the CPU of the ultra-low latency switch 20 ( Figure 2 (Not shown) Based on the mapping relationship of mapping the same filtering port group to the same sending network interface, some network interfaces of the switching unit 21 are set as multiple flow port groups; the first flow port group includes inlet flow port I20 and outlet flow port I23; the second flow port group includes inlet flow port I21 and outlet flow port I24.

[0044] The CPU of the ultra-low latency switch 20 sets up two filter port groups with the same number of ports for the filter inspection unit 22; the filter input port P0 and filter output port P3 of the first filter port group are directly connected to the input port I20 and output port I23 of the same flow guide port group, respectively; the filter input port P1 and filter output port P4 of the second filter port group are directly connected to the input port I21 and output port I24 of another flow guide port group, respectively.

[0045] The CPU of the ultra-low latency switch sets packet filtering parameters for the port registers of the ingress ports P0 and P1 of each filtering port group. For example, the packet filtering parameter of the port register of ingress port P0 is the source IP address 10.10.10.10; and the packet filtering parameter of the port register of ingress port P1 is the destination IP address 30.30.30.30.

[0046] The ultra-low latency switch 20 receives packets 301 and 302 through network interface I0, and receives packet 303 through network interface I2. The source IP address and destination IP address of packet 301 are 10.10.10.10 and 4.4.4.4, respectively; the source IP address and destination IP address of packet 302 are 10.10.10.15 and 30.30.30.35, respectively; and the source IP address and destination IP address of packet 303 are 20.20.20.20 and 30.30.30.30.

[0047] Based on the found forwarding table entries, switching unit 21 determines that the sending network interfaces for messages 301 and 302 are I3 and I4, respectively; and determines that the sending network interface for message 303 is I4. Switching unit 21 adds the receiving network interface and sending network interface of messages 301, 302, and 303 to the inter-chip communication header.

[0048] According to the sending network interface of messages 301, 302, and 303, the switching unit 21 sends the message 301 to be filtered and checked to the inlet port I20 of the same inlet port group; and sends the messages 302 and 303 to be filtered and checked to the inlet port I21 of the same inlet port group.

[0049] The switching unit 21 sends the message 301 to be filtered and checked to the directly connected filtering input port P0 through the input flow port I20; and sends the messages 302 and 303 to be filtered and checked to the directly connected filtering input port P1 through the input flow port I22.

[0050] The filtering inspection unit 22 checks that the message 301 received by the filtering inlet port P0 has the filtering parameter source IP address 10.10.10.10 in the port register, determines that the filtering inspection has failed, sets the message 301 to a message 301' with the cyclic redundancy check failure flag, and sends the message 301' that has completed the filtering inspection to the filtering outlet port P3 of the same filtering port group of the filtering inlet port P0.

[0051] The filtering check unit 22 checks that the message 302 received by the filtering inlet port P1 does not have the filtering parameter destination IP address 30.30.30.30 in the port register, and determines that the filtering check is successful; the message 302 that has completed the filtering check is sent to the filtering outlet port P4 of the same filtering port group of the filtering inlet port P1.

[0052] The filtering inspection unit 22 checks that the message 303 received by the filtering inlet port P1 has the filtering parameters destination IP address 30.30.30.30 in the port register, determines that the filtering inspection has failed, sets the message 303 to a message 303' with the cyclic redundancy check failure flag, and sends the message 303' that has completed the filtering inspection to the filtering outlet port P4 of the same filtering port group of the filtering inlet port P2.

[0053] The filtering inspection unit 22 sends each message 301', 302, 303' that has completed the filtering inspection through each filtering output port P3, P4 to the directly connected output ports I23, I24 respectively.

[0054] The filtering inspection unit 22 receives the filtering inspection message 301' through the outgoing port I23; it receives messages 302 and 303' through the outgoing port I24, obtains the sending network interface from the inter-chip communication header of these messages, and sends message 301' from network interface I3; it also sends messages 302 and 303' from network interface I4. Thus, the downstream devices connected to network interfaces I3 and I4 of the ultra-low latency switch 20 perform discard processing based on the cyclic redundancy check failure flag bits of messages 301' and 303'.

[0055] Figure 4 This is a schematic diagram of an embodiment of a port statistics device applied to an ultra-low latency switch provided in this application. The device 40 includes a network interface, a switching unit that performs ultra-low latency forwarding, a filtering unit (CPU) that performs filtering checks, and a memory; the processor executes a configuration module by running processor-executable instructions in the memory.

[0056] The configuration unit is used to configure a portion of the network interfaces of the switching unit based on the filtering port mapping relationship into multiple flow port groups; each flow port group includes an inlet flow port and an outlet flow port; the same number of filtering port groups are configured for the filtering inspection unit; the filtering inlet port and filtering outlet port of each filtering port group are directly connected to the inlet and outlet flow ports of the same flow port, respectively; packet filtering parameters are set in the port register of the filtering inlet port of each filtering port group; the switching unit is used to perform packet hardware forwarding according to the forwarding table entries to determine the sending network interface; each packet to be filtered and inspected with the determined sending network interface is sent to the destination via the inlet flow port of each flow port group. The system includes: a directly connected ingress filter port; a filter checking unit, which checks whether the packets received by the ingress filter port of any filter port group have the filter parameters of its port register; if so, it determines that the filter check has failed and sets the cyclic redundancy check failure flag; if not, it determines that the filter check has succeeded; it sends each packet that has completed the filter check to the outgress filter port of the same filter port group; it sends each packet that has completed the filter check through the outgress filter port directly connected to the outgress filter port of each flow guide port group; and a forwarding unit, which sends each packet that has completed the filter check through the determined transmission network interface so that the packets with the cyclic redundancy check failure flag set are discarded by downstream devices.

[0057] The configuration unit sets up multiple routing port groups based on the filtering port mapping relationship that maps the same filtering port group to the same receiving network interface. The forwarding unit forwards each packet to be filtered and checked from the determined sending network interface to the directly connected filtering inlet port through the inlet routing port of each routing port group, including: obtaining the network interface that receives each packet to be filtered and checked; and forwarding each packet to be filtered and checked received through the same network interface to the inlet routing port of the same routing port group.

[0058] The configuration unit sets up multiple traffic redirection port groups based on the filter port mapping relationship that maps the same filter port group to the same sending network interface.

[0059] The forwarding unit sends each packet to be filtered and checked, whose sending network interface has been determined, to the directly connected filtering inlet port through the inlet port of each flow port group. This includes: obtaining the sending network interface of each packet to be filtered and checked, and sending each packet to be filtered and checked with the same sending network interface to the inlet port of the same flow port group.

[0060] The above are merely preferred embodiments of this application and are not intended to limit this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the scope of protection of this application.

Claims

1. A message forwarding method, characterized in that, The method includes: Based on the filtering port mapping relationship, some network interfaces of the switching unit are set as multiple flow guide port groups; each flow guide port group includes an inlet flow guide port and an outlet flow guide port; The filter inspection unit is provided with multiple filter port groups of the same number; the filter inlet port and filter outlet port of each filter port group are directly connected to the inlet and outlet ports of the same flow guide port, respectively. Set message filtering parameters for the port register of each of the filtered inlet ports; Each packet to be filtered and checked, which has been determined to be sent to the network interface, is sent to the directly connected filtering inlet port through the inlet port of each of the aforementioned inlet port groups. When a packet received by the filter input port of any of the filter port groups has the filter parameters of its port register, the filter check is determined to have failed and the cyclic redundancy check failure flag is set. If the packet received by any of the filtering port groups does not have the filtering parameters of its port register, the filtering check is considered successful. Each message that has completed the filtering check is sent to the filter output port of the same filtering port group. Each packet that has completed the filtering check is sent to the directly connected outgoing port through each of the filtering outgoing ports; Each packet that has completed the filtering check is sent through the determined sending network interface, so that packets with the cyclic redundancy check failure flag set are discarded by downstream devices.

2. The method according to claim 1, characterized in that, The filtering port mapping relationship is that the same receiving network interface is mapped to the same filtering port group.

3. The method according to claim 2, characterized in that, The step of sending each packet to be filtered and checked to a directly connected filtering inlet port through the inlet port of each of the aforementioned flow port groups includes: obtaining the network interface that receives each packet to be filtered and checked; and sending each packet to be filtered and checked received through the same network interface to the inlet port of the same flow port group.

4. The method according to claim 1, characterized in that, The filtering port mapping relationship is that the same sending network interface is mapped to the same filtering port group.

5. The method according to claim 4, characterized in that, The step of sending each packet to be filtered and inspected to a directly connected filtering inlet port through the inlet port of each of the flow guiding port groups includes: obtaining the sending network interface of each packet to be filtered and inspected, and sending each packet to be filtered and inspected with the same sending network interface to the inlet port of the same flow guiding port group.

6. A message forwarding device, applied to an ultra-low latency switch, characterized in that, The device includes: a setting unit, a switching unit, a filtering and checking unit, and a forwarding unit; The configuration unit is used to configure a portion of the network interfaces of the switching unit as multiple flow port groups based on the filtering port mapping relationship; each flow port group includes an inlet flow port and an outlet flow port; the same number of multiple filtering port groups are configured for the filtering inspection unit; the filtering inlet port and filtering outlet port of each filtering port group are directly connected to the inlet flow port and outlet flow port of the same flow port, respectively; and packet filtering parameters are set in the port register of the filtering inlet port of each filtering port group. The switching unit is used to perform hardware forwarding of packets according to the forwarding table entries to determine the sending network interface; and to send each packet to be filtered and checked with the determined sending network interface to the directly connected filtering inlet port through the inlet port of each of the routing port groups. The filtering check unit is used to check whether the packets received by the filtering inlet port of any of the filtering port groups have the filtering parameters of its port register. If yes, the filtering check is determined to have failed and the cyclic redundancy check failure flag is set. If no, the filtering check is determined to have succeeded. Each packet that has completed the filtering check is sent to the filtering outlet port of the same filtering port group. Each packet that has completed the filtering check is sent through the filtering outlet port directly connected to the outlet port of each of the flow guiding port groups. The forwarding unit sends each packet that has completed the filtering check through the determined sending network interface, so that packets with the cyclic redundancy check failure flag set are discarded by downstream devices.

7. The device according to claim 6, characterized in that, The filtering port mapping relationship is that the same receiving network interface is mapped to the same filtering port group.

8. The device according to claim 7, characterized in that, The forwarding unit sends each packet to be filtered and checked, whose sending network interface has been determined, to the directly connected filtering inlet port through the inlet port of each of the flow guiding port groups, including: obtaining the network interface that receives each packet to be filtered and checked; and sending each packet to be filtered and checked received through the same network interface to the inlet port of the same flow guiding port group.

9. The device according to claim 6, characterized in that, The filtering port mapping relationship is that the same sending network interface is mapped to the same filtering port group.

10. The device according to claim 9, characterized in that, The forwarding unit sends each packet to be filtered and checked, whose sending network interface has been determined, to the directly connected filtering inlet port through the inlet port of each of the flow guiding port groups. This includes: obtaining the sending network interface of each packet to be filtered and checked, and sending each packet to be filtered and checked that has the same sending network interface to the inlet port of the same flow guiding port group.

Citation Information

Patent Citations

  • Message deduplication method and device, convergence and distribution equipment and storage medium

    CN112714077A

  • Network switch

    US20050047411A1