Ethernet active-standby link consistency identification lossless switching method and device
Patent Information
- Application Number
- CN202610892507.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-19
- Publication Date
- 2026-09-29
- Estimated Expiration
- 2046-06-19
AI Technical Summary
(1)通过在每个对齐标记的紧邻后置位置插入携带一致性标识的扩展编码块,接收端无需依赖上层协议或链路状态信息,即可在物理编码子层直接识别主备链路数据的逻辑对应关系,彻底避免了传统盲切导致的错误,大幅提升了多备路场景下链路选择的准确性与可靠性;
Smart Images

Figure CN122420094B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of high-speed interface communication technology, specifically to a method and apparatus for lossless switching of Ethernet primary and backup link consistency identification. Background Technology
[0002] In the field of high-speed Ethernet communication, physical layer coding technology based on the IEEE 802.3 standard is widely used. To meet the ever-increasing demand for data transmission rates, multi-channel parallel transmission architecture has become a standard configuration, in which data is encapsulated and processed in the Physical Coding Sublayer (PCS) using 64b / 66b encoding.
[0003] In order for the receiver to correctly recover data from multiple parallel channels, alignment markers (AMs) are usually inserted periodically into the encoded data stream to indicate the phase relationship between the data in the channels, thereby achieving the alignment and reassembly of multi-channel data.
[0004] In applications with high reliability requirements, such as data center interconnects or high-performance computing systems, primary and backup links are typically configured to improve link availability. In a common configuration, the sender transmits the same data on both the primary and backup links, making the backup link logically hot-standby so it can quickly take over services in the event of a failure on the primary link. In such systems, the receiver usually determines when and which backup link to switch to based on link quality monitoring information or pre-configured priority policies.
[0005] Therefore, the aforementioned multi-channel parallel transmission architecture and primary / backup link hot standby mechanism together constitute the mainstream technical implementation method for high-speed Ethernet high-reliability data transmission. Summary of the Invention
[0006] To alleviate or partially alleviate the above-mentioned technical problems, the solution of the present invention is as follows: On one hand, this invention discloses a lossless switching method for Ethernet primary / backup link consistency identification, comprising: The sending end inserts an extended coding block immediately following each alignment mark. The extended coding block carries a consistency identifier that characterizes the logical identity of the data stream. Furthermore, the consistency identifier is the same for the primary link and the backup link that carry the same data content. The receiving end receives data from the primary link and the backup link, parses the extended coding block to obtain the consistency identifier, and identifies the target backup link that is consistent with the data of the primary link by comparing the consistency identifier; When the primary link fails, the receiving end switches the data output path from the primary link to the target backup link at the next alignment mark boundary.
[0007] In one embodiment, the extended coding block adopts a control block format compatible with the 64b / 66b coding system, without changing the original coding block structure, transmission rate, and frame interval.
[0008] In one embodiment, the consistency identifier is generated in a manner that can characterize the logical identity of the data flow.
[0009] In one embodiment, the consistency identifier generation method includes at least one of the following: The system uses pre-configured fixed encoding; Encoding dynamically generated based on data frame sequence number; Path labels are uniformly assigned by the sending end.
[0010] In one embodiment, the comparison of the consistency identifier includes at least one of the following matching patterns: Single-point periodic matching mode: directly compare whether the consistency identifiers of the primary and backup links are completely consistent within the same alignment mark period; Continuous multi-cycle window matching mode: The matching results of multiple adjacent alignment mark cycles are combined for a comprehensive judgment; Fault-tolerant error matching mode: Allows for a small number of bit transmission errors while still determining that the identifier matches.
[0011] In one embodiment, the extended coding block is further provided with a verification field for verifying the consistency identifier; When the verification fails, discard the identifier comparison result of the current cycle and wait for the next alignment mark cycle to re-parse and match.
[0012] In one embodiment, when there are at least two backup links, the receiving end automatically identifies the target backup link that is consistent with the primary link data by comparing the consistency identifier.
[0013] On the other hand, this invention discloses a lossless switching device for Ethernet primary / backup link consistency identification, comprising a transmitter and a receiver, wherein the transmitter includes: The alignment mark insertion and management module is used to periodically insert alignment marks into the data stream; An extended coding block generation module is used to insert an extended coding block at the immediate following position of each alignment mark. The extended coding block carries a consistency identifier representing the logical identity of the data stream. Specifically, for primary and backup links carrying the same data content, the inserted extended coding blocks carry identical consistency identifiers. The receiving end includes: An extended coding parsing module is used to parse the extended coding block located after the alignment mark to obtain the consistency identifier; The consistency identification module is used to identify the target backup link that is consistent with the primary link data by comparing the consistency identifier; The switching control module is used to switch the data output path from the primary link to the target backup link at the next alignment mark boundary when the primary link fails.
[0014] In one embodiment, the extended coding block generated by the extended coding block generation module adopts a control block format compatible with the existing 64b / 66b coding system, without changing the original coding block structure, transmission rate and frame interval.
[0015] In one embodiment, the extended coding block is provided with a verification field; the consistency identification module is connected to the extended coding parsing module and is used to verify the consistency identifier according to the verification field, and to trigger the extended coding parsing module to wait for the next alignment mark cycle to re-parse when the verification fails.
[0016] The technical solution of the present invention has one or more of the following beneficial technical effects: (1) By inserting an extended coding block carrying a consistency identifier at the immediate post position of each alignment mark, the receiver can directly identify the logical correspondence between primary and backup link data at the physical coding sublayer without relying on upper layer protocols or link state information, thus completely avoiding errors caused by traditional blind switching and greatly improving the accuracy and reliability of link selection in multi-backup scenarios. (2) By strictly limiting the link switching action to the natural coding boundary of the alignment mark, the structural integrity of the coding block can be completely preserved, effectively avoiding problems such as coding block fragmentation, FEC decoding window misalignment, and data jump, duplication or loss during the switching process, and realizing lossless switching of the physical coding layer boundary; (3) By reusing the existing 64b / 66b encoding system and alignment mark mechanism, the extended coding block adopts the standard control block format, without changing the original protocol framework and hardware transmission mechanism, and can be directly integrated into the existing Ethernet physical layer chip. At the same time, the extended coding block can have a built-in CRC check field to further improve the error resistance of the identification transmission. (4) The consistency identifier can be flexibly configured and is strictly synchronized with the alignment mark period. This solution can be extended to multiple backup link networking scenarios. The receiving end can automatically identify the data ownership of each backup link by identifier comparison. There is no need to manually pre-configure the primary and backup mapping relationship, which greatly reduces the operation and maintenance complexity of large-scale networking.
[0017] Furthermore, other beneficial effects of the present invention will be mentioned in the specific embodiments. Attached Figure Description
[0018] Figure 1 This is a schematic diagram of the device structure of one embodiment of the present invention; Figure 2 This is a flowchart illustrating one embodiment of the present invention. Detailed Implementation
[0019] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.
[0020] To facilitate a clear description of the technical solutions in the embodiments of the present invention, the terms "first" and "second" are used to distinguish identical or similar items with essentially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order.
[0021] The term "extended coding block" refers to a newly defined 66-bit coding block based on the existing 64-bit / 66-bit coding system. It adopts the same format as the standard control block and is fixedly positioned immediately after each alignment mark, with no other coding blocks between it and the alignment mark. The payload of this extended coding block carries a consistency identifier, used to provide the receiving end with a basis for identifying the logical ownership of the data stream.
[0022] The term "consistency identifier" refers to a segment of bit information embedded in the payload of the extended coding block, used to uniquely identify the logical ownership of the current data stream. For primary and backup links carrying the same data content, the sending end inserts the exact same identifier into its extended coding block, enabling the receiving end to determine whether the data from different links originates from the same logical data stream by comparing the identifiers.
[0023] The term "alignment mark boundary" refers to the natural start or end position of the 66b coded block corresponding to the alignment mark, which is the inherent dividing point between coded blocks. This invention strictly limits the primary / backup link switching operation to this boundary to ensure that the switching process does not damage the structural integrity of any coded block and avoids data misalignment or loss.
[0024] The term "immediately following position" refers to a specific positional relationship in this invention where the extended coding block is directly located after the alignment mark, and there are no other coding blocks between them. This positional relationship provides the extended coding block with a fixed and predictable positioning reference, allowing the receiving end to quickly locate and parse the extended coding block using the positioning function of the alignment mark, without the need for blind searching of the entire data stream.
[0025] Through investigation and research, the inventors discovered that in existing multi-channel parallel transmission architectures and primary / backup hot standby mechanisms, although the primary and backup paths transmit the same data content, the data streams processed by the receiving end at the Physical Coding Sublayer (PCS) consist of standard 66-bit coded block sequences. These coded block sequences are structurally identical, and the alignment markers in existing coding systems are only used to indicate the phase relationship between channels, without carrying information that can distinguish data sources or reflect the data correspondence between different links. Therefore, when the receiving end needs to select one of multiple backup paths for switching, it cannot determine which backup path's data is logically consistent with the current primary path's data by parsing the content of the coded blocks themselves. Furthermore, due to potential transmission delay differences between different links, even if the same data stream is transmitted on the primary and backup paths, its presentation time and position at the receiving end may deviate, further increasing the complexity of direct data comparison at the coding layer. The aforementioned problem—how to identify the data consistency relationship between the primary and backup paths at the coding layer, thereby providing an accurate basis for high-reliability switching—is the starting point for the inventors' thinking and proposed solution.
[0026] This invention discloses a lossless switching method and apparatus for Ethernet primary and backup link consistency identification. While retaining the existing 64b / 66b encoding system and multi-channel parallel transmission architecture, this invention adds an extended coding block (66b) and embeds a consistency identifier at a fixed position on the Alignment Marker (AM). This allows the receiving end to directly identify the logical correspondence of data streams between primary and backup links at the physical coding sublayer and complete link switching based on the alignment mark boundary. This invention is applicable to 40Gbps / 100Gbps high-speed Ethernet communication scenarios conforming to the IEEE 802.3 standard.
[0027] Figure 1This is a schematic diagram of a device structure according to one embodiment of the present invention. As shown in the figure, the high-speed Ethernet communication system used in this invention includes at least two interconnected communication devices, with a primary link and at least one backup link deployed between the devices to form a primary and backup transmission path. Each communication device integrates functional modules that implement the scheme of this invention. Specifically, at the transmitting end, the present invention mainly includes an alignment mark insertion and management module and an extended coding block generation module; at the receiving end, it mainly includes an extended coding parsing module, a consistency identification module, and a handover control module. All functional modules are integrated within the Ethernet physical coding sublayer, without requiring modification of the media access control layer and higher-level protocols, possessing strong protocol compatibility and hardware adaptability, and can be directly integrated into existing Ethernet physical layer chips without any modification to the upper-layer software of the system.
[0028] It should be noted that the present invention does not exclude the presence of other conventional Ethernet physical layer modules in the system, such as an encoding module for performing 64b / 66b encoding, a multi-link transmission module (located at the transmitting end) for performing data distribution and physical channel transmission, and a decoding alignment module (located at the receiving end) for performing optical signal reception and physical layer alignment, etc. Figure 2 The purpose is to highlight the modules that realize the core innovative mechanism of the present invention and their connection relationships, rather than limiting the device of the present invention to include only the modules shown in the figure.
[0029] Figure 2 This is a flowchart illustrating one embodiment of the present invention. As shown in the figure, in a specific embodiment of the present invention, the method of implementation is as follows: At the transmitting end, the data first undergoes conventional 64b / 66b encoding to form a sequence of encoded blocks. This sequence then enters the alignment mark insertion and management module. This module, following the IEEE 802.3 standard, periodically inserts alignment marks (AMs) into the data stream. While retaining all the original functions of periodic alignment mark insertion, multi-channel distribution, and timing alignment, this invention, while the alignment mark insertion module performs alignment mark insertion, has an extended encoded block generation module that, according to fixed encoded block embedding rules, inserts an extended encoded block conforming to the 64b / 66b standard control block format immediately following each alignment mark. This extended encoded block fully reuses the control block frame structure defined by existing protocols, requiring no modification to the encoding format, transmission rate, or frame interval. It can be directly decoded by existing Ethernet hardware without adding extra system transmission overhead or disrupting the regularity of the original 66b encoded blocks. The payload field of the extended encoded block contains a preset Consistency ID, which uniquely identifies the logical ownership of the current data stream, thus establishing the basis for data association between different links.
[0030] It is particularly important to note that this invention specifically limits the insertion of the extended coding block to the position immediately following the alignment mark. This is crucial for achieving compatibility with the 64b / 66b encoding system without modifying the existing protocol (IEEE 802.3 protocol). Only when adjacent to the alignment mark can the extended coding block utilize the alignment mark as a natural positioning reference, allowing the receiving end to directly lock and parse it without altering the existing decoding logic. Furthermore, according to the 64b / 66b encoding standard, the alignment mark, as a periodically inserted dedicated control block, has its position immediately following the alignment mark as a standard-reserved control block extension bit, unoccupied by any service data or standard control information. Inserting the extended coding block at this position does not disrupt the continuous arrangement of the original 66b coding blocks, does not change the standard-specified coding block period and frame structure, and does not affect the normal decoding process of existing Ethernet physical layer chips for standard data blocks and control blocks. If the extended coding block is inserted into a non-adjacent position after the alignment mark, it will disrupt the continuous sequence of the original service data blocks, requiring modification of the decoding logic and data reassembly rules at the receiving end, and making it impossible to achieve seamless compatibility with existing protocols and hardware.
[0031] Consistency identifiers can be generated in several feasible ways: for example, fixed codes pre-configured by the system, codes dynamically generated based on data frame sequence numbers, or dedicated path labels uniformly allocated by the sender. For the primary / standby hot standby working mode, the sender inserts an extended coding block carrying the exact same consistency identifier at the same alignment mark period position on the primary link and the corresponding standby link. Links carrying unrelated service data flows are configured with differentiated consistency identifiers, ensuring that the primary and standby links form a uniquely identifiable data association feature at the coding layer.
[0032] After the alignment markers and extended coding block embedding are completed, the complete coding block sequence is distributed to multiple physical transmission channels according to preset rules. Finally, after the electrical signal to optical signal is converted between each other by an optical transceiver, it is transmitted synchronously on the primary link and the backup link. The entire data processing flow at the transmitting end can be adapted to existing multi-channel parallel distribution, wavelength division multiplexing, or multi-fiber bundle transmission mechanisms, and is compatible with mainstream rate architectures such as 40Gbps four-channel parallel, 100Gbps ten-channel or twenty-channel parallel, without changing the original transmission path and timing characteristics of the service data.
[0033] At the receiving end, data undergoes optical-to-electrical conversion, channel alignment, and decoding via the system's decoding and alignment module before entering the extended coding parsing module. Since the extended coding block is fixedly positioned immediately following each alignment marker, the receiving end can accurately locate the extended coding block using the alignment markers as a positioning reference. This eliminates the need for blind searching the entire data stream, allowing for rapid capture of the extended coding block and significantly reducing parsing latency and hardware implementation complexity. The extended coding parsing module then parses the locked extended coding block, extracting the consistency identifier carried within it.
[0034] The consistency identification module synchronously collects the consistency identifiers parsed from the primary link and all backup links within the same alignment mark period, and performs identifier comparison and verification according to preset matching logic. Specifically, it can adopt single-point periodic matching, continuous multi-period window matching, or fault-tolerant error matching mode: Single-point periodic matching directly compares whether the consistency identifiers of the primary and backup links are completely consistent within the same alignment mark period; continuous multi-period window matching makes a comprehensive judgment by accumulating the matching results of multiple adjacent alignment mark periods, effectively avoiding misjudgments caused by instantaneous interference; fault-tolerant error matching allows the identifier to still be judged to match even with a small number of bit transmission errors, adapting to minor bit error scenarios in actual link transmission.
[0035] By comparing consistency identifiers across links, the receiving end can accurately distinguish the logical affiliation of the data streams carried by each backup link, and quickly select the optimal backup link that is completely matched with the main data stream and is time-aligned, thus making up for the shortcomings of existing technologies that can only switch based on the physical state of the link and cannot identify the consistency of data content.
[0036] When the receiving end detects abnormal operating states such as physical link failure, bit error rate exceeding the system preset threshold, or alignment mark loss, the system triggers a link switching mechanism. The switching control module does not immediately execute the link switching operation, but waits until the coding boundary position of the next alignment mark. Only at the coding block boundary node corresponding to the alignment mark is the service data output path smoothly switched from the primary link to the backup link that has successfully matched the consistency identification. This invention strictly limits the switching action to the natural coding boundary of the alignment mark, which can completely preserve the structural integrity of the 66b coding block and avoid problems such as coding block fragmentation, forward error correction (FEC) decoding window misalignment, data jumps, duplication, or loss caused by switching at non-coding boundaries, achieving truly lossless switching at the physical coding layer boundary.
[0037] In another implementation, to further improve the reliability of consistency identifier transmission and identification, a Cyclic Redundancy Check (CRC) field can be added inside the extended coding block. The CRC check logic is used to verify the bit information of the consistency identifier. If a transmission bit error is detected, causing the consistency identifier to fail, the identifier comparison result of the current period is discarded, and the system silently waits for the next alignment mark period to re-complete the extended coding block parsing and identifier matching, avoiding erroneous link switching decisions caused by link errors. Simultaneously, the technical solution of this invention can be seamlessly extended to networking scenarios with three or more backup links. The sending end can configure mutually distinguishable consistency identifiers for different logical service data streams, and the receiving end can automatically identify the data ownership relationship of multiple backup paths through identifier comparison, without the need for manual pre-configuration of primary and backup link mapping rules. This adapts to the application requirements of multi-link redundant networking in large-scale data centers, high-performance clusters, and other applications.
[0038] In summary, this invention binds extended coding blocks to alignment markers at fixed positions and adds a cross-link data consistency identifier for extended coding blocks. This allows the alignment markers to simultaneously perform three core functions: multi-channel timing alignment, extended coding block positioning, and lossless handover boundary. Without altering the existing 64b / 66b coding system or adding additional protocol overhead, it achieves a technical upgrade from the traditional coarse-grained link-state switching to precise coding layer data consistency switching. This effectively solves the long-standing technical problems of unidentifiable data and poor handover stability in high-speed Ethernet primary / standby hot standby architectures.
[0039] To better illustrate the present invention, numerous specific details have been provided in the detailed embodiments described above. Those skilled in the art should understand that the present invention can be practiced even without certain specific details. In some instances, methods, means, components, and circuits well known to those skilled in the art have not been described in detail in order to highlight the main points of the present invention.
[0040] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the present invention should be included within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A method for lossless switching of Ethernet primary and backup links based on consistency identification, characterized in that, include: The sending end inserts an extended coding block at the position immediately following each alignment mark. The extended coding block carries a consistency identifier used to characterize the logical identity of the data stream. Furthermore, the consistency identifier is the same for primary and backup links carrying the same data content; The receiving end receives data from the primary link and the backup link, parses the extended coding block to obtain the consistency identifier, and identifies the target backup link that is consistent with the data of the primary link by comparing the consistency identifier; When the primary link fails, the receiving end switches the data output path from the primary link to the target backup link at the next alignment mark boundary. The extended coding block adopts a control block format compatible with the 64b / 66b coding system, without changing the original coding block structure, transmission rate and frame interval.
2. The Ethernet primary / backup link consistency identification and lossless switching method according to claim 1, characterized in that: The consistency identifier is generated in a way that can characterize the logical identity of the data flow.
3. The Ethernet primary / backup link consistency identification and lossless switching method according to claim 1, characterized in that, The consistency identifier generation method includes at least one of the following: The system uses pre-configured fixed encoding; dynamically generated encoding based on data frame sequence numbers; and path labels uniformly assigned by the sending end.
4. The Ethernet primary / backup link consistency identification and lossless switching method according to claim 1, characterized in that, The comparison of the consistency identifiers includes at least one of the following matching patterns: Single-point periodic matching mode: directly compare whether the consistency identifiers of the primary and backup links are completely consistent within the same alignment mark period; Continuous multi-cycle window matching mode: The matching results of multiple adjacent alignment mark cycles are combined for a comprehensive judgment; Fault-tolerant error matching mode: Allows for a small number of bit transmission errors while still determining that the identifier matches.
5. The Ethernet primary / backup link consistency identification and lossless switching method according to claim 1, characterized in that: The extended coding block also includes a verification field for verifying the consistency identifier; When the verification fails, discard the identifier comparison result of the current cycle and wait for the next alignment mark cycle to re-parse and match.
6. The Ethernet primary / backup link consistency identification and lossless switching method according to claim 1, characterized in that... : When there are at least two backup links, the receiving end automatically identifies the target backup link that is consistent with the primary link data by comparing the consistency identifier.
7. A lossless switching device for Ethernet primary / backup link consistency identification, characterized in that, It includes a sending end and a receiving end, wherein the sending end includes: The alignment mark insertion and management module is used to periodically insert alignment marks into the data stream; An extended coding block generation module is used to insert an extended coding block immediately following each alignment mark. The extended coding block carries a consistency identifier to characterize the logical identity of the data stream. For primary and backup links carrying the same data content, the inserted extended coding blocks carry identical consistency identifiers. The extended coding blocks adopt a control block format compatible with the 64b / 66b coding system, without changing the original coding block structure, transmission rate, or frame interval. The receiving end includes: An extended coding parsing module is used to parse the extended coding block located after the alignment mark to obtain the consistency identifier; The consistency identification module is used to identify the target backup link that is consistent with the primary link data by comparing the consistency identifier; The switching control module is used to switch the data output path from the primary link to the target backup link at the next alignment mark boundary when the primary link fails.
8. The Ethernet primary / backup link consistency identification and lossless switching device according to claim 7, characterized in that: The extended coding block is provided with a verification field; the consistency identification module is connected to the extended coding parsing module and is used to verify the consistency identifier according to the verification field, and to trigger the extended coding parsing module to wait for the next alignment mark cycle to re-parse when the verification fails.
Citation Information
Patent Citations
Flexible Ethernet overhead frame processing method and device
CN116746093A