A method and network device for eth-lm detection

By selecting a target chip in a distributed network device and aggregating the count values ​​of each chip for ETH-LM detection, the problems of inaccurate measurement and low precision in distributed device networking are solved, and high-precision packet loss detection is achieved.

CN118677813BActive Publication Date: 2026-05-05NEW H3C TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NEW H3C TECH CO LTD
Filing Date
2024-05-29
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

In distributed device networking, the existing single-end ETH-LM detection cannot accurately measure the packet loss rate on the load-sharing path, and its accuracy is not high, making it difficult to deploy in the live network.

Method used

By selecting the target chip, the count values ​​of the transmitted and received target service packets are obtained from the service boards of the local network equipment and other service boards. These count values ​​are then summarized into a total value and filled into the packet before being sent to the detection platform for ETH-LM detection.

Benefits of technology

It achieves high-precision ETH-LM detection in distributed device load-sharing scenarios, solving the problems of inaccurate measurement and low accuracy, and is suitable for distributed network devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118677813B_ABST
    Figure CN118677813B_ABST
Patent Text Reader

Abstract

The specification provides a method and network device for ETH-LM detection, the method comprising: a main control board of a local network device selecting a target chip from a service board, the target chip obtaining first counting values of transceiving target service packets from other chips of the local service board and / or chips in other service boards, obtaining a total counting value according to the first counting values and a second counting value of the target chip sending the target service packets, filling the total counting value into a first packet and sending to a detection platform, so that the detection platform performs ETH-LM detection according to the total counting value. Through the method, ETH-LM detection can be realized in distributed device networking.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification relates to the field of communication technology, and in particular to a method and network device for ETH-LM detection. Background Technology

[0002] In single-ended ETH-LM (Ethernet Frame Loss Measurement) detection, when device A sends an LMM message, it obtains the TxFCf and RxFCf counts on the device. Device B responds with an LMR message and obtains the TxFCb and RxFCl counts on the device. Finally, the packet loss rate at the source device A is calculated for the far end and the near end. Since all the counts are taken from the data forwarding messages on the device and do not depend on the number of protocol messages, this packet loss detection has high accuracy and low CPU usage.

[0003] In distributed device networking, load balancing often occurs between devices, which can be achieved through routing equivalence, link aggregation, or a combination of both. However, for distributed devices, the statistics of data packets are often based on the chip level. Therefore, it is difficult for device A or device B to obtain the sum of statistical counts on different chips, which greatly limits the application of single-end ETH-LM detection function and makes it impossible to deploy in the live network. Summary of the Invention

[0004] To overcome the problems existing in related technologies, this specification provides a method and network device for ETH-LM detection.

[0005] According to a first aspect of the embodiments of this specification, a method for ETH-LM detection is provided, the method comprising:

[0006] The main control board of the local network device selects the target chip from the service board;

[0007] The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and obtains a total value based on each first count value and the second count value of the target chip sending target service messages;

[0008] The total value is filled into the first message and sent to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0009] The main control board of the local network device selects the target chip from the service board, including:

[0010] Select the target business board according to the slot number of the business board in the order or in reverse order, and determine the target chip according to the chip number in the target business board in the order or in reverse order.

[0011] Wherein, after the main control board of the local network device selects the target chip from the service board, the method includes:

[0012] The target chip maintains a corresponding bitmap based on the detection instance, and the bitmap includes chip identifiers for all target services that are transmitted and received.

[0013] The target chip obtains the first count values ​​for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, including:

[0014] The target chip traverses the bitmap to obtain the chip identifiers of other chips in the bitmap besides the target chip;

[0015] A first request message to obtain a first count value is sent based on the chip identifier of other chips;

[0016] Receive a first response message sent by other chips in accordance with a first request message, wherein the first response message carries a first count value;

[0017] Iterate through each first response message to obtain the first count value.

[0018] The target chip obtains the first count values ​​for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, including:

[0019] The local network device uses the CPU control channel to obtain the first count value of the chip on the relevant slot service board through the slot where the specified chip is located.

[0020] The step of filling the total value into the first message and sending it to the detection platform includes:

[0021] Fill the count value of the target service message sent in the total value into the TxFCf field of the first message, and fill the count value of the target service message received in the total value into the RxFCf field of the first message;

[0022] The first message, filled with the TxFCf and RxFCf fields, is sent to the detection platform.

[0023] As can be seen from the above method, by selecting a target chip and collecting the count values ​​of the target service messages sent and received by other chips through the target chip, and then sending the total value to the detection platform, ETH-LM detection can be achieved in a scenario of distributed device load sharing.

[0024] According to a second aspect of the embodiments of this specification, a network device is provided, the network device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the following method:

[0025] The main control board of the local network device selects the target chip from the service board;

[0026] The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and obtains a total value based on each first count value and the second count value of the target chip sending target service messages;

[0027] The total value is filled into the first message and sent to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0028] According to a third aspect of the embodiments of this specification, a network device is provided, the network device comprising:

[0029] The selection module is used by the main control board to select the target chip from the service board.

[0030] The acquisition module is used for the target chip to acquire each first count value of sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and to obtain a total value based on each first count value and the second count value of the target chip sending target service messages;

[0031] The sending module is used to fill the total value into the first message and send it to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0032] Specifically, the selection module is used to select and determine the target service board according to the slot number sequence or reverse sequence corresponding to the service board, and to determine the target chip according to the chip number sequence or reverse sequence in the target service board.

[0033] Specifically, the sending module is used to fill the count value of the target service message sent in the total value into the TxFCf field of the first message, and to fill the count value of the target service message received in the total value into the RxFCf field of the first message;

[0034] The first message, filled with the TxFCf and RxFCf fields, is sent to the detection platform.

[0035] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this specification. Attached Figure Description

[0036] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this specification and, together with the description, serve to explain the principles of this specification.

[0037] Figure 1 This is a flowchart illustrating an ETH-LM detection method according to an exemplary embodiment of this specification.

[0038] Figure 2 This is a schematic diagram of a detection cycle illustrated in this specification according to an exemplary embodiment. Detailed Implementation

[0039] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this specification. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this specification as detailed in the appended claims.

[0040] The terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to be limiting of this specification. The singular forms “a,” “the,” and “the” as used in this specification and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.

[0041] It should be understood that although the terms first, second, third, etc., may be used in this specification to describe various information, this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, without departing from the scope of this specification, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to determination."

[0042] Currently, ETH-LM faces the following challenges in distributed device networking:

[0043] 1. Measurement inaccuracy occurs when the measurement path is load-sharing.

[0044] When the measurement path has route equivalence or aggregation paths, data traffic is load-balanced along the path by calculating hash values ​​using IP addresses, MAC addresses, and Layer 4 port numbers. Data traffic is random, and the load distribution along the measurement path can change at any time. Single-end ETH-SLM detection of protocol frames struggles to adjust frame forwarding based on these load changes. If data frames experience packet loss on a path, but protocol frames do not follow that path, or if the number of protocol frames and data packets on a path does not match, inaccurate measurements will result.

[0045] 2. Indirect measurement, low accuracy.

[0046] According to the results of ITU-T Y.1731 on the accuracy of single-ended ETH-SLM testing, it was found that the faster the protocol messages are sent, the lower the actual packet loss rate, and the closer the measurement results are to the true packet loss rate. When the actual packet loss rate is 50%, even if 1000 protocol frames are sent per second, there is still a deviation of 1.58%, which is low accuracy. Moreover, to achieve this level of accuracy, a large number of protocol frames need to be sent. In the case of load-sharing test paths, the number of protocol frames required is even greater. The requirements are high for both the device's ability to send protocol frames and the load consumption on the link. However, the measurement accuracy is not only limited but also affected by the actual packet loss rate, making it difficult to guarantee.

[0047] To achieve high-precision ETH-LM detection in distributed device networking, this disclosure provides a method for ETH-LM detection, which is applied to local network devices, such as... Figure 1 As shown, the method includes:

[0048] The main control board of the S101 local network device selects the target chip from the service board;

[0049] S102 The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips in other service boards, and obtains a total value based on each first count value and the second count value of the target chip sending target service messages;

[0050] S103 fills the total value into the first message and sends it to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0051] In this embodiment, the local network device can be any of the distributed network devices, and the peer network device is relative to the local network device. The local network device can be device A, and the peer network device can be device B.

[0052] In step S101, device A can select a target chip from service boards via the main control board. In one example, when the main control board determines each service board that forwards the target packet and selects a target chip from each service board, it can select the target service board in the order or reverse order of the slot numbers corresponding to the service boards. For example, the service board with the smaller slot number can be selected as the target service board, or the service board with the larger slot number can be selected as the target service board, and then the target chip can be selected from the target service board. When selecting the target chip, it can also be selected in the order or reverse order of the chip number. This example does not limit this.

[0053] In this embodiment, each chip in the device counts the number of detected service packets (target service packets) on each chip, including the TX and RX directions. In this embodiment, the target chip obtains the first count values ​​of other chips on the service board that transmit and receive target service packets from the inter-board lines of the service board it is on. Assuming that chip0 in device A is the target chip, and chip1 and chip2 are other chips on the target service board where chip0 is located, chip0 obtains the first count values ​​of chip1 and chip2 that transmit and receive target service packets through the inter-board lines.

[0054] Meanwhile, if there are other service boards in device A, chip0 on the target service board can obtain the first statistical value of the target service messages sent and received by each chip on the other service boards through the inter-board data channel of the service board.

[0055] In another example, the local network device can use the CPU control channel to obtain the first count value of the chip on the relevant slot service board through the slot where the specified chip is located. That is, the count can also be obtained through inter-board communication via the CPU control channel for the slot where the specified chip is located.

[0056] chip0 obtains the first count values ​​of each of the other chips (including chips in other boards) for sending and receiving target service messages, and accumulates the second count values ​​of sending and receiving target service messages on chip0 to obtain a total value.

[0057] Taking the ETH-LM initiator device as an example, the main control board selects a chip on an interface board to perform LMM message transmission. This chip needs to collect the TX statistics of the tested service on all paths on the device and add them to the LM TX statistics of the sending chip. After the count is summarized, the LM TX statistics are filled into the TxFCf field, the LMM message is sent, and then the LM TX statistics are synchronized to other chips.

[0058] When the initiating device receives an LMR response message from the connected device, the receiving chip needs to collect the RX statistics counts for all paths of the service and add them to the RX statistics of the LM chip. After the counts are summarized, the RX statistics of the LM chip are filled into the RxFCl field, and the message is sent to the platform to calculate the packet loss rate of the near end and the far end.

[0059] When the docking device receives the LMM message and responds with the LMR message, the processing procedure is the same as that of the initiating device, and will not be described in detail here.

[0060] like Figure 2 The diagram illustrates a detection cycle. To achieve high-precision detection, the time interval between TC3 and TP3 needs to be as close as possible to the detection cycle T between TC0 and TP0. If the time offsets for packet transmission, packet reception, and RX count reading are fixed (TC3-TP3 = TC0-TP0), then in reality, a jitter will always exist. To reduce this jitter, TP1-TP0 and TP3-TP2 need to be sufficiently small, while TP2-TP1 represents the link transmission delay, which is relatively fixed and does not need to be considered. Similarly, for the collection of TX and RX counts, the timing of the read counts on each chip also needs to be as close as possible.

[0061] Meanwhile, in the distributed network device, each chip has a mod number for cross-board and cross-chip forwarding. Taking the sending end as an example, the detected path exit is parsed and contains three chips: chip0, chip1, and chip2, which correspond to mod0, mod1, and mod2 respectively. Chip0 is designated as the chip for counting collection, responsible for collecting LMM TxFCf counts and sending LMM messages. Chip1 and chip2 are responsible for collecting LMM TxFCf counts for their respective chips and responding to chip0.

[0062] Each detection instance of chip0 maintains a corresponding bitmap Sendbitmap, containing mod0, mod1, and mod2. Upon receiving an LMM message transmission request from the main control board, the chip iterates through the Sendbitmap and sends the first request message. The format may include: internal header (containing dmod + smod) + Dmac (peer device bridge MAC) + Smac (local device bridge MAC) + 0x8902 (cfd protocol number) + LM_STAT PDU, as detailed below:

[0063]

[0064] Among them, MEL: MEG level.

[0065] Version: Version number, 0.

[0066] Opcode: PDU type (tentatively Lmst = 60).

[0067] Flags: Defined as follows:

[0068]

[0069] Op-type 1: request.

[0070] Op-type 2: answer.

[0071] Lm_stat_offset: The offset of the statistics counter for each detected instance.

[0072] service_stat_offset: The offset of the statistics counter for the monitored service.

[0073] stat_value: Counter count.

[0074] Receive a first response message sent by other chips in accordance with a first request message, wherein the first response message carries a first count value;

[0075] Iterate through each first response message to obtain the first count value.

[0076] For example, when mod0, mod1, and mod2 receive a request message, they read the count corresponding to service_stat_offset on their chip, fill it into stat_value, change the mod of the source and destination, and respond with an answer message.

[0077] When chip0 receives the answer message, it obtains the stat_value, adds it to the counter corresponding to Lm_stat_offset, and sets the mod corresponding to receivebitmap.

[0078] When the receivebitmap and sendbitmap of chip0 are the same, LMM message transmission is triggered. TxFCf is taken from the Lm_stat_offset counter. The receivebitmap is cleared after transmission is completed.

[0079] The peer network device (receiving end) receives LM messages using a designated chip. This chip collects RxFCf or RxFCl counts, and the implementation method is the same as that of the sending end. This example will not repeat the details.

[0080] As can be seen from the examples above, in the architecture of a distributed network, all count statistics of the transmission and reception of target service messages can be collected by specifying a target chip to achieve ETH-LM detection, thereby achieving high-precision packet loss detection.

[0081] Based on the above method embodiments, this disclosure also provides a network device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the following method:

[0082] The main control board of the local network device selects the target chip from the service board;

[0083] The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and obtains a total value based on each first count value and the second count value of the target chip sending target service messages;

[0084] The total value is filled into the first message and sent to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0085] This disclosure also provides a network device, the network device comprising:

[0086] The selection module is used by the main control board to select the target chip from the service board.

[0087] The acquisition module is used for the target chip to acquire each first count value of sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and to obtain a total value based on each first count value and the second count value of the target chip sending target service messages;

[0088] The sending module is used to fill the total value into the first message and send it to the detection platform so that the detection platform can perform ETH-LM detection based on the total value.

[0089] Specifically, the selection module is used to select and determine the target service board according to the slot number sequence or reverse sequence corresponding to the service board, and to determine the target chip according to the chip number sequence or reverse sequence in the target service board.

[0090] Specifically, the sending module is used to fill the count value of the target service message sent in the total value into the TxFCf field of the first message, and to fill the count value of the target service message received in the total value into the RxFCf field of the first message;

[0091] The first message, filled with the TxFCf and RxFCf fields, is sent to the detection platform.

[0092] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to in the description of the method embodiments. The device embodiments described above are merely illustrative. The modules described as separate components may or may not be physically separate, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of the solution in this specification according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0093] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.

[0094] Other embodiments of this specification will readily occur to those skilled in the art upon consideration of the specification and practice of the invention claimed herein. This specification is intended to cover any variations, uses, or adaptations that follow the general principles of this specification and include common knowledge or customary techniques in the art not claimed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this specification are indicated by the following claims.

[0095] It should be understood that this specification is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this specification is limited only by the appended claims.

[0096] The above description is merely a preferred embodiment of this specification and is not intended to limit this specification. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of protection of this specification.

Claims

1. A method for ETH-LM detection, characterized in that, The method is applied in the local network device, and the method includes: The main control board of the local network device selects the target chip from the service board; The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and adds each first count value to the second count value for sending and receiving target service messages to obtain a total value. The total value is filled into the first message and sent to the detection platform so that the detection platform can perform ETH-LM detection based on the total value; The step of filling the total value into the first message and sending it to the detection platform includes: Fill the first message with the count value of the target service message sent from the total value, and fill the first message with the count value of the target service message received from the total value. The first message is sent to the detection platform.

2. The method according to claim 1, characterized in that, The main control board of the local network device selects the target chip from the service board, including: Select the target business board according to the slot number of the business board in the order or in reverse order, and determine the target chip according to the chip number in the target business board in the order or in reverse order.

3. The method according to claim 1, characterized in that, After the main control board of the local network device selects the target chip from the service board, the method includes: The target chip maintains a corresponding bitmap based on the detection instance, and the bitmap includes chip identifiers for all target services that are transmitted and received.

4. The method according to claim 3, characterized in that, The target chip obtains the first count values ​​for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, including: The target chip traverses the bitmap to obtain the chip identifiers of other chips in the bitmap besides the target chip; A first request message to obtain a first count value is sent based on the chip identifier of other chips; Receive a first response message sent by other chips in accordance with a first request message, wherein the first response message carries a first count value; Iterate through each first response message to obtain the first count value.

5. The method according to claim 1, characterized in that, The target chip obtains the first count values ​​for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, including: The local network device uses the CPU control channel to obtain the first count value of the chip on the relevant slot service board through the slot where the specified chip is located.

6. The method according to claim 1, characterized in that, The step of filling the total value into the first message and sending it to the detection platform includes: Fill the count value of the target service message sent in the total value into the TxFCf field of the first message, and fill the count value of the target service message received in the total value into the RxFCf field of the first message; The first message, filled with the TxFCf and RxFCf fields, is sent to the detection platform.

7. A network device, characterized in that, The network device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements the following method: The main control board of the local network device selects the target chip from the service board; The target chip obtains each first count value for sending and receiving target service messages from other chips on this service board and / or chips on other service boards, and adds each first count value to the second count value for sending and receiving target service messages to obtain a total value. The total value is filled into the first message and sent to the detection platform so that the detection platform can perform ETH-LM detection based on the total value; The step of filling the total value into the first message and sending it to the detection platform includes: Fill the first message with the count value of the target service message sent from the total value, and fill the first message with the count value of the target service message received from the total value. The first message is sent to the detection platform.

8. A network device, characterized in that, The network device includes: The selection module is used by the main control board to select the target chip from the service board. The acquisition module is used to acquire the first count values ​​of receiving and sending target service messages from other chips on this service board and / or chips on other service boards, and to accumulate the first count values ​​with the second count values ​​of receiving and sending target service messages to obtain a total value. The sending module is used to fill the total value into the first message and send it to the detection platform so that the detection platform can perform ETH-LM detection based on the total value. Wherein, filling the total value into the first message and sending it to the detection platform includes: Fill the first message with the count value of the target service message sent from the total value, and fill the first message with the count value of the target service message received from the total value. The first message is sent to the detection platform.

9. The network device according to claim 8, characterized in that, The selection module is specifically used to select and determine the target service board according to the slot number order or reverse order of the service board, and to determine the target chip according to the chip number order or reverse order of the target service board.

10. The network device according to claim 8, characterized in that, The sending module is specifically used to fill the count value of the target service message sent in the total value into the TxFCf field of the first message, and to fill the count value of the target service message received in the total value into the RxFCf field of the first message; The first message, filled with the TxFCf and RxFCf fields, is sent to the detection platform.

Citation Information

Patent Citations

  • Loss measuring in link aggregation group

    CN103259692A

  • Service packet loss rate measuring method based on port or LSP in distributed architecture

    CN104270284A