Link sub-health detection method and device and electronic equipment

By adding a response identifier to the service packets of the active-active data center, the communication link status is initially detected and a detection packet is constructed for secondary detection, which solves the problems of bandwidth occupied by detection packets and missed and false positives in the existing technology. Improved the efficiency and accuracy of link sub-health detection.

CN118694685AActive Publication Date: 2024-09-24XINHUASAN INFORMATION TECH CO LTD

Patent Information

Application Number
CN202410853180.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-27
Publication Date
2024-09-24
Estimated Expiration
2044-06-27

AI Technical Summary

Technical Problem

In an active-active data center environment, existing network sub-health detection methods occupy network bandwidth through a large number of detection packets, affecting normal business packet processing, and can easily lead to false positives and false positives in network sub-health problems in complex architecture networking environments.

Method used

By adding a response identifier to the service message, the status of the communication link is determined based on the service message and response message within the specified time period. After the initial detection of the suspected sub-health state, a detection message is constructed for secondary detection to avoid additional detection reports. The text takes up bandwidth and improves detection accuracy.

Benefits of technology

It improves the efficiency and accuracy of link sub-health detection, avoids detection packets from occupying network bandwidth, reduces resource consumption, and accurately identifies and handles network sub-health events in complex networking environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118694685A
    Figure CN118694685A
Patent Text Reader

Abstract

The embodiment of the invention provides a link sub-health detection method and device and electronic equipment. In the embodiment of the invention, aiming at a communication link corresponding to a main network port on a node, the state of the communication link is firstly detected for the first time according to each service message sent by the node through the communication link and a response message of each service message in a specified time period; therefore, the sub-health detection of the link does not need to be carried out through an additional detection message during the primary detection, the condition that the normal service message processing is influenced due to the fact that a large number of detection messages occupy the network bandwidth is avoided, and the sub-health detection efficiency of the link is improved. Furthermore, under the condition that the primary detection result is the suspected sub-health state, secondary detection is carried out on the state of the communication link based on the constructed detection message and the determined detection node, so that the accuracy of link sub-health detection can be effectively improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of network communication technology, and in particular to a link sub-health detection method, device and electronic equipment. Background Art

[0002] In complex networking environments for distributed storage, such as active-active data center environments, the sub-health of network communication links (which can be recorded as network sub-health) has a great impact on the stability and performance of active-active data centers. The so-called active-active data center refers to a networking environment constructed by two data centers, one of which serves as the primary data center (such as being used to undertake user services, etc.) and the other as the backup data center (such as being used to backup the data, configuration or services of the primary data center). The two data centers serve as the primary and backup for each other, and perform real-time data backup. The so-called network sub-health refers to an intermediate state in which the network can still be used but the performance is lower than expected, such as high packet loss rate and high latency during transmission.

[0003] At present, in actual application, the ping packet method is usually used, that is, by actively sending detection packets to detect network sub-health conditions such as packet loss and delay anomalies of network communication links, so as to perform relevant network fault processing. However, the above-mentioned method of detecting link sub-health will generate a large number of detection packets, which will occupy unnecessary network bandwidth and affect normal business packet processing. Summary of the invention

[0004] In view of this, the present application provides a link sub-health detection method, device and electronic device to avoid the situation in which a large number of detection messages generated during the link sub-health detection process occupy the network bandwidth and affect the normal business message processing.

[0005] The present application embodiment provides a link sub-health detection method, which is applied to any node in any data center in a dual data center, and the method includes:

[0006] For the communication link corresponding to the main network port on the node, determine the first network information of the communication link within the specified time period according to each service message sent by the node through the communication link within the specified time period and the response message of each service message; wherein any service message carries a response identifier; the response identifier is used to indicate the target end of the service message to reply to the response message of the service message when receiving the service message;

[0007] If the state of the communication link is detected as a suspected sub-healthy state according to the first network information, a detection message for detecting the communication link is constructed, and a detection node for detecting the communication link is determined to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node.

[0008] The embodiment of the present application also provides a link sub-health detection device, which is configured in any node in any data center of the dual data center, and the device includes:

[0009] A determination module, for determining the first network information of the communication link within a specified time period according to each service message sent by the node through the communication link within a specified time period and a response message of each service message, for the communication link corresponding to the main network port on the node; wherein any service message carries a response identifier; the response identifier is used to indicate that the target end of the service message replies to the response message of the service message when receiving the service message;

[0010] The detection module is used to construct a detection message for detecting the communication link and determine a detection node for detecting the communication link if the state of the communication link is detected to be a suspected sub-healthy state based on the first network information, so as to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node.

[0011] The present application also provides an electronic device, the electronic device comprising:

[0012] Processor; and

[0013] A memory, in which computer program instructions are stored, and when the computer program instructions are executed by a processor, the processor executes the steps of the above method.

[0014] An embodiment of the present application further provides a computer-readable storage medium, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor executes the steps in the above method.

[0015] It can be seen from the above technical solutions that in this embodiment, the communication link corresponding to the main network port on this node is first detected based on the service messages sent by this node through the communication link within the specified time period and the response messages of each service message. In this way, there is no need to perform sub-health detection of the link through additional detection messages during the initial detection, which avoids the situation where a large number of detection messages occupy the network bandwidth and affect the normal business message processing, and improves the efficiency of link sub-health detection. Furthermore, in the case where the initial detection result is a suspected sub-health state, the state of the communication link is secondary detected based on the constructed detection message and the determined detection node, which can effectively improve the accuracy of link sub-health detection. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0017] Figure 1 A flow chart of the method provided in an embodiment of the present application.

[0018] Figure 2 A schematic diagram of a message provided for an embodiment of the present application.

[0019] Figure 3 A flow chart of the business message interaction provided for an embodiment of the present application.

[0020] Figure 4 A network diagram provided for an embodiment of the present application.

[0021] Figure 5 A flow chart of a sub-health detection method for a data center internal network provided in an embodiment of the present application.

[0022] Figure 6 A flow chart of a sub-health detection method for an inter-data center network provided in an embodiment of the present application.

[0023] Figure 7 This is a diagram of the device structure provided in an embodiment of the present application.

[0024] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0025] To facilitate understanding of this solution, before describing this solution, we first describe the technical problems existing in the existing networking environment for distributed storage:

[0026] In a distributed storage system, in order to ensure that the data in the storage cluster is not lost and provide normal external read and write services when a partial failure occurs in the distributed storage system, the distributed storage system uses computing or hardware redundancy mechanisms to deal with partial failures in the system. The main types of failures in distributed storage systems generally include disk failures, node failures, cabinet failures, network failures, etc. For clear types of failures, such as disk failures and node failures, data redundancy technology can generally be used to prevent storage data from being lost and unavailable; network failures are generally resolved by isolating the failed node by a node or cabinet or by performing a retry mechanism.

[0027] In contrast, the sub-healthy state of hardware is difficult to identify and has a greater impact on the storage cluster. Hardware sub-health refers to an intermediate state in which the hardware can still operate normally but the performance is lower than expected. Other causes of hardware sub-health include device temperature, hardware environment, configuration errors, etc.

[0028] In response to the high availability requirements of the network, the distributed storage system achieves fault redundancy and load balancing through technologies such as network card binding and network plane separation. The internal storage network or the internal data exchange network is connected through a 10G or 1G network to form a dedicated internal network of the storage pool node, which is responsible for data exchange and coordination. Here, the distributed storage system may include multiple storage pools, each of which includes multiple storage nodes. Network sub-health will also have an impact on the performance of the distributed storage system. Common network sub-health scenarios include high packet loss rate, high packet error rate, high latency, and flash disconnection. Distributed storage systems are required to monitor, alarm, and perform fault switching and isolation for various network sub-health scenarios.

[0029] Current network sub-health detection methods, for example, can periodically collect network information of each node through the management module for statistics, and calculate the network card's read and write, bandwidth, whether there is packet loss or error, and other information to handle network faults. Or, by using ping packets, without affecting the business, actively detect packets to identify network link packet loss and delay anomalies, and then handle network faults. However, the above methods still have the following problems:

[0030] 1. When the cluster size becomes larger, probing the network through ping packets will generate a large number of detection messages, which will affect the normal processing of business messages and occupy unnecessary network bandwidth;

[0031] 2. In a complex network environment (such as cluster expansion, active-active data centers, multi-site networking environments), network connections in different data centers have different characteristics. Using fixed thresholds (such as fixed latency thresholds, packet loss rate thresholds, etc.) to handle network sub-health problems can easily lead to missed or false reports of network sub-health problems, which in turn affects the normal business of users. Here, multi-site can be understood as multiple data centers.

[0032] In order to enable those skilled in the art to better understand the technical solutions provided by the embodiments of the present application and to make the above-mentioned purposes, features and advantages of the embodiments of the present application more obvious and understandable, the technical solutions in the embodiments of the present application are further described in detail below in conjunction with the accompanying drawings.

[0033] See also Figure 1 , Figure 1 A flow chart of a method provided in an embodiment of the present application. The method is applied to any node in any data center in a dual data center. As an embodiment, the node here is, for example, an electronic device such as a server, which is not specifically limited in this embodiment. The dual data center here refers to, for example, the active-active data center described above.

[0034] like Figure 1 As shown, the process may include the following steps:

[0035] Step 101, for a communication link corresponding to a primary network port on the node, determine first network information of the communication link within a specified time period according to each service message sent by the node through the communication link within a specified time period and a response message to each service message.

[0036] In this embodiment, any service message carries a response identifier; the response identifier is used to indicate the target end of the service message to reply to the service message when receiving the service message. Optionally, the response identifier can be flexibly set based on actual needs, such as a designated field, and this embodiment does not specifically limit the response identifier.

[0037] As an embodiment, when this node receives a business message, it will first add a response identifier in the data area of ​​the business message, and then send the business message carrying the response identifier to the target end; thereafter, when the target end receives the business message, if it recognizes that the business message carries a response identifier, it will immediately send a response message of the business message to this node. The specific content of the response message is not specifically limited here.

[0038] As an embodiment, the above-mentioned first network information at least includes: service delay information and service packet loss information; wherein, the service delay information is determined based on the delay parameters of each service message sent by this node through the above-mentioned communication link within a specified time period; the service packet loss information is determined based on the packet loss parameters of each service message sent by this node through the above-mentioned communication link within a specified time period. Here, the specified time period can be flexibly set based on actual needs, such as being set to 5 seconds, 10 seconds, etc. Optionally, the delay parameters of each service message may refer to the round-trip delay corresponding to each service message; the packet loss parameters of each service message may refer to the packet loss rate corresponding to each service message, which is not specifically limited in this embodiment.

[0039] Based on the above description, the first network information of the communication link within the specified time period is determined according to each service message sent by the node through the communication link within the specified time period and the response message of each service message. There are multiple ways in specific implementation. For example, when determining the service delay information, first for each service message, if a response message of the service message is found, then based on the sending time of the service message and the receiving time of the response message of the service message, the round-trip delay corresponding to the service message is determined; then, the service delay information is determined based on the round-trip delay corresponding to each service message. When determining the packet loss delay information, the service packet loss information corresponding to N new service messages is calculated based on the number of each service message and the number of response messages of each service message; for example, the ratio between the number of response messages of each service message and the number of each service message is used as the service packet loss information (i.e., the packet loss rate).

[0040] In this embodiment, the service delay information is determined based on the round-trip delay corresponding to each service message. In a specific implementation, for example, a maximum round-trip delay is selected from the round-trip delays corresponding to each service message as the service delay information; or the average of the round-trip delays corresponding to each service message is used as the service delay information.

[0041] Step 102: If the state of the above-mentioned communication link is detected to be a suspected sub-healthy state based on the first network information, a detection message for detecting the communication link is constructed, and a detection node for detecting the communication link is determined to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node.

[0042] In this embodiment, the state of the communication link is detected as a suspected sub-healthy state based on the first network information. In a specific implementation, for example, it can be: first check whether the service delay information in the first network information meets the service delay requirement corresponding to the communication link; and / or check whether the service packet loss information in the first network information meets the service packet loss requirement corresponding to the communication link. If the service delay information does not meet the service delay requirement corresponding to the communication link, and / or the service packet loss information does not meet the service packet loss requirement corresponding to the communication link, then it is determined that the state of the communication link is a suspected sub-healthy state.

[0043] Optionally, the service delay requirement may be, for example, that the service delay information is less than a set delay threshold; the service packet loss requirement may be, for example, that the service packet loss information is less than a set packet loss rate threshold. Here, the set delay threshold and the set packet loss rate threshold may be set based on actual needs, and this embodiment does not specifically limit them.

[0044] As for how to determine the detection node used to detect the communication link, and how to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node, it will be described with examples below and will not be repeated here.

[0045] So far, completed Figure 1 The process shown.

[0046] pass Figure 1It can be seen from the process shown that in this embodiment, the communication link corresponding to the main network port on this node is first detected based on the service messages sent by this node through the communication link within the specified time period and the response messages of each service message. In this way, there is no need to perform sub-health detection of the link through additional detection messages during the initial detection, which avoids the situation where a large number of detection messages occupy the network bandwidth and affect the normal business message processing, and improves the efficiency of link sub-health detection. Furthermore, in the case where the initial detection result is a suspected sub-health state, the state of the communication link is re-detected based on the constructed detection message and the determined detection node, which can effectively improve the accuracy of link sub-health detection.

[0047] The following describes how to determine the detection node used to detect the communication link:

[0048] In specific implementation, the communication link corresponding to the main network port on the above-mentioned node can usually be divided into two categories, one is the communication link between the node and other storage nodes in the data center; the other is the communication link between the node and the node in the opposite data center.

[0049] Based on the above description, as an embodiment, when the above-mentioned communication link is a communication link between this node and other nodes in this data center, the above-mentioned detection node determined to detect the communication link may include: selecting at least two nodes from other nodes in this data center as detection nodes.

[0050] Of course, as another embodiment, when the above-mentioned communication link is a communication link between the current node and a node in the opposite data center, the above-mentioned detection node determined for detecting the communication link may include, in specific implementation, selecting at least two nodes from the nodes in the opposite data center as detection nodes.

[0051] The following describes how to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node:

[0052] As an embodiment, there are many specific implementation methods for determining whether the state of the communication link is a sub-healthy state based on the detection message and the detection node. For example, first, for each detection node, based on the detection message and the response message of the detection message received through the reference communication link between the node and the detection node, determine the second network information corresponding to the reference communication link; wherein the second network information at least includes: detection delay information and detection packet loss information; the detection delay information is determined based on the delay parameters of each detection message sent by the node through the reference communication link; the detection packet loss information is determined based on the packet loss parameters of each detection message sent by the node through the reference communication link. Afterwards, detect whether the state of the communication link is a sub-healthy state based on each determined second network information.

[0053] In this embodiment, how to determine the second network information corresponding to the reference communication link based on the detection message and the response message of the detection message received through the reference communication link between the current node and the detection node is similar to how to determine the first network information of the communication link within a specified time period based on each business message sent by the current node through the communication link within a specified time period and the response message of each business message in the above step 101, and will not be repeated here.

[0054] It should be noted that this embodiment does not specifically limit the construction of the detection message, and the construction rule of the detection message can be set based on actual needs to construct the corresponding detection message based on the construction rule.

[0055] As for how to detect whether the state of the communication link is a sub-healthy state based on the determined second network information, it is similar to how to detect whether the state of the communication link is a suspected sub-healthy state based on the first network information in the above step 102, and will not be repeated here.

[0056] As an embodiment, there are many specific implementation methods for detecting whether the state of the communication link is a sub-healthy state based on the determined second network information. For example, first determine a target delay information based on the detection delay information in each second network information, and determine a target packet loss information based on the detection packet loss information in each second network information; then, check whether the target delay information meets the service delay requirement corresponding to the communication link; and / or, check whether the target packet loss information meets the service packet loss requirement corresponding to the communication link. If the target delay information does not meet the service delay requirement corresponding to the communication link, and / or, the target packet loss information does not meet the service packet loss requirement corresponding to the communication link, then determine that the state of the communication link is a sub-healthy state.

[0057] In this embodiment, the above-mentioned determination of a target delay information based on the detection delay information in each second network information can be specifically implemented as follows: selecting a maximum detection delay information from the detection delay information in each second network information as the target delay information; or taking the average of the detection delay information in each second network information as the target delay information. As for how to determine a target packet loss information based on the detection packet loss information in each second network information, it is similar to how to determine a target delay information based on the detection delay information in each second network information, and will not be repeated here.

[0058] As an embodiment, since the physical distances between the nodes corresponding to different types of communication links are different, performing link sub-health detection through fixed delay and packet loss thresholds may easily lead to underreporting or false reporting of link sub-health events. Therefore, in order to avoid this situation, this embodiment sets different requirements for link sub-health detection corresponding to different types of communication links (i.e., service delay requirements and service packet loss requirements), that is, each type of communication link sets service delay requirements and service packet loss requirements (i.e., delay and packet loss thresholds) based on its own network connection characteristics and actual needs.

[0059] The following further describes the processing process after determining that the state of the communication link is a sub-healthy state:

[0060] As an embodiment, when the above-mentioned communication link is a communication link between this node and other nodes in this data center, after determining that the status of the communication link is a sub-healthy state, this embodiment isolates the main network port and enables the backup network port corresponding to the main network port as the main network port.

[0061] As another embodiment, in the case where the above-mentioned communication link is a communication link between the node and the node in the opposite data center, after determining that the state of the communication link is a sub-healthy state, this embodiment reports a link sub-health event indicating that the communication link is in a sub-healthy state to the arbitration node connected to the dual data centers. Wherein, when the arbitration node determines that the number of target nodes corresponding to each data center has reached a set number threshold based on all link sub-health events stored locally, the backup data center in the dual data center is isolated; here, the target node corresponding to any data center refers to the node in the data center that has reported a link sub-health event.

[0062] In this embodiment, the arbitration node detects whether there is a sub-healthy event of the target link locally at a set period, and the time interval between the event reporting time point and the current time point is greater than or equal to the set threshold. If there is, the sub-healthy event of the target link is cleared. Here, the set period and the set threshold can be set based on actual needs, and this embodiment does not make specific limitations.

[0063] As an embodiment, in the case where the communication link is a second communication link, the above-mentioned detection of whether the communication link is in a network sub-health state based on the first network detection information corresponding to the communication link and the set threshold condition for network detection corresponding to the communication link may include: if it is found that the first network detection information corresponding to the second communication link meets the set threshold condition corresponding to the second communication link, then selecting at least two second detection storage nodes from the storage nodes in the opposite data center; sending K second detection messages to each second detection storage node through the second communication link; K is greater than 1; determining the third network detection information corresponding to the second communication link based on the K second detection messages and the response messages corresponding to the received K second detection messages; the third network detection information at least includes the delay information and packet loss information corresponding to the K second detection messages; and detecting whether the second communication link is in a network sub-health state based on the third network detection information.

[0064] As an embodiment, if it is determined that the second communication link is in a network sub-health state, a network sub-health event indicating that the second communication link is in a network sub-health state will be reported to an arbitration node connected to the active-active data center; wherein, when the arbitration node determines that the number of target nodes corresponding to each data center has reached a set number threshold based on all network sub-health events stored locally, the backup data center in the active-active data center will be isolated; the target node corresponding to any data center refers to the node in the data center that has reported a network sub-health event.

[0065] In order to facilitate understanding of the specific implementation process of the above-mentioned link sub-health detection method, the following is an example description through a specific embodiment.

[0066] This embodiment proposes an efficient network sub-health detection method based on adaptive adjustment of isolation strategy based on grouping. By adding statistical fields (i.e., response identifiers) to normal business messages, the network packet loss and delay are counted on the business side (i.e., the business message sending end), and then reported to the network management module (i.e., the module for managing and processing network sub-health events) for packet detection after certain conditions are met. For complex networking environments, by performing network grouping, different sub-health treatments are performed by distinguishing the network communication links within the data center and the core network between data centers (i.e., the network communication links between two data centers), thereby achieving the purpose of accurately identifying and processing sub-healthy networks in large-scale clusters and complex networking scenarios.

[0067] First, modify the service message. Figure 2As shown, taking a normal TCP / IP service message as an example, by adding a one-byte field (ie, Tag) to the data segment of the service message without modifying the specific message format, a new field (ie, response identifier) ​​will be carried in the normal service message.

[0068] Then, see Figure 3 As shown, the storage module (such as can be considered as a module configured on a node in a data center for data service processing, that is, Figure 3 The business interaction process of business module 1 and business module 2 is shown as follows:

[0069] S301, business module 1 sends a business message to business module 2;

[0070] S302, when the service module 2 recognizes that the service message carries a Tag, it immediately replies with a response message to the service module 1;

[0071] S303, business module 2 processes the business message;

[0072] S304 , the service module 2 returns the processing result message of the service message to the service module 1 .

[0073] In this way, each module with message interaction can count the link delay and packet loss information within a certain period.

[0074] After that, when there is a dual-active or multi-site scenario, group detection is performed. Figure 4 As shown, in this networking scenario, there are arbitration sites 401, routers 402, sites 1 403, and sites 2 404, wherein the arbitration site has no business and contains an arbitration node (i.e., node 5); the nodes in sites 1 and 2 communicate with the arbitration node through the router, and the nodes in site 1 and site 2 also communicate through the router. Taking this networking as an example, the network can be divided into three groups, the network in site 1 (such as the communication link between node 1 and node 2), the network in site 2 (such as the communication link between node 3 and node 4), and the core interactive network between site 1 and site 2 (such as the communication link between node 1 and node 2). Different sub-health detection and processing strategies are adopted for different groups.

[0075] The following describes the sub-health detection method process of the internal network of the data center (referred to as the first communication link):

[0076] See also Figure 5 As shown, the method is applied to any node in any data center of the dual data center, and the method includes the following steps:

[0077] S501. Count packet loss and delay information corresponding to service messages sent through a first communication link within a certain period through a configured service module.

[0078] Here, the service message refers to normal service messages such as heartbeat and data exchange.

[0079] S502: Whether the packet loss and delay information exceeds the set threshold; if so, execute S503; otherwise, return to execute S501.

[0080] S503: Report suspected network sub-health events to the configured BM module.

[0081] Here, the BM module refers to the above-mentioned network management module, which is configured in the above-mentioned business module.

[0082] S504. Randomly select several nodes in the data center through the BM module to perform packet detection and obtain packet detection results.

[0083] Here, the packet detection result refers to the detection packet loss information and detection delay information described above. As for how to obtain the packet detection result, please refer to the above related description, which will not be repeated here.

[0084] S505: Determine whether the setting requirement corresponding to the first communication link is met based on the packet detection result; if not, execute S506.

[0085] Here, the set requirements refer to the set delay requirements and the set packet loss requirements corresponding to the above communication link.

[0086] S506: Isolate the current active network port, and start the backup network port of the active network port for communication.

[0087] If the set requirements are met, the above-mentioned suspected network sub-health event is considered to be a false positive sub-health detection event, and the network port isolation and alarm reporting actions will not be performed.

[0088] The following describes the sub-health detection method process of the data center network (referred to as the second communication link):

[0089] See also Figure 6 As shown, the method is applied to any node in any data center of the dual data center, and the method includes the following steps:

[0090] S601, the business module that interacts across data centers will count the packet loss and delay information of the link within a certain period in normal message interaction including heartbeat and data interaction. When it exceeds a certain threshold, it will report to the BM module a suspected network sub-health event;

[0091] S601. Count packet loss and delay information corresponding to service messages sent through the second communication link within a certain period through the configured service module.

[0092] S602: Whether the packet loss and delay information exceeds the set threshold; if so, execute S603; otherwise, return to execute S601.

[0093] S603: Report suspected network sub-health events to the configured BM module.

[0094] S604. Randomly select several nodes in the peer data center through the BM module to perform packet detection and obtain corresponding packet detection results.

[0095] S605: Determine whether the setting requirement corresponding to the second communication link is met based on the packet detection result; if not, execute S606.

[0096] S606: Report a network sub-health event indicating that the second communication link is in a network sub-health state to the arbitration site.

[0097] In this embodiment, the arbitration site collects network sub-health events. If there are network sub-health events reported by site 1 to site 2 and network sub-health events reported by site 2 to site 1 at the same time, it is considered that there is a sub-health problem in the core network between data centers, triggering the keep-alive processing of the arbitration site (i.e. isolating the backup data center in the dual data centers). Among them, the arbitration site regularly cleans up the stored network sub-health events. As for how to clean up, please refer to the above description and will not be repeated here.

[0098] From the above, it can be seen that this embodiment counts the packet loss and delay of the network on the service side by adding a statistical field to the normal TCP message, and reports to the network management module for packet detection after meeting certain conditions, saving normal business resource messages in a passive packet detection mode; in this way, the network link status can be counted through the normal interaction of business messages, and there are no detection messages other than business messages in normal business interactions, which are not affected by the common detection message cycle. There are only detection messages in the scene where the network sub-health is suspected to occur, which improves the efficiency of network sub-health detection and reduces resource consumption. Furthermore, this embodiment also detects the suspected sub-health events reported by the BM module for the second time to prevent false reports of network sub-health events and improve the accuracy of detection. This embodiment also detects network sub-health in a grouping manner, can detect core network failures in dual-active or multi-site scenarios, and sets different isolation thresholds based on different groups for different processing, which improves the accuracy and flexibility of network sub-health detection.

[0099] At this point, the description of the method provided in the embodiment of the present application is completed. The following is a description of the device provided in the embodiment of the present application:

[0100] As an embodiment, this embodiment also provides a link sub-health detection device. Figure 7 , Figure 7 This is a schematic diagram of the device structure provided in the embodiment of the present application. Figure 7 As shown, the device is configured in any node in any data center of the dual data centers, and the device 700 includes:

[0101] The determination module 701 is used to determine the first network information of the communication link within the specified time period according to each service message sent by the node through the communication link within the specified time period and the response message of each service message; wherein any service message carries a response identifier; the response identifier is used to indicate that the target end of the service message replies to the response message of the service message when receiving the service message;

[0102] The detection module 702 is used to construct a detection message for detecting the communication link and determine a detection node for detecting the communication link if the state of the communication link is detected to be a suspected sub-healthy state based on the first network information, so as to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node.

[0103] As an embodiment, the first network information includes at least: service delay information and service packet loss information; the service delay information is determined based on the delay parameter of each service message sent by the node through the communication link within the specified time period; the service packet loss information is determined based on the packet loss parameter of each service message sent by the node through the communication link within the specified time period;

[0104] Detecting that the state of the communication link is a suspected sub-healthy state according to the first network information includes:

[0105] Check whether the service delay information in the first network information meets the service delay requirement corresponding to the communication link; and / or,

[0106] Check whether the service packet loss information in the first network information meets the service packet loss requirement corresponding to the communication link;

[0107] If not, the state of the communication link is determined to be a suspected sub-healthy state.

[0108] As an embodiment, the communication link is a communication link between the node and other nodes in the data center;

[0109] Determine the detection node used to detect the communication link, including:

[0110] Select at least two nodes from other nodes in the data center to serve as detection nodes.

[0111] As an embodiment, after determining that the state of the communication link is a sub-healthy state, the device further includes:

[0112] The isolation module is used to isolate the main network port and enable the backup network port corresponding to the main network port to serve as the main network port.

[0113] As an embodiment, the communication link is a communication link between the local node and a node in a peer data center;

[0114] Determining a detection node for detecting a communication link includes: selecting at least two nodes from nodes in a peer data center to serve as detection nodes.

[0115] As an embodiment, after determining that the state of the communication link is a sub-healthy state, the device further includes:

[0116] A reporting module, used for reporting a link sub-health event indicating that the communication link is in a sub-healthy state to an arbitration node connected to the dual data centers;

[0117] Among them, when the arbitration node determines that the number of target nodes corresponding to each data center has reached the set number threshold based on all link sub-health events stored locally, the backup data center in the dual data centers will be isolated; the target node corresponding to any data center refers to the node in the data center that has reported a link sub-health event.

[0118] As an embodiment, determining whether the state of the communication link is a sub-healthy state based on the detection message and the detection node includes:

[0119] For each detection node, the second network information corresponding to the reference communication link is determined based on the detection message and the response message of the detection message received through the reference communication link between the current node and the detection node; wherein the second network information at least includes: detection delay information and detection packet loss information; the detection delay information is determined based on the delay parameters of each detection message sent by the current node through the reference communication link; the service packet loss information is determined based on the packet loss parameters of each detection message sent by the current node through the reference communication link; and whether the state of the communication link is a sub-healthy state is detected based on the determined second network information.

[0120] So far, completed Figure 7 Structural description of the device shown.

[0121] The implementation process of the functions and effects of each unit in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, and will not be repeated here.

[0122] For the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, that is, they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present application scheme. A person of ordinary skill in the art can understand and implement it without paying creative labor.

[0123] See also Figure 8 , is a schematic diagram of the hardware structure of an electronic device provided by an exemplary embodiment of the present application. The electronic device may include a processor 801, a communication interface 802, a memory 803 and a communication bus 804. The processor 801, the communication interface 802 and the memory 803 communicate with each other through the communication bus 804. Among them, the memory 803 stores computer program instructions; the processor 801 can execute the steps of the method described in the above embodiment by executing the computer program instructions stored in the memory 803. The electronic device may also include other hardware according to the actual function of the electronic device, which will not be described in detail.

[0124] Correspondingly, an embodiment of the present application further provides a computer-readable storage medium, on which a number of computer program instructions are stored. When the computer program instructions are executed by a processor, the method disclosed in the above example of the present application can be implemented.

[0125] Exemplarily, the computer-readable storage medium may be any electronic, magnetic, optical or other physical storage device that may contain or store information, such as executable instructions, data, etc. For example, the computer-readable storage medium may be: RAM (Radom Access Memory), volatile memory, non-volatile memory, flash memory, storage drive (such as hard disk drive), solid state drive, any type of storage disk (such as optical disk, DVD, etc.), or similar storage medium, or a combination thereof. The processor and memory may be supplemented by or incorporated into a dedicated logic circuit.

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

Claims

1. A link sub-health detection method, It is characterized in that The method is applied to any node in any data center of the dual data centers, and the method includes: For the communication link corresponding to the main network port on the node, determine the first network information of the communication link within the specified time period according to each service message sent by the node through the communication link within the specified time period and the response message of each service message; wherein any service message carries a response identifier; the response identifier is used to indicate that the target end of the service message replies to the response message of the service message when receiving the service message; If it is detected according to the first network information that the state of the communication link is a suspected sub-healthy state, a detection message for detecting the communication link is constructed, and a detection node for detecting the communication link is determined to determine whether the state of the communication link is a sub-healthy state based on the detection message and the detection node.

2. The method according to claim 1, It is characterized in that The first network information includes at least: service delay information and service packet loss information; the service delay information is determined based on the delay parameter of each service message sent by the node through the communication link within a specified time period; the service packet loss information is determined based on the packet loss parameter of each service message sent by the node through the communication link within a specified time period; The detecting that the state of the communication link is a suspected sub-healthy state according to the first network information includes: Checking whether the service delay information in the first network information meets the service delay requirement corresponding to the communication link; and / or, Checking whether the service packet loss information in the first network information meets the service packet loss requirement corresponding to the communication link; If not, it is determined that the state of the communication link is a suspected sub-healthy state.

3. The method according to claim 1, It is characterized in that The communication link is a communication link between the node and other nodes in the data center; The determining of a detection node for detecting the communication link comprises: At least two nodes are selected from other nodes in the data center to serve as the detection nodes.

4. The method according to claim 3, It is characterized in that After determining that the state of the communication link is a sub-healthy state, the method further includes: The primary network port is isolated, and a backup network port corresponding to the primary network port is enabled to serve as the primary network port.

5. The method according to claim 1, It is characterized in that The communication link is a communication link between the node and a node in the opposite data center; The determining of a detection node for detecting the communication link comprises: At least two nodes are selected from the nodes in the peer data center to serve as the detection nodes.

6. The method according to claim 5, It is characterized in that After determining that the state of the communication link is a sub-healthy state, the method further includes: reporting a link sub-health event indicating that the communication link is in a sub-healthy state to an arbitration node connected to the dual data center; Among them, when the arbitration node determines that the number of target nodes corresponding to each data center has reached the set number threshold based on all link sub-health events stored locally, the backup data center in the dual data centers is isolated; the target node corresponding to any data center refers to the node in the data center that has reported a link sub-health event.

7. The method according to claim 1, It is characterized in that The determining whether the state of the communication link is a sub-healthy state based on the detection message and the detection node includes: For each detection node, determine the second network information corresponding to the reference communication link according to the detection message and the response message of the detection message received through the reference communication link between the node and the detection node; wherein the second network information at least includes: detection delay information and detection packet loss information; the detection delay information is determined based on the delay parameter of each detection message sent by the node through the reference communication link; the detection packet loss information is determined based on the packet loss parameter of each detection message sent by the node through the reference communication link; Whether the state of the communication link is a sub-healthy state is detected according to the determined second network information.

8. A link sub-health detection device, It is characterized in that The device is configured at any node in any data center of the dual data centers, and the device includes: A determination module, for determining, for the communication link corresponding to the main network port on the node, the first network information of the communication link within the specified time period according to each service message sent by the node through the communication link within the specified time period and the response message of each service message; wherein any service message carries a response identifier; the response identifier is used to indicate that the target end of the service message replies to the response message of the service message when receiving the service message; A detection module is used to construct a detection message for detecting the communication link and determine a detection node for detecting the communication link if it is detected that the state of the communication link is suspected to be in a sub-healthy state based on the first network information, so as to determine whether the state of the communication link is in a sub-healthy state based on the detection message and the detection node.

9. The device according to claim 8, It is characterized in that The first network information includes at least: service delay information and service packet loss information; the service delay information is determined based on the delay parameter of each service message sent by the node through the communication link within a specified time period; the service packet loss information is determined based on the packet loss parameter of each service message sent by the node through the communication link within a specified time period; Detecting that the state of the communication link is a suspected sub-health state based on the first network information includes: checking whether the service delay information in the first network information meets the service delay requirement corresponding to the communication link; and / or, checking whether the service packet loss information in the first network information meets the service packet loss requirement corresponding to the communication link; if not, determining that the state of the communication link is a suspected sub-health state; and / or, The communication link is a communication link between the node and other nodes in the data center; The determining of the detection node for detecting the communication link includes: selecting at least two nodes from other nodes in the data center to serve as the detection nodes; and / or, After determining that the state of the communication link is a sub-healthy state, the device further includes: an isolation module, used to isolate the main network port, and enable the backup network port corresponding to the main network port as the main network port; and / or, The communication link is a communication link between the node and a node in the opposite data center; The determining of the detection nodes for detecting the communication link includes: selecting at least two nodes from nodes in the opposite end data center as the detection nodes; and / or, After determining that the state of the communication link is a sub-health state, the device further includes: a reporting module, which is used to report a link sub-health event indicating that the communication link is in a sub-health state to an arbitration node connected to the dual data centers; wherein, when the arbitration node determines that the number of target nodes corresponding to each data center has reached a set number threshold based on all link sub-health events stored locally, the backup data center in the dual data center is isolated; the target node corresponding to any data center refers to a node in the data center that has reported a link sub-health event; and / or, The method of determining whether the state of the communication link is in a sub-healthy state based on the detection message and the detection node includes: for each detection node, according to the detection message and the response message of the detection message received through the reference communication link between the current node and the detection node, determining the second network information corresponding to the reference communication link; wherein the second network information includes at least: detection delay information and detection packet loss information; the detection delay information is determined based on the delay parameters of each detection message sent by the current node through the reference communication link; the detection packet loss information is determined based on the packet loss parameters of each detection message sent by the current node through the reference communication link; and detecting whether the state of the communication link is in a sub-healthy state based on the determined second network information.

10. An electronic device, It is characterized in that The electronic device includes: Processor; and A memory, wherein computer program instructions are stored in the memory, and when the computer program instructions are executed by the processor, the processor is caused to perform the steps in any one of the methods of claims 1 to 7.

Citation Information

Patent Citations

  • Method, device and system for health examination in load balancing

    CN112738238A

  • Network sub-health detection method and device and medium

    CN116016253A

  • Isolation method and device for sub-health nodes in storage cluster and electronic equipment

    CN117221091A

  • Service abnormity checking method and device, electronic equipment and readable storage medium

    CN117608901A

  • Health state checking method and device, electronic equipment and storage medium

    CN118055043A

Cited By

  • Network state detection method, device, equipment and medium

    CN119743414A