Cloud platform-based fault detection method and device, fault detection system and medium

By generating a node tree and traversing it level by level, the problem of low fault detection efficiency in the bank's PaaS cloud platform is solved, and more efficient fault node and container detection is achieved.

CN116319421BActive Publication Date: 2026-05-29INDUSTRIAL AND COMMERCIAL BANK OF CHINA
View PDF 3 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INDUSTRIAL AND COMMERCIAL BANK OF CHINA
Filing Date
2023-03-17
Publication Date
2026-05-29

AI Technical Summary

Technical Problem

In existing technologies, the number of nodes and containers in a bank's PaaS cloud platform is large, making it inefficient to detect faults one by one.

Method used

By generating a node tree and traversing its hierarchical structure level by level, faulty nodes and containers can be identified.

Benefits of technology

It improves fault detection efficiency, enabling faster identification of faulty nodes and containers on the cloud platform.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116319421B_ABST
    Figure CN116319421B_ABST
Patent Text Reader

Abstract

The application provides a cloud platform-based fault detection method and device, a fault detection system and a medium. The method comprises: when a detection instruction is received, acquiring node information and interface information of a cloud platform, the node information of the cloud platform comprising the name and identity of each level node, and the name and identity of each container under the last level node; generating a node tree according to the node information and interface information of the cloud platform; the node tree is a multi-level node of the cloud platform and a plurality of containers corresponding to the last level node represented in a hierarchical structure of a tree, and the hierarchical structure of the node tree represents the upstream and downstream relationships when data is transmitted between the nodes of each level of the cloud platform and between each container under the last level node and each node of the last level; and the node tree is traversed layer by layer according to the hierarchical structure of the node tree to determine the fault nodes and fault containers of the cloud platform. The method can improve the fault detection efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to fault detection technology, and more particularly to a fault detection method, device, system and medium based on a cloud platform. Background Technology

[0002] With the development of fault detection technology and the continuous growth of financial institutions' business, fault detection methods are needed to monitor the usage status of these nodes and containers in a timely manner in order to ensure the normal operation of the business.

[0003] Currently, the fault detection system is integrated into the PaaS cloud platform. The fault detection system identifies the status of each node and container in the bank's PaaS cloud platform one by one. When a node, container, or application cannot be accessed normally, it is determined that the node or container is abnormal, marked as unavailable, and output for maintenance personnel to troubleshoot.

[0004] However, the number of nodes and containers on a bank's PaaS cloud platform is usually very large, and the method of detecting faults by checking the status of each node and container one by one is inefficient. Summary of the Invention

[0005] This application provides a cloud-based fault detection method, apparatus, system, and medium to address the technical problem of low fault detection efficiency in the prior art.

[0006] Firstly, this application provides a fault detection method based on a cloud platform, comprising:

[0007] Upon receiving a detection command, the node information and interface information of the cloud platform are obtained. The node information of the cloud platform includes the name and identifier of each level node, as well as the name and identifier of each container under the last level node. The interface information of the cloud platform includes the upstream and downstream relationships between the nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node when transmitting data.

[0008] A node tree is generated based on the node information and interface information of the cloud platform. The node tree is a hierarchical structure representing the multi-level nodes of the cloud platform and the multiple containers corresponding to the last level node. The hierarchical structure of the node tree represents the upstream and downstream relationships between the nodes at each level of the cloud platform and between each node at the last level and each container under the last level node when data is transmitted.

[0009] Based on the hierarchical structure of the node tree, the node tree is traversed level by level to determine the faulty nodes and faulty containers of the cloud platform.

[0010] In one embodiment, obtaining the node information and interface information of the cloud platform upon receiving a detection command includes:

[0011] Upon receiving a detection command, a deployment information retrieval command is sent to the cloud platform;

[0012] Obtain the deployment information returned by the cloud platform in response to the deployment information acquisition command;

[0013] Based on the deployment information, obtain the node information and interface information of the cloud platform.

[0014] In one embodiment, traversing the node tree level by level according to its hierarchical structure to determine the faulty nodes and faulty containers of the cloud platform includes:

[0015] Based on the hierarchical structure of the node tree and following a bottom-up traversal method, the node tree is traversed level by level from the bottom layer to determine the faulty nodes and faulty containers of the cloud platform.

[0016] In one embodiment, the step of traversing the node tree level by level from the bottom down according to the hierarchical structure of the node tree and following a bottom-up traversal method to determine the faulty nodes and faulty containers of the cloud platform includes:

[0017] Based on the hierarchical structure of the node tree, data acquisition requests are triggered for multiple containers at the bottom level of the node tree to obtain the return data from each container;

[0018] Containers whose returned data does not meet the preset returned data conditions are identified as faulty containers, and data acquisition requests are triggered to the parent node of each faulty container to obtain the returned data of the parent node of each faulty container.

[0019] If it is determined that the returned data of the parent node of each faulty container meets the preset returned data conditions, then the traversal of the data transmission link where the faulty container is located is terminated.

[0020] In one embodiment, after traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the method further includes:

[0021] Based on the faulty node and the faulty container, determine the corresponding pre-set state test cases;

[0022] The faulty node and the faulty container are tested using each of the state test cases to obtain the corresponding test results, which are the state of the faulty node or the faulty container.

[0023] Based on the pre-stored node status table and the test results, the status identifiers of the faulty node and the faulty container are determined. The node status table stores the status of the node and the container and the corresponding status identifier.

[0024] Based on the pre-stored first maintenance table, the operation and maintenance methods corresponding to the status identifiers of the faulty node and the faulty container are determined and output. The first maintenance table stores the status identifiers of the faulty node and the faulty container and the operation and maintenance methods corresponding to each status identifier.

[0025] In one embodiment, after obtaining the node information and interface information of the cloud platform upon receiving the detection instruction, the method further includes:

[0026] The node information and interface information of the cloud platform are stored in the functional interface database;

[0027] After traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the method further includes:

[0028] The system calls the key functions of the fault node and the fault container stored in the functional interface database, and sends a third data acquisition request to access the interface of the key functions of the fault node and the fault container using pre-packaged functional test cases. The system obtains the test data returned by the key functions of the fault node and the fault container. The third data acquisition request includes the expected data structure to be returned. The key functions are the functions that the container and the node use most frequently for data transmission.

[0029] The data structure of each test data is compared with the expected return data structure to determine whether the key functions of the fault node and the fault container are abnormal;

[0030] In response to the abnormality of the critical functions of the faulty node and the faulty container, the corresponding cause of the abnormality is determined;

[0031] Based on the pre-stored second maintenance table and the cause of the anomaly, the corresponding operation and maintenance method is determined and output. The second maintenance table stores the cause of anomalies when the key functions of nodes and containers are abnormal, and the operation and maintenance method corresponding to each cause of anomaly.

[0032] In one embodiment, comparing the data structure of each test data with the expected returned data structure to determine whether the critical functions of the faulty node and the faulty container are abnormal includes:

[0033] The data structure of each test data is compared with the expected return data structure;

[0034] Determine whether the data structure of each test data is the same as the expected returned data structure;

[0035] In response to the discrepancy in the comparison results, it is determined that the critical functions of the faulty node and the faulty container are abnormal.

[0036] If the comparison results are the same, it is determined that the critical functions of the faulty node and the faulty container are not abnormal.

[0037] In one embodiment, after obtaining the node information and interface information of the cloud platform upon receiving the detection instruction, the method further includes:

[0038] Nodes and containers whose return codes are not preset values ​​are identified as abnormal nodes and abnormal containers, respectively.

[0039] The abnormal nodes and abnormal containers are detected by a preset detection tool to determine the cause of network and / or hardware and software failures of the abnormal nodes and abnormal containers.

[0040] Based on the pre-stored third maintenance table and the cause of the failure, the corresponding operation and maintenance method is determined and output. The third maintenance table stores the cause of failure when the network and / or hardware and software of the node and container fail, the failure category to which each failure cause belongs, and the operation and maintenance method corresponding to each failure category.

[0041] Secondly, this application provides a cloud-based fault detection device, located within a fault detection system, the device comprising:

[0042] The information acquisition module is used to acquire the node information and interface information of the cloud platform when a detection command is received. The node information of the cloud platform includes the name and identifier of each level node, and the name and identifier of each container under the last level node. The interface information of the cloud platform includes the upstream and downstream relationships between the nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node when data is transmitted.

[0043] The node tree generation module is used to generate a node tree based on the node information and interface information of the cloud platform. The node tree is a hierarchical structure of the cloud platform, representing the multi-level nodes and the multiple containers corresponding to the last-level node. The hierarchical structure of the node tree represents the upstream and downstream relationships between the nodes at each level of the cloud platform and between the last-level nodes and the containers under the last-level nodes when transmitting data.

[0044] The node tree traversal module is used to traverse the node tree level by level according to its hierarchical structure in order to determine the faulty nodes and faulty containers of the cloud platform.

[0045] Thirdly, this application provides a fault detection system, including: a processor, and a memory communicatively connected to the processor;

[0046] The memory stores computer-executed instructions;

[0047] The processor executes computer execution instructions stored in the memory to implement the method as described in the first aspect.

[0048] Fourthly, this application provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement the method described in the first aspect.

[0049] Fifthly, this application provides a computer program product, including a computer program that, when executed by a processor, implements the method described in the first aspect.

[0050] The fault detection method, apparatus, system, and medium based on a cloud platform provided in this application, upon receiving a detection command, acquires the node information and interface information of the cloud platform. The node information includes the name and identifier of each level of node, and the name and identifier of each container under the last level node. The interface information includes the upstream and downstream relationships during data transmission between nodes at all levels of the cloud platform, and between each node at the last level and its containers. Based on the node information and interface information, a node tree is generated. The node tree represents the multi-level nodes of the cloud platform and the multiple containers corresponding to the last level node in a hierarchical tree structure. The hierarchical structure of the node tree characterizes the upstream and downstream relationships during data transmission between nodes at all levels of the cloud platform, and between each node at the last level and its containers. Based on the hierarchical structure of the node tree, the node tree is traversed level by level to determine the faulty nodes and faulty containers of the cloud platform. Upon receiving a detection command, this application generates a node tree based on the node information and interface information of the cloud platform, and determines the faulty nodes and faulty containers of the cloud platform by traversing the node tree level by level. Since hierarchical traversal can traverse multiple containers or nodes simultaneously, this application can significantly improve detection efficiency compared to the traditional method of traversing the state of nodes or containers one by one, thereby identifying faulty nodes and containers on the cloud platform more quickly. Attached Figure Description

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

[0052] Figure 1This is an application scenario diagram illustrating the cloud-based fault detection method according to embodiments of this application.

[0053] Figure 2 This is a schematic flowchart illustrating an embodiment of the fault detection method based on a cloud platform according to this application.

[0054] Figure 3 This is a flowchart illustrating another embodiment of the fault detection method based on a cloud platform according to this application;

[0055] Figure 4 This is a schematic diagram illustrating the structure of the cloud-based fault detection method implemented in this application.

[0056] Figure 5 This is a schematic diagram of the structure of a fault detection system used to implement a cloud-based fault detection method.

[0057] The accompanying drawings illustrate specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0058] 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 numbers 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 application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0059] To clearly understand the technical solution of this application, the solutions of the prior art will be described in detail first.

[0060] In the traditional approach, the fault detection system is integrated into the PaaS cloud platform. The fault detection system identifies the status of each node and container in the bank's PaaS cloud platform one by one. When a node, container, or application cannot be accessed normally, it is determined that the node or container is abnormal, marked as unavailable, and output for maintenance personnel to troubleshoot.

[0061] However, the number of nodes and containers on a bank's PaaS cloud platform is usually very large, and the method of detecting faults by checking the status of each node and container one by one is inefficient.

[0062] Therefore, facing the technical problems of existing technologies, the inventors, through creative research, discovered and designed a more efficient fault detection method to improve fault detection efficiency. This method primarily constructs a node tree for fault detection based on the node deployment of the cloud platform. This node tree represents the multi-level nodes of the cloud platform in a hierarchical structure, along with the multiple containers corresponding to the last-level nodes. The hierarchical structure of the node tree represents the upstream and downstream relationships during data transmission between nodes at each level, and between each node at the last level and its containers. Upon receiving a detection command, the faulty nodes and containers on the cloud platform are identified by traversing the node tree level by level. Since each level includes multiple containers or multiple nodes, this level-by-level traversal method is more efficient than individual node-by-node traversal, allowing for faster identification of faulty nodes and containers.

[0063] like Figure 1 As shown in the embodiment of this application, the application scenario of the cloud platform-based fault detection method includes a fault detection system 10 and a cloud platform 20 in the corresponding network architecture, and the fault detection system 10 and the cloud platform 20 are connected for communication. When the fault detection system 10 receives a detection command, it obtains node information and interface information from the cloud platform 20 and generates a node tree in the fault detection system 10. Then, the fault detection system 10 traverses the node tree level by level according to the hierarchical structure of the node tree to determine the faulty nodes and faulty containers of the cloud platform 20.

[0064] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0065] Figure 2 This application provides a cloud-based fault detection method according to an embodiment, such as... Figure 2 As shown, the execution entity of the cloud-based fault detection method provided in this embodiment is the fault detection system. Therefore, the cloud-based fault detection method provided in this embodiment includes the following steps:

[0066] Step 101: Upon receiving a detection command, obtain the node information and interface information of the cloud platform.

[0067] The detection command is an instruction used to direct the fault detection system to perform fault detection on the cloud platform. The timing of triggering the detection command can be either automatic fault detection by the fault detection system according to a set trigger time, or the cloud platform sending a detection command to the fault detection system or sending a detection request notification to the operations and maintenance personnel's terminal when it determines that the difference between its own business system's transaction volume and historical average transaction volume, and / or transaction success rate and historical average success rate reaches corresponding preset thresholds, so that the operations and maintenance personnel can trigger the fault detection system to perform fault detection on the cloud platform.

[0068] The cloud platform's node information includes the name and identifier of each level of the cloud platform's nodes, as well as the name and identifier of each container under the last level node. The cloud platform's interface information includes the upstream and downstream relationships between nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node, during data transmission.

[0069] Optionally, upon receiving a detection command, the system acquires the node and interface information of the cloud platform. Specifically, this includes: sending a deployment information acquisition command to the cloud platform upon receiving the command; acquiring the deployment information returned by the cloud platform in response to the command; and acquiring the node and interface information of the cloud platform based on the deployment information. The deployment information refers to the planned architecture information prior to the formal deployment of the cloud platform. Therefore, by acquiring the deployment information from the cloud platform, the fault detection system can determine the node and interface information of the cloud platform.

[0070] In this embodiment, the fault detection system is used for the first fault detection of a cloud platform. Upon receiving the detection command, it is necessary to obtain the node information and interface information from the cloud platform. For subsequent fault detections of the same cloud platform (N being a positive integer greater than 1), it is not necessary to re-obtain the node information and interface information from the same cloud platform. The fault detection system can perform fault detection on multiple cloud platforms, but for the initial fault detection of each cloud platform, it is necessary to obtain the corresponding cloud platform's node information and interface information.

[0071] For the same cloud platform, if the nodes and containers of that cloud platform are updated, the fault detection system needs to re-acquire the node information and interface information of that cloud platform. Here, this embodiment can also be understood as the cloud platform's nodes and / or containers being updated, notifying the fault detection system so that the fault detection system can obtain the current node information and interface information of the cloud platform. Therefore, the node information and interface information of the cloud platform in step 101 can be understood as the updated node information and interface information of the cloud platform.

[0072] Step 102: Generate a node tree based on the node information and interface information of the cloud platform.

[0073] The cloud platform's node information includes the name and identifier of each node at each level, as well as the name and identifier of each container under the last-level node. The cloud platform's interface information includes the upstream and downstream relationships between nodes at each level and between each node at the last level and its containers. Therefore, based on the cloud platform's node and interface information, the architecture of the cloud platform's multiple nodes and containers can be determined.

[0074] After obtaining the node and interface information of the cloud platform, the multi-level nodes of the cloud platform and the multiple containers under the last level node are represented by the hierarchical structure of the node tree, thus generating the node tree.

[0075] The fault detection system obtains node and interface information from the cloud platform, generates a node tree, and can perform fault detection on the cloud platform based on this node tree. The principle is as follows: the fault detection system generates a node tree based on the node and interface information of the cloud platform, enabling the fault detection system to obtain the layout of multiple containers under each level of nodes and the last level node of the cloud platform, as well as the multiple data transmission links of the cloud platform. Therefore, it can control and trigger a data acquisition request corresponding to any container or node of the cloud platform. This data acquisition request can be used to obtain data from the corresponding container and node of the cloud platform, and determine where the fault occurred in the data transmission link of any container or node based on the returned data and return code, such as the container or a certain level node.

[0076] Step 103: Based on the hierarchical structure of the node tree, traverse the node tree level by level to determine the faulty nodes and faulty containers of the cloud platform.

[0077] Since the cloud platform and business systems rely on the normal data transmission of each node and container to achieve efficient and accurate business operations, when the transaction volume of the business system connected to the cloud platform differs from the historical average transaction volume and / or the transaction success rate differs from the historical average success rate, it can be determined that some nodes and / or containers in the cloud platform are faulty, and a fault detection system is needed to detect the cloud platform.

[0078] Here, a faulty node refers to a node in the cloud platform that experiences a failure, causing problems with the business. A faulty container refers to a container in the cloud platform that experiences a failure, causing problems with the business.

[0079] Because the fault detection system has pre-configured load balancing, it can concurrently send data retrieval requests to multiple containers / nodes at the same level in the node tree, traversing the node tree level by level.

[0080] By traversing the node tree level by level, multiple containers or nodes can be traversed simultaneously. Therefore, compared with the existing technology of traversing the state of nodes or containers one by one, the method of traversing the node tree level by level can significantly improve the detection efficiency, thereby enabling faster identification of faulty nodes and containers on the cloud platform.

[0081] In this application, upon receiving a detection command, the node information and interface information of the cloud platform are obtained. The node information includes the name and identifier of each level of node, and the name and identifier of each container under the last level node. The interface information includes the upstream and downstream relationships between nodes at all levels of the cloud platform, and between each node at the last level and its containers. Based on the node information and interface information of the cloud platform, a node tree is generated. The node tree represents the multi-level nodes of the cloud platform and the multiple containers corresponding to the last level node in a hierarchical tree structure. The hierarchical structure of the node tree represents the upstream and downstream relationships between nodes at all levels of the cloud platform, and between each node at the last level and its containers. Based on the hierarchical structure of the node tree, the node tree is traversed level by level to determine the faulty nodes and faulty containers of the cloud platform. In this application, upon receiving a detection command, a node tree is generated based on the node information and interface information of the cloud platform, and the faulty nodes and faulty containers of the cloud platform are determined by traversing the node tree level by level. Since hierarchical traversal can traverse multiple containers or nodes simultaneously, this application can significantly improve detection efficiency compared to the traditional method of traversing the state of nodes or containers one by one, thereby identifying faulty nodes and containers on the cloud platform more quickly.

[0082] As an optional implementation, in this embodiment, step 103 specifically includes step 201: according to the hierarchical structure of the node tree and following a bottom-up traversal method, traverse each level of the node tree from the bottom layer to determine the faulty nodes and faulty containers of the cloud platform.

[0083] The process involves traversing the node tree from its hierarchical structure, starting from the bottom level (the level containing multiple containers under the last node). After traversing the bottom level, the process continues level by level upwards to identify faulty nodes and containers on the cloud platform.

[0084] When a fault detection system sends a data retrieval request to a container or a node at a certain level to obtain data, the data retrieved may not necessarily be from that container or node at that level, but rather from other nodes in the transmission link. Therefore, if an error occurs during data transmission, it is possible that the container or node returning the error data is not actually the faulty container or node. Figure 3 Taking the node tree shown as an example, this node tree has four levels. The bottom level consists of the containers, the next level up consists of the second-level nodes, the next level up consists of the first-level nodes, and the top level is the parent node. Figure 3 The data transmission link in the branch from container A1 to secondary node 1, primary node 1, and finally to the main node is analyzed. Assume the fault detection system requests data from container A1, but the data returned from container A1 may not be from container A1 itself. For example, if container A1 does not have the data requested by the fault detection system, it will request it from secondary node 1. Similarly, if the data is not present in secondary node 1, it will request it from primary node 1. If the data is also not present in primary node 1, it will request it from the main node.

[0085] The availability of a cloud platform is closely related to the critical functions of its containers and nodes. These critical functions refer to the functions that containers and nodes most frequently use for data transmission. The availability of the cloud platform is guaranteed only if the critical functions of containers and nodes are functioning correctly. Only a bottom-up traversal method can determine whether the critical functions of containers and nodes are functioning correctly. Therefore, to ensure the availability of the cloud platform, the node tree is traversed from bottom to top.

[0086] In addition, traversing the node tree from top to bottom is costly and inefficient, requiring individual inspection of containers and nodes, similar to existing technologies. This individual inspection necessitates further investigation. For example, if a problem is identified in the data transmission process of the main node, it's necessary to determine which of the following level-one nodes (nodes 1, 2, 3, ..., n) is causing the issue. If the problem is identified as node 2, it's also necessary to determine which of the following level-two nodes (nodes 1, 2, ..., n) is causing the problem, and so on.

[0087] Using a bottom-up, layer-by-layer traversal approach can accurately identify faulty containers and nodes because, as mentioned earlier, nodes at lower levels retrieve data from nodes at higher levels when there is none. Therefore, when a node at a lower level is determined to be abnormal, the nodes at the higher level are checked, and so on, accurately identifying the source node of the anomaly and determining it as the faulty node. Furthermore, if the parent node has not yet been detected, for example, if second-level node 1 is found to be normal, container A1 can be determined to be abnormal without needing to check first-level node 1 and the parent node. Therefore, the detection efficiency is faster than the top-down approach.

[0088] In this embodiment, based on the hierarchical structure of the node tree and following a bottom-up traversal method, the node tree is traversed level by level from the bottom layer to determine the faulty nodes and faulty containers of the cloud platform.

[0089] As an optional implementation, in this embodiment, step 201 includes the following steps:

[0090] Step 301: Based on the hierarchical structure of the node tree, trigger data acquisition requests for multiple containers at the bottom layer of the node tree to obtain the return data from each container.

[0091] The container's data retrieval request includes the expected data structure of the data returned by the container. This expected data structure is the data structure anticipated for the data returned by the container. Theoretically, only if the data structure of the container's returned data matches the expected data structure in the container's data retrieval request can it be concluded that the data returned from the container is accurate and that there are no data transmission errors in the data transmission link where the container resides.

[0092] In the cloud platform, data retrieval requests from nodes and containers are stored as node information in the fault detection system. The fault detection system can trigger data retrieval requests from containers at the bottom of the node tree to obtain data from them. The data retrieved from these containers is called the container's returned data. Here, the data retrieval requests from containers differ slightly from general data retrieval requests. General data retrieval requests involve containers retrieving data from other locations, such as their parent nodes. However, here, the data retrieval requests from containers refer to requests that retrieve data directly from within those containers.

[0093] Data retrieved from a container can be retrieved directly from the container if the corresponding data is stored in the container's database. If the corresponding data is not stored in the container's database, the container can retrieve it from its parent node.

[0094] Step 302: Containers whose returned data does not meet the preset returned data conditions are identified as faulty containers, and data acquisition requests are triggered to the parent node of each faulty container to obtain the returned data of the parent node of each faulty container.

[0095] The data retrieval request for the parent node of the faulty container here refers to the request to retrieve data from the parent node of the faulty container. It can be used to retrieve data from the parent node of the faulty container.

[0096] The data acquisition request of the parent node of the faulty container includes the expected data structure of the returned data of the parent node of the faulty container. The expected data structure of the returned data of the parent node of the faulty container is the expected data structure of the data returned by the parent node of the faulty container.

[0097] The container's returned data does not meet the preset returned data conditions, which means that the returned data of the container is inconsistent with the expected data structure of the returned data of the corresponding container in the container's data acquisition request.

[0098] Data returned from the parent node of the failed container can be retrieved from that parent node's database if the corresponding data is stored there. If the corresponding data is not stored in the database of the parent node, the parent node can retrieve it from its parent's parent node.

[0099] Step 303: If it is determined that the returned data of the parent node of each faulty container meets the preset returned data conditions, then the traversal of the data transmission link where the faulty container is located is terminated.

[0100] Here, it is assumed that the returned data from the parent node of each faulty container meets the preset returned data conditions. In this case, the traversal of the data transmission link where the faulty container is located is terminated.

[0101] The return data of the parent node of the faulty container meets the preset return data conditions, which means that the return data of the parent node of the faulty container is consistent with the expected data structure of the return data of the parent node of the faulty container.

[0102] If it is determined that the returned data of the previous node of each faulty container does not meet the preset return data conditions, then all such nodes are identified as first faulty nodes, and a data acquisition request is triggered for the next-level node of each first faulty node to obtain its returned data. Furthermore, for the next-level nodes of each first faulty node, if the returned data of the next-level node of each first faulty node does not meet the preset return data conditions, then all such nodes are identified as second faulty nodes, and a data acquisition request is triggered for the next-level node of each second faulty node to obtain its returned data. For any data transmission link in the node tree, the end of traversal is indicated by the data obtained from the Nth-level node meeting the preset return data conditions. If the data does not meet the preset return data conditions, a data acquisition request for the next-level node is triggered again, and traversal continues. If the returned data of the lowest-level container of one or more data transmission links in the node tree meets the preset return data conditions, then traversal upwards is stopped.

[0103] In this embodiment, the returned data of each container and node is judged by preset return data conditions, so as to accurately determine whether a data transmission error has occurred.

[0104] Let's illustrate the process of traversing a node tree to determine the faulty container and faulty node with a concrete example: Let's continue with... Figure 3 The data transmission link of the branch from container A1 to secondary node 1 to primary node 1 to the main node is analyzed. First, a data acquisition request is triggered in container A1 to obtain data from container A1. If the data structure returned by container A1 is consistent with the expected data structure returned by container A1, it is determined that there is no data transmission error in the data transmission link where container A1 is located, and the data transmission link of this branch will not be checked again.

[0105] Meanwhile, assuming that in the data transmission link of another branch—container A2-secondary node 2-primary node 2-main node—the data structure returned by container A2 is inconsistent with the expected data structure returned by container A2, then it is determined that there is a data transmission error in the data transmission link where container A2 resides. However, as mentioned above, the source of the data transmission error may be caused by a node n levels above it, and this n-level node is the actual faulty node. Therefore, in order to further determine which level of node is the faulty node, it is necessary to further inspect the data transmission link of this branch.

[0106] This method utilizes the hierarchical structure of a node tree and leverages the flow of data to determine whether further testing of the upper level is necessary based on the status of the lower-level data. If the lower level is normal, then all data in the same branch in the upper level is normal; if the lower level is abnormal, then the data in the same branch in the upper level may be abnormal. This effectively reduces the number of nodes traversed, lowers the workload, and improves testing efficiency.

[0107] To further determine the causes of failures in the faulty nodes and containers, state test cases are used to examine the state of each faulty node and container. As an optional implementation, this embodiment further includes the following steps after step 103:

[0108] Step 401: Determine the corresponding pre-set state test cases based on the fault node and the fault container.

[0109] Among them, state test cases are pre-defined test programs of the fault detection system, which can be used to detect the state of nodes and containers to determine whether the nodes and containers are in a faulty state. State test cases include state test cases specifically for detecting the state of nodes (hereinafter referred to as node state test cases) and state test cases specifically for detecting the state of containers (hereinafter referred to as container state test cases).

[0110] It should be noted that there can be one or more faulty nodes and one or more faulty containers.

[0111] Assuming that the fault detection system determines that there are both faulty nodes and faulty containers in the cloud platform, then at this time, node status test cases are used to detect the status of at least one faulty node, and container status test cases are used to detect the status of at least one faulty container.

[0112] If the fault detection system only determines that the cloud platform has faulty nodes, then it only needs to use node status test cases to detect the status of at least one faulty node. Similarly, if the fault detection system only determines that the cloud platform has faulty containers, then it only needs to use container status test cases to detect at least one faulty container.

[0113] Step 402: Test the faulty node and the faulty container using each of the state test cases to obtain the corresponding test results, where the test results represent the state of the faulty node or the faulty container.

[0114] Testing at least one faulty node using node status test cases involves inputting the IP information of at least one faulty node into the node status test cases. After the test, the status of the faulty node can be obtained. Similarly, testing at least one faulty container using container status test cases involves inputting the IP information and / or name of at least one faulty container into the container status test cases. After the test, the status of the faulty container can be obtained.

[0115] The state of a faulty node is the state it is in when it is detected as a faulty node by the fault detection system. The state of a faulty container is the state it is in when it is detected as a faulty container by the fault detection system.

[0116] The states of faulty nodes and faulty containers can be as shown in the node state table in Table 1. For example, the state of a faulty node can be pending (waiting to be scheduled), waiting (waiting to start), or CrashLoopBackOff (container exits). If the fault detection system detects that a node is in a pending state, it can determine that the node is a faulty node.

[0117] The status of a faulty container can be Restarting, Removing, Paused, etc. For example, if the fault detection system detects that a container is in the Restarting state, it can determine that the container is faulty.

[0118] The databases in Table 1 refer to the databases of nodes and containers; all nodes and containers have databases. If the databases of a node or container are in any of the states shown in Table 1, the fault detection system will identify that node or container as a faulty node or container.

[0119] Table 1

[0120]

[0121]

[0122] The relationship between applications, nodes, and containers can be understood as follows: an application is composed of multiple nodes and / or multiple containers to perform a certain type of business function. Therefore, after identifying a faulty node or container, it can be inferred that the application composed of that faulty node or container may have a problem; this can be called a faulty application. After identifying the faulty application, relevant personnel can be instructed to perform maintenance. Table 2 shows the potential problems with a faulty application.

[0123] Table 2

[0124]

[0125] Step 403: Based on the pre-stored node status table and the test results, determine the status identifiers of the faulty node and the faulty container.

[0126] The node state table stores the state of the node, the state of the container, and the state identifiers of the node and the container. As shown in Table 1, the third column of Table 1 represents the state of the node and the state of the container, and the second column of Table 1 represents the state identifiers of the node and the state identifiers of the container.

[0127] Based on the pre-stored node status table, the status of the faulty node, and the status of the faulty container, the status identifier of the faulty node and the status identifier of the faulty container can be determined.

[0128] Step 404: Based on the pre-stored first maintenance table, determine and output the operation and maintenance mode corresponding to the status identifier of the faulty node and the faulty container.

[0129] The first maintenance table stores the status identifiers of faulty nodes and faulty containers, as well as the corresponding maintenance methods for the status identifiers of the faulty nodes and containers. As shown in Table 3, the rows in the third column of Table 3 represent the maintenance methods corresponding to the status identifiers of the faulty nodes and containers.

[0130] Table 3

[0131]

[0132]

[0133] Based on the pre-stored first maintenance table, the status identifiers of the faulty nodes and the faulty containers, the maintenance method corresponding to the status identifiers of the faulty nodes and containers can be determined. Then, the fault detection system outputs the maintenance methods corresponding to the status identifiers of the faulty nodes and containers.

[0134] In this embodiment, pre-set state test cases are determined based on the faulty node and the faulty container. Each state test case is used to test the faulty node and the faulty container, obtaining corresponding test results, which represent the state of the faulty node or container. Based on a pre-stored node state table and the test results, state identifiers for the faulty node and the faulty container are determined. The node state table stores the states of nodes and containers and their corresponding state identifiers. A pre-stored first maintenance table is used to determine and output the maintenance methods corresponding to the state identifiers of the faulty node and the faulty container. The first maintenance table stores the state identifiers of the faulty node and the faulty container and their corresponding maintenance methods. Because after determining the faulty node and the faulty container on the cloud platform, each state test case is used to test the faulty node and the faulty container to determine their states. Then, the state identifiers of the faulty node and the faulty container are determined based on the node state table, and the maintenance methods corresponding to the state identifiers of the faulty node and the faulty container are determined based on the first maintenance table, accurate maintenance of the faulty node and the faulty container can be achieved.

[0135] As an optional implementation, in this embodiment, after step 101, the following step is also included: storing the node information and interface information of the cloud platform in the functional interface database.

[0136] The functional interface database, located within the fault detection system, stores node and interface information from the cloud platform. Upon receiving a detection command and retrieving node and interface information from the cloud platform, the fault detection system stores this information in the functional interface database. This allows the system to control each node and container to trigger data retrieval requests.

[0137] Following step 102, the cloud-based fault detection method further includes the following steps:

[0138] Step 501: Invoke the key functions of the fault node and the fault container stored in the functional interface database, and use pre-packaged functional test cases to send a third data acquisition request to access the interface of the key functions of the fault node and the fault container to obtain the test data returned by the key functions of the fault node and the fault container.

[0139] The third data acquisition request includes the expected returned data structure, and its key function is the one that containers and nodes use most frequently for data transfer.

[0140] The node information of a cloud platform also includes multiple functions of each node and container. The most frequently used function among these functions is called a critical function. A function can be used to transfer specific data from a container or node to a target object. Taking container A1 as an example, suppose container A1 has three functions: B1, B2, and B3. Function B1 can transfer data X1 to secondary node 1, function B2 can transfer data X2 to secondary node 1, and function B3 can transfer data X3 to secondary node 1. If function B1 transfers data X1 most frequently, then function B1 is a critical function.

[0141] It can be seen that the critical function of a faulty node refers to the function that the faulty node uses most frequently for data transmission. Similarly, the critical function of a faulty container refers to the function that the faulty container uses most frequently for data transmission.

[0142] By invoking the key functions of fault nodes and fault containers stored in the functional interface database and running pre-packaged functional test cases, a third-party data acquisition request can be triggered to access the interfaces for the key functions of the fault nodes and fault containers. This allows the acquisition of test data returned by the fault nodes and fault containers through their respective key functions. The third-party data acquisition request includes the expected returned data structure.

[0143] Step 502: Compare the data structure of each test data with the expected returned data structure to determine whether the critical functions of the fault node and the fault container are abnormal.

[0144] By comparing the data structure of the test data returned by the faulty node with the expected data structure, it can be determined whether the critical functions of the faulty node are abnormal.

[0145] Specifically, it determines whether the test data structure returned by the faulty node is the same as the expected data structure; if the comparison results are different, it determines that the critical function of the faulty node is abnormal; if the comparison results are the same, it determines that the critical function of the faulty node is not abnormal.

[0146] Similarly, by comparing the data structure of the test data returned by the faulty container with the expected data structure, it can be determined whether the critical functions of the faulty container have malfunctioned.

[0147] Specifically, it determines whether the test data structure returned by the faulty container is the same as the expected data structure; if the comparison results are different, it determines that the critical function of the faulty container is abnormal; if the comparison results are the same, it determines that the critical function of the faulty container is not abnormal.

[0148] Step 503: In response to the abnormality of the critical functions of the faulty node and the faulty container, determine the corresponding cause of the abnormality.

[0149] Step 504: Determine and output the corresponding operation and maintenance method based on the pre-stored second maintenance table and the cause of the anomaly.

[0150] The second maintenance table also stores the reasons for abnormalities in the critical functions of nodes and containers, as well as the corresponding operation and maintenance methods for each reason. As shown in Table 4, when the reason for the abnormality is that the returned field is invalid, the corresponding operation and maintenance method is to automatically switch back to the previous version and notify the maintenance personnel by email / SMS.

[0151] Table 4

[0152]

[0153] In this embodiment, the node information and interface information of the cloud platform are stored in a functional interface database. After traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the method further includes: calling the key functions of the faulty nodes and faulty containers stored in the functional interface database; sending a third data acquisition request using pre-packaged functional test cases to access the interfaces of the key functions of the faulty nodes and faulty containers; obtaining test data returned through the key functions of the faulty nodes and faulty containers; the third data acquisition request includes the expected data structure to be returned; the key functions are the functions most frequently used by containers and nodes for data transmission; comparing the data structure of each test data with the expected data structure to determine whether the key functions of the faulty nodes and faulty containers are abnormal; in response to the abnormality of the key functions of the faulty nodes and faulty containers, determining the corresponding cause of the abnormality; determining and outputting the corresponding operation and maintenance method based on the pre-stored second maintenance table and the cause of the abnormality; the second maintenance table also stores the cause of the abnormality when the key functions of nodes and containers are abnormal, and the operation and maintenance method corresponding to each cause of abnormality. Since the cause of the anomaly is determined based on the key functions of the faulty node and the faulty container, the operation and maintenance method corresponding to the cause of the anomaly is accurate based on the second maintenance table, which can efficiently and accurately perform operation and maintenance on the faulty node and the faulty container.

[0154] As an optional implementation, in this embodiment, after step 101, the following step is further included:

[0155] Step 601: Nodes and containers whose return codes are not preset values ​​are identified as abnormal nodes and abnormal containers, respectively.

[0156] The return code returned by a container is determined by the fault detection system based on the latency of triggering the data acquisition request. If the latency exceeds a preset latency, the container's return code indicates whether the container's network and / or hardware / software state is abnormal. If the container's return code is not a preset value (i.e., not 200), it indicates that the container's network and / or hardware / software is in a fault state, and the container is identified as an abnormal container. The return code returned by a node is determined in the same way as that of a container. The node's return code indicates whether the node's network and / or hardware / software state is abnormal. If the node's return code is not a preset value, it indicates that the node's network and / or hardware / software is in a fault state, and the node is identified as an abnormal node.

[0157] Step 602: Use a preset detection tool to detect the abnormal node and the abnormal container to determine the cause of the network and / or hardware and software failure of the abnormal node and the abnormal container.

[0158] The preset detection tools can be third-party open-source testing tools such as LoadRunner and JMeter, which can be used to obtain the network and / or hardware and software status of nodes and containers. The preset detection tools are software code, and their operation is controlled by the fault detection system to determine the cause of network and / or hardware and software failures in abnormal nodes and containers.

[0159] Step 603: Determine and output the corresponding operation and maintenance method based on the pre-stored third maintenance table and the cause of the fault.

[0160] The third maintenance table stores the causes of network and / or hardware / software failures of nodes and containers, the failure categories to which each cause belongs, and the corresponding maintenance methods for each failure category. For example, if the cause of a network and / or hardware / software failure is excessive CPU utilization, the corresponding failure category is insufficient resources, and the corresponding maintenance method is emergency resource expansion and notification of maintenance personnel via email / SMS.

[0161] Table 5

[0162]

[0163]

[0164] In this embodiment, nodes and containers whose return codes are not preset values ​​are identified as abnormal nodes and abnormal containers, respectively. A preset detection tool is used to detect the abnormal nodes and containers to determine the cause of network and / or hardware / software failures. Based on a pre-stored third maintenance table and the cause of failure, a corresponding maintenance method is determined and output. The third maintenance table stores the cause of network and / or hardware / software failures of nodes and containers, the failure category of each cause, and the corresponding maintenance method for each failure category. Because the preset detection tool can accurately determine the cause of failure for abnormal nodes and containers, the accuracy of determining the maintenance method based on the third maintenance table can be guaranteed, thus ensuring accurate maintenance of abnormal nodes and containers.

[0165] Figure 4 This is a schematic diagram of the structure of a cloud-based fault detection device provided in an embodiment of this application, as shown below. Figure 4 As shown, the cloud-based fault detection device 40 provided in this embodiment is located in the fault detection system. Therefore, the cloud-based fault detection device 40 provided in this embodiment includes:

[0166] The information acquisition module is used to acquire the node information and interface information of the cloud platform when a detection command is received. The node information of the cloud platform includes the name and identifier of each level node, and the name and identifier of each container under the last level node. The interface information of the cloud platform includes the upstream and downstream relationships between the nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node when data is transmitted.

[0167] The node tree generation module is used to generate a node tree based on the node information and interface information of the cloud platform. The node tree is a hierarchical structure of the cloud platform, representing the multi-level nodes and the multiple containers corresponding to the last-level node. The hierarchical structure of the node tree represents the upstream and downstream relationships between the nodes at each level of the cloud platform and between the last-level nodes and the containers under the last-level nodes when transmitting data.

[0168] The node tree traversal module is used to traverse the node tree level by level according to its hierarchical structure in order to determine the faulty nodes and faulty containers of the cloud platform.

[0169] Optionally, the information acquisition module is specifically used for: sending a deployment information acquisition instruction to the cloud platform when a detection instruction is received; acquiring the deployment information returned by the cloud platform in response to the deployment information acquisition instruction; and acquiring the node information and interface information of the cloud platform based on the deployment information.

[0170] Optionally, the node tree traversal module, when traversing the node tree level by level according to its hierarchical structure to determine the faulty nodes and faulty containers of the cloud platform, is specifically configured to: traverse each level of the node tree level by level from the bottom layer according to its hierarchical structure and in a bottom-up traversal manner to determine the faulty nodes and faulty containers of the cloud platform.

[0171] Optionally, based on the hierarchical structure of the node tree, data acquisition requests are triggered for multiple containers at the bottom layer of the node tree to obtain the return data of each container; containers whose return data does not meet the preset return data conditions are identified as faulty containers, and data acquisition requests are triggered for the parent node of each faulty container to obtain the return data of the parent node of each faulty container; if it is determined that the return data of the parent node of each faulty container meets the preset return data conditions, the traversal of the data transmission link where the faulty container is located is terminated.

[0172] Optionally, the fault detection device based on the cloud platform further includes a first operation and maintenance module, which, after traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, is configured to: determine corresponding pre-set state test cases based on the faulty nodes and the faulty containers; test the faulty nodes and the faulty containers respectively through each of the state test cases to obtain corresponding test results, wherein the test results are the state of the faulty nodes or faulty containers; determine the state identifiers of the faulty nodes and faulty containers based on a pre-stored node state table and each of the test results, wherein the node state table stores the state of nodes and containers and the corresponding state identifiers; and determine and output the operation and maintenance methods corresponding to the state identifiers of the faulty nodes and faulty containers based on a pre-stored first maintenance table, wherein the first maintenance table stores the state identifiers of the faulty nodes and faulty containers and the operation and maintenance methods corresponding to each state identifier.

[0173] Optionally, the fault detection device based on the cloud platform further includes a second operation and maintenance module. After traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the module is configured to: call the key functions of the faulty nodes and faulty containers stored in the functional interface database; send a third data acquisition request using pre-packaged functional test cases to access the interfaces of the key functions of the faulty nodes and faulty containers; obtain test data returned through the key functions of the faulty nodes and faulty containers, wherein the third data acquisition request includes the expected data structure to be returned, and the key functions are the functions most frequently used by containers and nodes for data transmission; compare the data structure of each test data with the expected data structure to determine whether the key functions of the faulty nodes and faulty containers are abnormal; in response to the abnormality of the key functions of the faulty nodes and faulty containers, determine the corresponding cause of the abnormality; and determine and output the corresponding operation and maintenance method based on the pre-stored second maintenance table and the cause of the abnormality, wherein the second maintenance table stores the cause of the abnormality when the key functions of the nodes and containers are abnormal, and the operation and maintenance method corresponding to each cause of the abnormality.

[0174] Optionally, the second maintenance module, when comparing the data structure of each test data with the expected returned data structure to determine whether the critical functions of the fault node and the fault container are abnormal, specifically performs the following steps: comparing the data structure of each test data with the expected returned data structure; determining whether the comparison results of the data structure of each test data with the expected returned data structure are the same; in response to the comparison results being different, determining that the critical functions of the fault node and the fault container are abnormal; in response to the comparison results being the same, determining that the critical functions of the fault node and the fault container are not abnormal.

[0175] Optionally, the cloud platform-based fault detection device further includes a third operation and maintenance module, used for: identifying faulty nodes and faulty containers whose return codes are not preset values ​​as abnormal nodes and abnormal containers, respectively; detecting the abnormal nodes and abnormal containers using preset detection tools to determine the network and / or hardware / software fault causes of the abnormal nodes and abnormal containers; determining and outputting the corresponding operation and maintenance methods based on a pre-stored third maintenance table and the fault causes, wherein the third maintenance table stores the fault causes when the network and / or hardware / software of nodes and containers fail, the fault categories to which each fault cause belongs, and the operation and maintenance methods corresponding to each fault category.

[0176] Figure 5 This is a block diagram illustrating a fault detection system according to an exemplary embodiment. The device may be as follows: Figure 5As shown, the fault detection system includes: a memory 51 and a processor 52; the memory 51 is a memory for storing processor-executable instructions; the processor 52 is used to run computer programs or instructions to implement the cloud-based fault detection method provided in any of the above embodiments.

[0177] The memory 51 is used to store programs. Specifically, the program may include program code, which includes computer operation instructions. The memory 51 may include high-speed RAM, and may also include non-volatile memory, such as at least one disk storage device.

[0178] The processor 52 may be a central processing unit (CPU), an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of this disclosure.

[0179] Optionally, in specific implementations, if the memory 51 and processor 52 are implemented independently, then the memory 51 and processor 52 can be interconnected via bus 53 to complete mutual communication. Bus 53 can be an Industry Standard Architecture (ISA) bus 53, a Peripheral Component Interconnect (PCI) bus 53, or an Extended Industry Standard Architecture (EISA) bus 53, etc. Bus 53 can be divided into address bus 53, data bus 53, control bus 53, etc. For ease of representation, Figure 5 The bus 53 is represented by a single thick line, but this does not mean that there is only one bus 53 or only one type of bus 53.

[0180] Optionally, in a specific implementation, if the memory 51 and the processor 52 are integrated on a single chip, then the memory 51 and the processor 52 can communicate with each other through an internal interface.

[0181] A non-transitory computer-readable storage medium, when the instructions in the storage medium are executed by the processor of a fault detection system, enables the fault detection system to perform the cloud-based fault detection method of the aforementioned fault detection system.

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

[0183] It should be understood that this application is not limited to the precise structure 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 application is limited only by the appended claims.

Claims

1. A fault detection method based on a cloud platform, characterized in that, The method, applied to a fault detection system, includes: Upon receiving a detection command, the node information and interface information of the cloud platform are obtained. The node information of the cloud platform includes the name and identifier of each level node, as well as the name and identifier of each container under the last level node. The interface information of the cloud platform includes the upstream and downstream relationships between the nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node when transmitting data. A node tree is generated based on the node information and interface information of the cloud platform. The node tree is a hierarchical structure representing the multi-level nodes of the cloud platform and the multiple containers corresponding to the last level node. The hierarchical structure of the node tree represents the upstream and downstream relationships between the nodes at each level of the cloud platform and between each node at the last level and each container under the last level node when data is transmitted. Based on the hierarchical structure of the node tree, the node tree is traversed level by level to determine the faulty nodes and faulty containers of the cloud platform. The step of traversing the node tree level by level according to its hierarchical structure to determine the faulty nodes and faulty containers of the cloud platform includes: Based on the hierarchical structure of the node tree and following a bottom-up traversal method, the node tree is traversed level by level from the bottom layer to determine the faulty nodes and faulty containers of the cloud platform.

2. The method according to claim 1, characterized in that, Upon receiving a detection command, the process of acquiring node and interface information from the cloud platform includes: Upon receiving a detection command, a deployment information retrieval command is sent to the cloud platform; Obtain the deployment information returned by the cloud platform in response to the deployment information acquisition command; Based on the deployment information, obtain the node information and interface information of the cloud platform.

3. The method according to claim 1, characterized in that, The step of traversing the node tree level by level, starting from the bottom layer and proceeding from the top, according to its hierarchical structure, to determine the faulty nodes and faulty containers of the cloud platform includes: Based on the hierarchical structure of the node tree, data acquisition requests are triggered for multiple containers at the bottom level of the node tree to obtain the return data from each container; Containers whose returned data does not meet the preset returned data conditions are identified as faulty containers, and data acquisition requests are triggered to the parent node of each faulty container to obtain the returned data of the parent node of each faulty container. If it is determined that the returned data of the parent node of each faulty container meets the preset returned data conditions, then the traversal of the data transmission link where the faulty container is located is terminated.

4. The method according to any one of claims 1-3, characterized in that, After traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the method further includes: Based on the faulty node and the faulty container, determine the corresponding pre-set state test cases; The faulty node and the faulty container are tested using each of the state test cases to obtain the corresponding test results, which are the state of the faulty node or the faulty container. Based on the pre-stored node status table and the test results, the status identifiers of the faulty node and the faulty container are determined. The node status table stores the status of the node and the container and the corresponding status identifier. Based on the pre-stored first maintenance table, the operation and maintenance methods corresponding to the status identifiers of the faulty node and the faulty container are determined and output. The first maintenance table stores the status identifiers of the faulty node and the faulty container and the operation and maintenance methods corresponding to each status identifier.

5. The method according to claim 4, characterized in that, Upon receiving a detection command, after obtaining the node information and interface information of the cloud platform, the process further includes: The node information and interface information of the cloud platform are stored in the functional interface database; After traversing the node tree to determine the faulty nodes and faulty containers of the cloud platform, the method further includes: The system calls the key functions of the fault node and the fault container stored in the functional interface database, and sends a third data acquisition request to access the interface of the key functions of the fault node and the fault container using pre-packaged functional test cases. The system obtains the test data returned by the key functions of the fault node and the fault container. The third data acquisition request includes the expected data structure to be returned. The key functions are the functions that the container and the node use most frequently for data transmission. The data structure of each test data is compared with the expected return data structure to determine whether the key functions of the fault node and the fault container are abnormal; In response to the abnormality of the critical functions of the faulty node and the faulty container, the corresponding cause of the abnormality is determined; Based on the pre-stored second maintenance table and the cause of the anomaly, the corresponding operation and maintenance method is determined and output. The second maintenance table stores the cause of anomalies when the key functions of nodes and containers are abnormal, and the operation and maintenance method corresponding to each cause of anomaly.

6. The method according to claim 5, characterized in that, The step of comparing the data structure of each test data with the expected returned data structure to determine whether the critical functions of the faulty node and the faulty container are abnormal includes: The data structure of each test data is compared with the expected return data structure; Determine whether the data structure of each test data is the same as the expected returned data structure; In response to the discrepancy in the comparison results, it is determined that the critical functions of the faulty node and the faulty container are abnormal. If the comparison results are the same, it is determined that the critical functions of the faulty node and the faulty container are not abnormal.

7. The method according to claim 5, characterized in that, After obtaining the node information and interface information of the cloud platform upon receiving the detection command, the method further includes: Nodes and containers whose return codes are not preset values ​​are identified as abnormal nodes and abnormal containers, respectively. The abnormal nodes and abnormal containers are detected by a preset detection tool to determine the cause of network and / or hardware and software failures of the abnormal nodes and abnormal containers. Based on the pre-stored third maintenance table and the cause of the failure, the corresponding operation and maintenance method is determined and output. The third maintenance table stores the cause of failure when the network and / or hardware and software of the node and container fail, the failure category to which each failure cause belongs, and the operation and maintenance method corresponding to each failure category.

8. A fault detection device based on a cloud platform, characterized in that, Located in the fault detection system, the device includes: The information acquisition module is used to acquire the node information and interface information of the cloud platform when a detection command is received. The node information of the cloud platform includes the name and identifier of each level node, and the name and identifier of each container under the last level node. The interface information of the cloud platform includes the upstream and downstream relationships between the nodes at all levels of the cloud platform, and between each node at the last level and each container under the last level node when data is transmitted. The node tree generation module is used to generate a node tree based on the node information and interface information of the cloud platform. The node tree is a hierarchical structure of the cloud platform, representing the multi-level nodes and the multiple containers corresponding to the last-level node. The hierarchical structure of the node tree represents the upstream and downstream relationships between the nodes at each level of the cloud platform and between the last-level nodes and the containers under the last-level nodes when transmitting data. The node tree traversal module is used to traverse the node tree level by level according to its hierarchical structure in order to determine the faulty nodes and faulty containers of the cloud platform. The node tree traversal module, when traversing the node tree level by level according to its hierarchical structure to determine the faulty nodes and faulty containers of the cloud platform, is specifically used for: Based on the hierarchical structure of the node tree and following a bottom-up traversal method, the node tree is traversed level by level from the bottom layer to determine the faulty nodes and faulty containers of the cloud platform.

9. A fault detection system, comprising: A processor, and a memory communicatively connected to the processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the method as described in any one of claims 1-7.

11. A computer program product comprising a computer program that, when executed by a processor, implements the method of any one of claims 1-7.

Citation Information

Patent Citations

  • PaaS cloud platform fault test method and device

    CN113157577A

  • Method and device for detecting fault in micro-service architecture, and storage medium

    CN113760636A

  • Topological structure detection method and device, equipment and storage medium

    CN113918428A