Dual-transmission redundancy method and storage medium based on traffic mirroring
By adopting a dual-send redundancy method based on traffic mirroring in 4G/5G or WiFi networks, a multi-path redundant backup is established and redundant traffic is filtered on the receiving end, which solves the packet loss problem of network traffic in the case of unstable links. , realizes the 0 packet loss rate of network transmission and the requirements of WAN transmission.
Patent Information
- Application Number
- CN202211537935.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-02
- Publication Date
- 2025-02-07
- Estimated Expiration
- 2042-12-02
AI Technical Summary
In 4G/5G or WiFi networks, network traffic is prone to packet loss due to unstable links and hardware abnormalities. Especially in remote office and Internet of Things scenarios, packet loss not only affects the user experience, but also poses security risks.
Using the dual-transmitted redundancy method based on traffic mirroring, by establishing multiple transmission channels between the sending network element and the receiving network element, copying IP traffic using the mirroring strategy to form a 1:N multi-path redundant backup, and pass the inspection at the receiving end. The heavy strategy filters out redundant traffic to ensure the 0 packet loss rate of network transmission.
It realizes the 0 packet loss rate of the same packets transmitted on multiple paths in network transmission, and is backed up by each other. At the same time, it avoids the impact of redundant packets on terminal customer applications and meets the needs of wide-area network transmission.
Smart Images

Figure CN115766571B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of computer network data communication, and in particular to a dual-transmission redundancy method based on traffic mirroring. Background Art
[0002] When network traffic is transmitted between devices, it may be affected by factors such as link bandwidth, device cache size, policy control, and hardware anomalies. Especially when network traffic needs to be transmitted via 4G / 5G or WiFi, wireless links are more unstable than wired links due to obstructions, humidity, temperature, and lightning weather. These factors may cause packet loss in network traffic. In scenarios such as remote office and the Internet of Things, if audio and video messages or control signals are lost, it will not only reduce the user experience, but also pose a major safety hazard and lead to property losses. Therefore, ensuring zero packet loss in network traffic transmission is receiving more and more attention.
[0003] Currently, the widely used technologies to ensure zero packet loss rate of network traffic transmission can be divided into three categories:
[0004] 1. Equipment redundancy backup. In the event of a device failure, the network traffic transmission packet loss rate is guaranteed by switching between devices. Commonly used technical means include MC-LAG, VRRP, HSRP, and stacking. Equipment redundancy backup technology not only requires high costs, but also equipment failure switching will inevitably cause packet loss;
[0005] 2. Link protection. A protection relationship is formed between transmission links. Only one link transmits packets in the same time period. The link status is detected through BFD or keep-alive mechanisms. When the link is abnormal, it switches to the backup link. Common technical means include link aggregation mechanism, fast rerouting, and protection group. However, packet loss is inevitable during link switching;
[0006] 3. Redundant transmission of network traffic. Network traffic is transmitted through different transmission paths, and N (N>1) copies of traffic are transmitted between the sending network element and the receiving network element. The receiving network element filters out redundant traffic to ensure that there is always normal traffic transmission between network elements when an abnormality occurs at any time and on any path, thereby achieving a zero packet loss rate. The technologies used are TSN and PRP. However, both TSN and PRP protocols achieve redundant transmission of network traffic by extending link layer fields and interacting, which is not conducive to wide area network applications.
[0007] Whether it is the Internet of Things or APP applications such as voice and video, they all need to be transmitted over a wide area network to achieve long-distance or even cross-regional interactions. When traffic is transmitted over a wide area network, it not only passes through many network nodes, but also there are large differences in hardware and software between different network nodes. At the same time, most wide area networks are IP protocols. Therefore, it is necessary to provide a redundant transmission method for network traffic based on the IP protocol to avoid unnecessary network bandwidth consumption due to extended fields. Summary of the invention
[0008] The present invention proposes a dual-transmission redundancy method based on traffic mirroring, which can solve the problem of replicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy to achieve a method of achieving zero packet loss in network transmission.
[0009] To achieve the above object, the present invention adopts the following technical solutions:
[0010] A dual-transmission redundancy method based on traffic mirroring, a method for replicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundancy backup, comprising:
[0011] Step 1: Establish multiple transmission channels between the sending network element and the receiving network element. Channel 1 is the main transmission path, that is, the protected path;
[0012] Step 2: Use channel 1 as the mirror source of the mirror policy and enable dual-transmission protection. If channel 1 forwards multiple service flows or flows accessing multiple destination network elements, it is required to enable dual-transmission protection for specific flows. Use the access control list ACL to filter out the required flows and enable dual-transmission protection for specific flows.
[0013] Step 3, set other transmission channels 2, ..., n between the sending network element and the receiving network element as redundant backup paths, namely, protection paths. The protection path is used as the mirroring destination of the mirroring strategy, and the protected path and the protection path form a dual-transmission relationship through the mirroring strategy;
[0014] Step 4: When dual-transmission protection is enabled, set the version number, source IP, destination IP, fragment identifier, and offset value of the IPv4 or IPv6 message header of the protected traffic as the unique identifier of the traffic and the dual-transmission protection mark; in addition to normal forwarding, the protected traffic is copied to the mirror destination based on the mirroring strategy, that is, the protection path;
[0015] Step 5: The protected traffic is used as a payload message at the mirror destination, and the outer message header is encapsulated according to the type of the mirror destination path; on the protection path, the message of the protected traffic is used as a payload and is not allowed to be modified, and is forwarded to the receiving network element according to the field information encapsulated in the outer message;
[0016] Step 6: The receiving network element sets channel 1, channel 2, ..., channel n to the same selective receiving group to enable selective receiving and weight checking. The main path, such as channel 1, has the role set to MASTER; the other protection paths have the role set to SLAVE;
[0017] Step 7: The selective receiving group members of the receiving network element parse the received message. If the message carries a double-send protection mark, the traffic unique identifier is parsed and recorded to form a redundant filtering and duplication detection table. The selective receiving group members parse the traffic unique identifier of the message received, and check whether there is a record in the redundant filtering and duplication detection table. If there is no record in the redundant duplication detection and filtering table, it means that the message is received for the first time, and it is forwarded and processed normally; if there is, it means that the same message has been received, and the current message is a redundant message, so the message is discarded.
[0018] Furthermore, it also includes a computer-readable storage medium storing a computer program, and when the computer program is executed by a processor, the processor executes the steps of the above method.
[0019] It can be seen from the above technical solution that the dual-transmission redundancy method based on traffic mirroring of the present invention provides a method for replicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy. The patented method is embodied in three aspects: 1. The mirroring strategy is extended to support 1:N redundant backup protection; 2. The version number, source IP, destination IP, fragment identifier and offset value of IPv4 and IPv6 are marked as unique identifiers of traffic; 3. The receiving network element detects and filters redundant traffic.
[0020] The present invention provides a method for achieving zero packet loss in network transmission by duplicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy. The scheme of the present invention expands the mirroring strategy used for network anomaly diagnosis, establishes a backup transmission channel between the sending network element and the receiving network element in addition to the normal transmission path; encapsulates the message with the unique identifier of the traffic, and in addition to normal forwarding, copies a copy and imports it into the backup transmission path through the mirroring strategy, thereby achieving dual-transmission redundant transmission of key traffic between network elements. Whether it is the main path or the backup transmission path, if any path loses packets due to insufficient bandwidth, flow control strategy or link anomaly, the normal transmission of the message on one path can be guaranteed. In order to avoid the receiving network element receiving redundant messages, causing voice, video or data replay, by identifying and recording the unique identifier of the traffic in the message, for the received network traffic, the redundant backup that arrives later is discarded, thereby realizing the redundant transmission of the traffic and the reliability requirements of the unique received data.
[0021] The beneficial effects of the present invention are:
[0022] The present invention provides a method for achieving 0 packet loss in network transmission by duplicating IP traffic based on a mirroring strategy to form 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy. In the scheme of the present invention, the version number, source IP, destination IP, fragment identifier and offset value in IPv4 and IPv6 messages are used as redundant message uniqueness detection and filtering conditions to avoid bandwidth consumption and docking incompatibility caused by extended fields; at the same time, the use of the mirroring strategy can not only realize 1:N multi-path backup, but also the backup path can support multiple transmission channels, which can meet multiple scenarios such as layer 2 and 3 networks and NAT traversal. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 A model diagram of a solution for realizing traffic redundancy backup and duplicate checking and filtering based on a mirroring strategy provided by an embodiment of the present invention;
[0024] Figure 2 A processing flow chart for forming redundant backup messages and setting IP message uniqueness information through a mirroring strategy provided by an embodiment of the present invention;
[0025] Figure 3 The field used as the uniqueness information of the redundant message in IPv4 provided in the embodiment of the present invention and the first bit of the extended IPv4 Flag indicate that it is a redundant backup protection message;
[0026] Figure 4 The field used as the uniqueness information of the redundant message in the IPv6 provided in the embodiment of the present invention and the Res field identifier of the extended IPv6 fragment header are redundant backup protection messages;
[0027] Figure 5 A processing flow chart of receiving network element parsing messages and filtering redundant messages provided in an embodiment of the present invention;
[0028] Figure 6 A processing flow chart of establishing, modifying and aging a redundant duplicate check filter table on a receiving network element provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0029] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments.
[0030] like Figure 1As shown, the dual-transmission redundancy method based on traffic mirroring described in this embodiment provides a method for replicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy to achieve zero packet loss in network transmission. Through the embodiment of the present invention, it is possible to achieve zero packet loss in which multiple paths transmit the same message in network transmission and back up each other; at the same time, redundant filtering is enabled at the receiving end to avoid replay of audio, video and data of terminal customer applications.
[0031] like Figure 1 , the method comprising:
[0032] Step S101: The mirroring strategy monitoring source of the sending end A enables redundant backup protection, and the IP forwarding traffic is Figure 3 and Figure 4 Set the unique identification field of the message and then forward it. At the same time, copy the traffic to N mirror destination links according to the mirroring policy.
[0033] Step S102, N mirror destination links encapsulate message headers according to link characteristics; and use the message copied from the mirror source as the payload, so as to keep the original forwarded message, and achieve the purpose of multi-path redundant backup transmission; at the same time, the N backup paths can be layer 2 transmission or IPSec, L2TP and other forwarding, to meet the requirements of transmission in different networks;
[0034] Step S103: Multiple links of the receiving end B form a redundant backup protection group, and the link connected to the mirror source of the sending end A is defined as the MASTER; the other links connected to the mirror destination of the sending end A are defined as the SLAVE. The link of the SLAVE role on the receiving end B needs to strip off the outer encapsulation header to obtain the IP packet header in the Payload; according to Figure 3 and Figure 4 As shown, extract the fields in the IP message header with redundant backup protection marks on the MASTER link and multiple SLAVE links, and use the duplicate check filter table to determine whether the same message has been received. If the unique identifier of the message is not in the duplicate check filter table, the message is considered to be received for the first time and is processed by the receiving end B; if the unique identifier of the message exists in the duplicate check filter table, the message is considered to be redundant and is discarded.
[0035] Figure 2 The invention describes a method for generating redundant backup message forwarding after the sender A uniquely identifies the IP traffic based on the mirroring strategy, including:
[0036] Step 201: The forwarding link of the message of the sender A is used as the monitoring source of the mirroring strategy. If the mirroring strategy refers to the ACL access control list strategy, only the traffic that meets the "five-tuple" condition will execute the mirroring strategy; otherwise, all messages of the forwarding link will execute the mirroring strategy;
[0037] Step 202: If the monitoring source of the mirroring strategy has enabled redundant backup protection, Figure 3 and Figure 4 , after setting the unique identification field value of the IPv4 or IPv6 packet header, copy the traffic N times and query the destination link forwarding table of the mirroring policy;
[0038] Step 203: The N duplicated redundant protection messages are used as payloads on the destination link of the mirroring strategy, and the outer message headers are re-encapsulated according to the table information of the forwarding link.
[0039] Figure 3 The color-coded field is used as unique information for IPv4 packets. The processing methods include:
[0040] Step 301, the source IP and destination IP of IPv4 are encapsulated according to the information of the monitoring source of the mirroring strategy;
[0041] Step 302: Enable redundant backup protection for the monitoring source of the mirroring strategy, set the PF bit in the 3-bit flag field of IPv4 to 1, indicating that the current message is enabled with redundant backup protection; at the same time, use the global counter to set the 16-bit flag field, and if the message is packetized due to MTU, set the fragment offset field value of the message.
[0042] Figure 4 The color-coded field is used as unique information for IPv6 packets. The processing methods include:
[0043] Step 401, the source IP and destination IP of IPv6 are encapsulated according to the information of the monitoring source of the mirroring strategy;
[0044] Step 402: Enable redundant backup protection for the monitoring source of the mirroring strategy, and add a FragmentHeader extension header to the forwarded IPv6. Set the Res field in the Fragment Header to 01; use the global counter to set the identifier field value in the Fragment Header; if the message is fragmented due to MTU, set the fragment offset value of the Fragment Header.
[0045] Figure 5 The method for receiving end B to process redundant messages is described, including:
[0046] Step 501, the receiving end B defines multiple links as redundant backup protection groups. The link connected to the mirror policy monitoring source of the sending end A is defined as MASTER, and the other links are defined as SLAVE. The link of the SLAVE role needs to obtain the IP header information of the Payload, and the link of the MASTER role parses the outermost IP header;
[0047] Step 502: Link analysis of the MASTER role and the SLAVE role determines whether the IP message is marked with redundant backup protection. If there is a redundant backup protection mark, the unique identification field is extracted and the duplicate check filter table is queried; if there is no redundant backup protection mark, the message is processed normally;
[0048] Step 503: For the message with the redundant backup protection mark, query the duplicate check filter table to determine whether the unique duplicate check field information has been recorded in the table. If the unique field information carried by the message cannot be found in the duplicate check filter table, it is considered to be a message received for the first time and the next step is carried out; if the unique field information carried by the message is found in the duplicate check filter table, it is considered to be a redundant message and the message is discarded.
[0049] Figure 6 The aging mechanism of the duplicate check filter table of the receiving end B is described to realize the table entry update after the redundant message is lost during the network transmission and the same message on multiple redundant paths has been processed. The method includes:
[0050] Step 601: After receiving a message with a redundant backup protection mark, the link between the MASTER role and the SLAVE role queries the duplicate check filter table. If there is no unique field information in the duplicate check filter table, an entry is added and the number of matches is increased by 1; if the unique field information in the duplicate check filter table is matched, only the number of matches is increased by 1;
[0051] Step 602: When the system enables the redundant backup protection function, start the aging cycle timer of the duplicate check filter table. Each time the timer expires, the duplicate check filter table entries are inspected, the number of matches for each entry is increased by 1, and the difference between the number of matches for the entry and the redundant backup protection member is calculated. If the difference is greater than 2, it means that it has been marked at least twice by the aging timer, and the entry is deleted.
[0052] In summary, the embodiment of the present invention provides a method for replicating IP traffic based on a mirroring strategy to form a 1:N multi-path redundant backup, and filtering out redundant traffic through a receiving duplicate detection strategy to achieve zero packet loss in network transmission. In the scheme of the present invention, the version number, source IP, destination IP, fragment identifier and offset value in IPv4 and IPv6 messages are used as redundant message uniqueness detection and filtering conditions to avoid bandwidth consumption and docking incompatibility caused by extended fields; at the same time, the use of the mirroring strategy can not only achieve 1:N multi-path backup, but also the backup path can support multiple transmission channels, which can meet multiple scenarios such as layer 2 and 3 networks and NAT traversal.
[0053] In yet another aspect, the present invention further discloses a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor executes the steps of any of the above methods.
[0054] On the other hand, the present invention further discloses a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of any of the above methods.
[0055] In another embodiment provided by the present application, a computer program product including instructions is also provided, which, when executed on a computer, enables the computer to execute the steps of any method in the above embodiments.
[0056] It is understandable that the system provided by the embodiment of the present invention corresponds to the method provided by the embodiment of the present invention, and the explanation, examples and beneficial effects of the relevant contents can refer to the corresponding parts in the above method.
[0057] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0058] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0059] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A dual-transmission redundancy method based on traffic mirroring, characterized in that: The following steps are included: Step 1: Establish multiple transmission channels between the sending network element and the receiving network element; channel 1 is the main transmission path, that is, the protected path; Step 2: Set channel 1 as the mirror source of the mirror policy and enable double-transmission protection. Step 3, setting other transmission channels 2 to n between the sending network element and the receiving network element as redundant backup paths, i.e., protection paths; The protection path is used as the mirroring destination of the mirroring policy. The protected path and the protection path form a dual-transmission relationship through the mirroring policy. Step 4: When double-send protection is enabled, set the version number, source IP address, destination IP address, fragment identifier, and offset value of the IPv4 or IPv6 message header of the protected traffic as the unique identifier of the traffic and the double-send protection mark; In addition to normal forwarding, the protected traffic is copied to the mirror destination based on the mirroring strategy, that is, the protection path; Step 5: The protected traffic is used as a payload message at the mirror destination, and an outer message header is encapsulated according to the type of the mirror destination path. On the protection path, the protected traffic message is used as the payload and is not allowed to be modified. It is forwarded to the receiving network element according to the field information encapsulated in the outer message. Step 6, the receiving network element sets channel 1, channel 2, to channel n to the same selective receiving group to enable selective receiving and weight checking; Step 7, the selective receiving group members of the receiving network element parse the received message. If the message carries a double-send protection mark, the traffic uniqueness identifier is parsed and recorded to form a redundant filtering and duplication detection table. The selective receiving group members parse the traffic uniqueness identifier of the message received and check whether there are records in the redundant filtering and duplication detection table. If there are no records in the redundant duplication detection and filtering table, it means that the message is received for the first time and it is forwarded and processed normally. If there are records, it means that the same message has been received and the current message is a redundant message and the message is discarded.
2. The dual-transmission redundancy method based on traffic mirroring according to claim 1 is characterized in that: The step 2 specifically includes: if multiple business flows or flows accessing multiple destination network elements are forwarded on channel 1, double-transmission protection is enabled for specific flows, and the access control list ACL is used to filter out the required flows to enable double-transmission protection for the specific flows.
3. A computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor is caused to perform the steps of the method according to any one of claims 1 to 2.
Citation Information
Patent Citations
Fully redundant architecture storage system
CN107846306A
Dynamic multipath optimization method, system and equipment based on cloud network fusion technology
CN113438164A