Distributed system fault judgment and recovery method, cloud operating system and computing platform using the method

By combining Apache Mesos and Corosync with deep learning technology, we can accurately determine the fault nodes of the distributed system and generate recovery difficulty reports, which solves the problems of inaccurate fault detection and insufficient recovery difficulty prediction in traditional methods, and improves the stability and reliability of the system. .

CN118331779BActive Publication Date: 2024-09-10GUANGDONG QINZHI SCIENCE & TECHNOLOGY RESEARCH INSTITUTE
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410754127.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-12
Publication Date
2024-09-10
Estimated Expiration
2044-06-12

AI Technical Summary

Technical Problem

Traditional distributed system fault detection methods are not accurate enough in assessing the health status of nodes, resulting in some faulty nodes not being repaired in time, affecting system performance and reliability, and the difficulty of predicting the recovery of faulty nodes needs to be improved.

Method used

Use Apache Mesos as the resource manager, combined with Corosync to obtain cluster node status data, use deep learning technology and distributed consistency algorithms to determine faulty nodes, and calculate health index through feature extraction and health prediction models, generate recovery difficulty reports, real-time monitoring and Visualize failed node status.

Benefits of technology

It improves the accuracy and scientificity of the health status assessment of failed nodes, provides a more reliable prediction of recovery difficulty, ensures that the system continues to operate under normal conditions of most nodes, reduces fault spread and maintenance costs, and improves system stability and reliability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118331779B
    Figure CN118331779B
Patent Text Reader

Abstract

The present invention discloses a method for fault judgment and recovery of a distributed system, a cloud operating system and a computing platform applying the method, and relates to the technical field of fault judgment. Corosync is used to obtain the status data information of several groups of nodes in a cluster, and in combination with a distributed consistency algorithm, the faulty nodes are accurately judged and marked accordingly. This method ensures that the system can monitor the node status in real time, quickly identify the faulty nodes, and avoid the overall performance of the system being reduced due to the failure of a single node. By detecting the operation data information of relevant resources and the disk status data information in the distributed operating system, a health impact set is constructed. Through these comprehensive data collection and analysis, the health status of each faulty node can be more accurately evaluated, providing a more accurate prediction of the difficulty of recovery. The health impact set is extracted and analyzed and calculated using deep learning technology combined with a trained health prediction model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of fault judgment, and specifically to a distributed system fault judgment and recovery method, a cloud operating system and a computing platform applying the method. Background Art

[0002] In the field of modern computing technology, distributed systems, as an important computing architecture, improve the scalability and fault tolerance of the system by distributing resources on multiple nodes. Specifically in the field of distributed operating systems, such systems need to handle resource allocation, management, and task scheduling to ensure the efficient operation of the entire system and the rational use of resources.

[0003] In such a system, ensuring the normal operation of each node is the key. Therefore, how to accurately determine the fault status of the node and recover it in time has become an important research direction in distributed systems. However, traditional fault detection methods are not accurate enough in assessing the health status of nodes, and may not be able to fully reflect the health status of the nodes, resulting in some faulty nodes not being repaired in time, affecting the overall performance and reliability of the system. In addition, the difficulty of recovering predicted faulty nodes also needs to be improved. Summary of the invention

[0004] In view of the deficiencies in the prior art, the present invention provides a distributed system fault diagnosis and recovery method, a cloud operating system and a computing platform applying the method, which solve the problems in the above-mentioned background technology.

[0005] To achieve the above objectives, the present invention is implemented through the following technical solutions: a distributed system fault judgment and recovery method, comprising the following steps:

[0006] S1. Use Apache Mesos as a resource manager to build a virtual resource pool, and use Mesos as the kernel of the distributed operating system to handle resource allocation and centrally manage the cluster;

[0007] S2. In a distributed operating system, based on Corosync, obtain relevant status data information of several groups of nodes in the cluster, and construct a node data set. Based on the node data set and in combination with a distributed consistency algorithm, determine several groups of faulty nodes and make corresponding marks.

[0008] S3, according to the groups of faulty nodes obtained in step S2, detecting the operation data information of related resources and the disk status data information in the distributed operating system to construct a health impact set;

[0009] S4, extracting features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz and number of I / O errors Cwp of the corresponding faulty node respectively, and using deep learning technology and combining it with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and by associating the resource usage coefficient Zsxs and the disk status coefficient Czxs, fitting and obtaining the health index Jkzs of the corresponding faulty node;

[0010] S5. Preset a prediction threshold Q, and compare and analyze the prediction threshold Q with the health index Jkzs of the corresponding faulty node, comprehensively predict the difficulty report of the current faulty node recovery, and present it in a visual form on the computing platform.

[0011] Preferably, based on Corosync, cluster information and heartbeat information are transmitted in real time to obtain relevant status data information of several groups of nodes in the cluster and construct a node data set, wherein the node data set includes the number of nodes in the cluster Jdsz, the timestamp of each node sending a heartbeat signal, and the timestamp of each node receiving a heartbeat signal.

[0012] Preferably, a fixed time interval TzTz is set, and each sending node in the cluster sends a heartbeat signal to the receiving node at a fixed time interval TzTz to indicate that it is active. After the receiving node in the cluster receives the heartbeat signal of the sending node, it records the timestamp of receiving the heartbeat;

[0013] Based on the received heartbeat timestamp, the receiving node makes a preliminary judgment on whether the sending node has a failure risk. The specific preliminary judgment contents are as follows:

[0014] If the nth sending timestamp - the n-1th sending timestamp > the fixed time interval TzTz, the receiving node will preliminarily determine that the sending node has a failure risk and mark the sending node as a judgment node;

[0015] If the nth sending timestamp - the n-1th sending timestamp ≤ the fixed time interval TzTz, the receiving node will preliminarily determine that there is no risk of failure in the sending node.

[0016] Preferably, when the receiving node preliminarily determines that the sending node has a risk of failure, the receiving node will send a voting request to the cluster for comprehensive judgment, the specific contents are as follows:

[0017] The node that receives the voting request will analyze whether the current judgment node has a risk of failure based on the timestamp of the heartbeat signal it has recently received from the judgment node. When the node that receives the vote analyzes that the judgment node has a risk of failure, it returns the instruction and issues a positive vote. When the node that receives the vote analyzes that the judgment node does not have a risk of failure, it returns the instruction and issues a negative vote.

[0018] According to the positive votes and negative votes made by the node that received the voting request, the number of positive votes Kts and the number of negative votes Fts are obtained;

[0019] If the number of positive votes Kts> the number of negative votes Fts, the node is analyzed as a faulty node and marked accordingly for further analysis;

[0020] If the number of positive votes Kts ≤ the number of negative votes Fts, the node is analyzed as a non-faulty node.

[0021] Preferably, the number of faulty nodes Gj is obtained according to the marked faulty nodes, and the fault ratio Gjs is calculated according to the number of nodes Jdsz in the cluster, and the relevant resource operation data information and disk status data information in the distributed operating system are detected at the same time to construct a health impact set, which includes the relevant resource operation data information and disk status data information;

[0022] The relevant resource operation data information includes CPU usage Csz, memory usage Nsi, disk usage Csyz and operating temperature;

[0023] The disk status data information includes the number of bad blocks at each monitoring time point within the monitoring cycle The number of I / O errors Cwp at each monitoring time point in the monitoring cycle, and the statistical mean algorithm is used to obtain the mean number of bad blocks in the monitoring cycle. And the average number of I / O errors during the monitoring period ;

[0024] At the same time, a convolutional neural network is used to build a primary model, and the primary model is trained and tested with relevant resource operation data information and disk status data information. The trained preliminary model is used as an information recognition model, and the feature information therein is obtained respectively. The information recognition model is trained and tested with the obtained feature information. Combined with the obtained fault proportion Gjs, the trained information recognition model is used as a health prediction model.

[0025] Preferably, according to the health prediction model, combined with deep learning technology, the resource usage coefficient Zsxs and the disk status coefficient Czxs are calculated and obtained respectively, and the resource usage coefficient Zsxs and the disk status coefficient Czxs are obtained respectively by the following formulas:

[0026] ;

[0027] In the formula, and is the weight coefficient, Csz represents the CPU usage, Csyz represents the disk usage, Nsi represents the memory usage, and V represents the first correction constant;

[0028] ;

[0029] Where n is the number of monitoring time points, i=1, 2, 3, ..., n, It is expressed as the number of bad blocks at the i-th monitoring time point, It is expressed as the mean number of bad blocks in the monitoring period. It is expressed as the number of I / O errors at the i-th monitoring time point, It is expressed as the average number of I / O errors during the monitoring period.

[0030] Preferably, the resource usage coefficient Zsxs and the disk status coefficient Czxs are linearly normalized and the corresponding data values ​​are mapped to the interval The health index Jkzs of the corresponding fault node is obtained by fitting. The health index Jkzs of the corresponding fault node is obtained by the following formula:

[0031] ;

[0032] Where Ccn is the TCP retransmission rate, Gjs is the failure rate, and e is the Euler number, which is approximately 2.71828.

[0033] Preferably, the prediction threshold Q is compared and analyzed with the health index Jkzs of the corresponding fault node, and a recovery difficulty report of the current fault node is comprehensively predicted, and the specific contents are as follows:

[0034] If the health index Jkzs of the corresponding faulty node is ≥ the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in an abnormal state. At this time, the corresponding faulty node is isolated from the cluster, and the task allocation and data communication of the faulty node are stopped, and an early warning instruction is sent to the system administrator. The backup node in the distributed storage system is then used to restore the data on the faulty node, and the tasks and data on the faulty node are reallocated to the backup node. At this time, the backup node will take over the responsibilities of the faulty node within 5 seconds and try to perform automated fault repair operations. If the automated repair is invalid, wait for the system administrator to intervene manually.

[0035] If the health index Jkzs of the corresponding faulty node is less than the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in a normal state. At this time, an attempt is made to automatically repair the faulty node. The automatic repair means include restarting the node, restoring the configuration, and reloading the service, and monitoring the repair process. After the faulty node is restored, a distributed consistency protocol is used for data synchronization and consistency verification. After the faulty node is restored, a health status verification is performed to confirm that the node has been restored to a normal state and can run stably. After the faulty node is restored to normal, the faulty node is rejoined to the cluster, and tasks and resources are reallocated.

[0036] A cloud operating system includes a construction module, a first monitoring module, a fault locking module, a second monitoring module, a health assessment module and a prediction management module;

[0037] The construction module uses Apache Mesos as a resource manager to build a virtual resource pool, and uses Mesos as the kernel of a distributed operating system to handle resource allocation and centrally manage clusters;

[0038] The first monitoring module, in a distributed operating system, obtains relevant status data information of several groups of nodes in the cluster according to Corosync, and constructs a node data set;

[0039] The fault locking module determines several groups of faulty nodes based on the node data set and combines the distributed consistency algorithm, and makes corresponding marks;

[0040] The second monitoring module detects the operation data information of related resources and the disk status data information in the distributed operating system according to the groups of fault nodes obtained in step S2, so as to construct a health impact set;

[0041] The health assessment module extracts features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz, and number of I / O errors Cwp of the corresponding faulty node, and uses deep learning technology in combination with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and associates the resource usage coefficient Zsxs with the disk status coefficient Czxs to obtain the health index Jkzs of the corresponding faulty node.

[0042] The prediction management module pre-sets a prediction threshold Q, and compares and analyzes the prediction threshold Q with the health index Jkzs of the corresponding fault node, comprehensively predicts the difficulty report of the current fault node recovery, and presents it in a visual form on the computing platform.

[0043] A computing platform, comprising at least a processor, a memory and an input-output unit;

[0044] The memory is used to store computer programs, and the processor is used to call the computer programs stored in the memory to execute the distributed system fault judgment and recovery method.

[0045] The present invention provides a distributed system fault judgment and recovery method, a cloud operating system and a computing platform applying the method, which have the following beneficial effects:

[0046] (1) Use Corosync to obtain the status data information of several groups of nodes in the cluster, and combine it with the distributed consistency algorithm to accurately determine the faulty nodes and make corresponding marks. This method ensures that the system can monitor the node status in real time, quickly identify the faulty nodes, and avoid the overall performance of the system being degraded due to the failure of a single node. By detecting the relevant resource operation data information and disk status data information in the distributed operating system, a health impact set is constructed. Through this comprehensive data collection and analysis, the health status of each faulty node can be more accurately evaluated, providing a more accurate prediction of the difficulty of recovery. Using deep learning technology combined with the trained health prediction model, the health impact set is feature extracted and analyzed to obtain the resource usage coefficient Zsxs and the disk status coefficient Czxs, and the health index Jkzs is fitted. This method improves the accuracy and scientificity of the health status assessment of the faulty node, making the prediction results more reliable. By comparing and analyzing the prediction threshold with the health index, the recovery capability of the faulty node is comprehensively predicted, and a recovery difficulty report is generated and displayed in a visual form. This method provides system administrators with an intuitive and clear fault node recovery capability assessment report, helping them make more scientific decisions and improve the system's maintenance efficiency and fault tolerance. Through the above method, by timely monitoring the faulty nodes and taking corresponding measures, it is possible to further ensure that the system can continue to operate normally when most nodes are normal. Even if some nodes fail, their recovery capabilities can be quickly detected and evaluated, and corresponding measures can be taken to recover or isolate them to avoid the spread of the failure, thereby greatly improving the stability and reliability of the system.

[0047] (2) When the receiving node preliminarily determines that a certain node has a risk of failure, it sends a voting request to the cluster to achieve information exchange and coordination among cluster members. This voting mechanism helps maintain the consistency of the cluster and ensures accurate reflection and comprehensive judgment of the node status. The node that receives the voting request quickly analyzes whether the current node has a risk of failure based on the timestamp of the most recently received heartbeat signal, and makes a positive or negative vote. Through the rapid response and comprehensive judgment of cluster members, the existence of the faulty node can be quickly confirmed, further reducing the time and cost of fault diagnosis. According to the number of positive and negative votes received, the failure risk of the node is comprehensively evaluated. This comprehensive judgment can improve the accuracy and reliability of fault judgment and avoid misjudgment caused by individual node errors. Through rapid fault confirmation and accurate fault marking, the system can timely identify and isolate the faulty node to avoid the spread of faults affecting the entire system. This effective fault handling mechanism can improve the stability and availability of the system and ensure that the system can continue to operate normally in the event of a fault. In summary, this method uses majority voting to comprehensively judge whether the faulty node has a risk of failure, which can ensure that the system continues to operate when most nodes are normal. At the same time, by evaluating the health status of the faulty nodes, the difficulty of node recovery can be accurately predicted, thus providing protection for the stability and reliability of the system.

[0048] (3) Through strict time interval judgment criteria, the false alarm rate is reduced, and the misjudgment caused by network delays or instantaneous fluctuations is further reduced, thereby improving the accuracy of fault judgment. Through the rapid preliminary judgment and marking of node failure risks, timely measures can be taken to further reduce the impact of faulty nodes on the normal operation of the entire system. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 A schematic diagram of the steps of the distributed system fault judgment and recovery method of the present invention;

[0050] Figure 2 This is a schematic diagram of a cloud operating system process in which a distributed failure of the present invention can be used to recover and determine the cloud operating system. DETAILED DESCRIPTION

[0051] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention. Example

[0052] See also Figure 1The present invention provides a distributed system fault judgment and recovery method, comprising the following steps:

[0053] S1. Use Apache Mesos as a resource manager to build a virtual resource pool, and use Mesos as the kernel of the distributed operating system to handle resource allocation and centrally manage the cluster;

[0054] S2. In a distributed operating system, based on Corosync, obtain relevant status data information of several groups of nodes in the cluster, and construct a node data set. Based on the node data set and in combination with a distributed consistency algorithm, determine several groups of faulty nodes and make corresponding marks.

[0055] S3, according to the groups of faulty nodes obtained in step S2, detecting the operation data information of related resources and the disk status data information in the distributed operating system to construct a health impact set;

[0056] S4, extracting features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz and number of I / O errors Cwp of the corresponding faulty node respectively, and using deep learning technology and combining it with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and by associating the resource usage coefficient Zsxs and the disk status coefficient Czxs, fitting and obtaining the health index Jkzs of the corresponding faulty node;

[0057] S5. Preset a prediction threshold Q, and compare and analyze the prediction threshold Q with the health index Jkzs of the corresponding faulty node, comprehensively predict the difficulty report of the current faulty node recovery, and present it in a visual form on the computing platform.

[0058] In the present embodiment, in step S1, Apache Mesos is used as a resource manager to build a virtual resource pool, and Mesos is used as the kernel of a distributed operating system to handle resource allocation and centrally manage clusters. This step further realizes efficient management and allocation of resources, further ensures the optimal use of system resources, and provides a stable basis for subsequent fault detection and recovery. In step S2, relevant status data information of several groups of nodes in the cluster is obtained through Corosync, and a node data set is constructed. Combined with a distributed consistency algorithm, several groups of faulty nodes can be accurately judged and corresponding marks can be made. This step improves the accuracy of fault detection and further ensures that the system can identify and respond to faulty nodes in a timely manner. In step S3, according to the detected faulty nodes, the relevant resource operation data information and disk status data information in the distributed operating system are obtained, and a health impact set is constructed. Through multi-dimensional data collection, the health status of the faulty nodes is comprehensively evaluated, providing a rich information basis for subsequent recovery judgment. In step S4, by extracting features from the health impact set, combining deep learning technology, and using the trained health prediction model, the computing resource usage coefficient Zsxs and the disk status coefficient Czxs are analyzed, and these coefficients are associated to fit the health index Jkzs of the corresponding faulty node. This step uses advanced deep learning methods to improve the accuracy and reliability of health status prediction. In step S5, by pre-setting the prediction threshold Q, it is compared and analyzed with the health index Jkzs of the corresponding faulty node, and the recovery difficulty report of the current faulty node is comprehensively predicted, and displayed in a visual form on the computing platform. This step provides an intuitive fault recovery difficulty assessment, so that the system administrator can quickly understand the recovery difficulty of the faulty node, so as to take appropriate measures to ensure that the system can still operate normally when most nodes are normal. In short, this method further realizes the accurate detection and comprehensive evaluation of faulty nodes in distributed systems, and improves the accuracy of health status prediction through deep learning technology. This method not only ensures the stable operation of the system, but also significantly improves the efficiency and reliability of faulty node recovery judgment, and has broad application prospects and practical value. Example

[0059] Please refer to Figure 1 Specifically: Based on Corosync, cluster information and heartbeat information are transmitted in real time to obtain relevant status data information of several groups of nodes in the cluster, and a node data set is constructed, where the node data set includes the number of nodes in the cluster Jdsz, the timestamp of each node sending a heartbeat signal, and the timestamp of each node receiving a heartbeat signal.

[0060] Set a fixed time interval TzTz. Each sending node in the cluster sends a heartbeat signal to the receiving node at a fixed time interval TzTz to indicate that it is active. After receiving the heartbeat signal from the sending node, the receiving node in the cluster records the timestamp of receiving the heartbeat.

[0061] Based on the received heartbeat timestamp, the receiving node makes a preliminary judgment on whether the sending node has a failure risk. The specific preliminary judgment contents are as follows:

[0062] If the nth sending timestamp - the n-1th sending timestamp > the fixed time interval TzTz, the receiving node will preliminarily determine that the sending node has a failure risk and mark the sending node as a judgment node;

[0063] If the nth sending timestamp - the n-1th sending timestamp ≤ the fixed time interval TzTz, the receiving node will preliminarily determine that there is no risk of failure in the sending node.

[0064] In the present embodiment, cluster information and heartbeat information are transmitted in real time by Corosync, the status data of nodes in the cluster are obtained, and a node data set is constructed. This method realizes real-time monitoring of node status, can quickly and accurately grasp the running status of each node, and provides reliable data support for fault detection. A fixed time interval TzTz is set, and each sending node sends a heartbeat signal to the receiving node at a fixed time interval TzTz. The receiving node can accurately detect the active state of the node by recording the timestamp of the heartbeat signal and comparing the time interval between two consecutive transmissions. If the time interval between two consecutive heartbeat signals exceeds the preset fixed time interval TzTz, the receiving node can preliminarily judge in time that the sending node has a fault risk. This accurate time interval detection method greatly improves the accuracy and timeliness of fault detection. By comparing the time interval of the heartbeat signal of the sending node, the receiving node can quickly preliminarily judge the fault risk of the sending node. If the time interval exceeds the preset range, the sending node can be marked as a fault risk node. This method is simple and efficient, can quickly identify potential fault nodes, reduce the fault response time of the system, and improve the overall stability of the system. Only when the difference between two consecutive timestamps sent by the sending node exceeds a fixed time interval TzTz, the receiving node preliminarily determines that there is a risk of failure, otherwise it is judged to be normal. This method significantly improves the fault tolerance and stability of the system, ensuring that the system can work continuously and efficiently when most nodes are operating normally. In summary, the present invention realizes a rapid preliminary judgment of the risk of node failure in a distributed system through precise heartbeat signal time interval detection and real-time monitoring. This method has the advantages of high efficiency, accuracy, and real-time, and provides a strong technical guarantee for the stable operation and fault recovery of the system. Example

[0065] Please refer to Figure 1 Specifically: When the receiving node initially determines that the sending node has a risk of failure, the receiving node will send a voting request to the cluster for a comprehensive judgment. The specific contents are as follows:

[0066] The node that receives the voting request will analyze whether the current judgment node has a risk of failure based on the timestamp of the heartbeat signal it has recently received from the judgment node. When the node that receives the vote analyzes that the judgment node has a risk of failure, it returns the instruction and issues a positive vote. When the node that receives the vote analyzes that the judgment node does not have a risk of failure, it returns the instruction and issues a negative vote.

[0067] According to the positive votes and negative votes made by the node that received the voting request, the number of positive votes Kts and the number of negative votes Fts are obtained;

[0068] If the number of positive votes Kts> the number of negative votes Fts, the node is analyzed as a faulty node and marked accordingly for further analysis;

[0069] If the number of positive votes Kts ≤ the number of negative votes Fts, the node is analyzed as a non-faulty node.

[0070] In this embodiment, by sending a voting request to the cluster, a more accurate judgment of the faulty node is achieved by using the comprehensive judgment of multiple nodes in the cluster. Each node analyzes the fault risk of the judgment node based on its own heartbeat signal timestamp and status data, reaches a consensus through comprehensive voting, gives full play to collective wisdom, and improves the accuracy and reliability of judgment. According to the statistics of the number of positive votes Kts and the number of negative votes Fts of the nodes in the cluster on the judgment node, it can be accurately judged whether the node has a fault risk. When the number of positive votes Kts is much greater than the number of negative votes Fts, the judgment node can be determined to be a faulty node, which is convenient for subsequent fault processing and repair. This accurate fault judgment can effectively improve the stability and availability of the system. Once the judgment node is determined to be a faulty node, the system can make corresponding marks in time and take corresponding measures to isolate or recover the fault. Through the comprehensive voting of the nodes in the cluster, the faulty node can be quickly confirmed, misjudgment and delay can be avoided, and the timeliness and effectiveness of the fault response can be improved. Through multiple voting and comprehensive judgment of the nodes in the cluster, the subjective misjudgment of a single node can be avoided from affecting the overall judgment result. Each node in the cluster makes an independent judgment based on its own status data, and reaches a consensus through comprehensive voting, which reduces the misjudgment rate and ensures the accuracy and credibility of the judgment results. Fault judgment through the voting mechanism can effectively deal with the failure of nodes in the cluster and improve the fault tolerance and stability of the system. Both the isolation and recovery of faulty nodes can be carried out in a timely manner, ensuring that the system can still maintain stable operation when most nodes are normal. In summary, the present invention realizes the comprehensive judgment of faulty nodes by nodes in the cluster through the voting mechanism, and has the beneficial effects of accuracy, timeliness and reliability, and provides effective technical support for fault handling and recovery of distributed systems. Example

[0071] Please refer to Figure 1 Specifically: the number of faulty nodes Gj is obtained according to the marked faulty nodes, and the fault ratio Gjs is calculated according to the number of nodes Jdsz in the cluster, and at the same time, the relevant resource operation data information and disk status data information in the distributed operating system are detected to construct a health impact set, which includes the relevant resource operation data information and disk status data information;

[0072] The relevant resource operation data information includes CPU usage Csz, memory usage Nsi, disk usage Csyz and operating temperature;

[0073] The CPU usage rate Csz and the memory usage rate Nsi can be monitored and obtained through system monitoring tools and performance monitoring platforms. System monitoring tools include but are not limited to "top" or "htop" on Linux, and performance monitoring platforms include but are not limited to Prometheus and Nagios.

[0074] The disk usage Csyz can be monitored and obtained using a file system monitoring tool and a performance monitoring platform, wherein the file system monitoring tool includes but is not limited to df, iostat, and du;

[0075] The disk status data information includes the number of bad blocks at each monitoring time point within the monitoring cycle The number of I / O errors Cwp at each monitoring time point in the monitoring cycle, and the statistical mean algorithm is used to obtain the mean number of bad blocks in the monitoring cycle. And the average number of I / O errors during the monitoring period ;

[0076] Number of bad blocks It can be monitored and obtained through hard disk monitoring tools and performance monitoring platforms;

[0077] The number of I / O errors Cwp is monitored and obtained through system logs and I / O monitoring tools; the I / O monitoring tools include iostat;

[0078] At the same time, a convolutional neural network is used to build a primary model, and the primary model is trained and tested with relevant resource operation data information and disk status data information. The trained preliminary model is used as an information recognition model, and the feature information therein is obtained respectively. The information recognition model is trained and tested with the obtained feature information. Combined with the obtained fault proportion Gjs, the trained information recognition model is used as a health prediction model.

[0079] In this embodiment, the constructed health impact set includes various related resource operation data information and disk status data information. These data dimensions are comprehensive and can fully reflect the health status of the node, providing rich features for the subsequent health prediction model. The primary model is constructed using a convolutional neural network. Through training and testing, the features in the related resource operation data information and disk status data information can be effectively extracted. This feature extraction method has high adaptability and nonlinear fitting capabilities, and can capture the potential laws and related information in the data. Using the trained preliminary model as an information recognition model, the feature information is trained and tested, and an accurate health prediction model is constructed in combination with the proportion of faulty nodes. This model combines various health influencing factors and can accurately predict the health status of the node, providing an important reference for system administrators. Through the comprehensive analysis of multi-dimensional data and the feature extraction of convolutional neural networks, the health status of the node can be more accurately identified. This helps to improve the accuracy and timeliness of fault diagnosis, enabling system administrators to respond and handle fault conditions more quickly and reduce the impact of system failures on business. By constructing a health impact set and training a health prediction model, dynamic monitoring and prediction of the health status of the system can be achieved. System administrators can monitor the health status of nodes in real time, discover potential failure risks in time, take preventive measures, and ensure the stable operation of the system. In summary, this method achieves accurate prediction and dynamic monitoring of the health status of distributed system nodes by constructing a comprehensive set of health impacts and using convolutional neural networks to build a health prediction model, providing important guarantees for the stability and reliability of the system. Example

[0080] Please refer to Figure 1 Specifically: According to the health prediction model and combined with deep learning technology, the resource usage coefficient Zsxs and the disk status coefficient Czxs are calculated and obtained respectively. The resource usage coefficient Zsxs and the disk status coefficient Czxs are obtained respectively by the following formulas:

[0081] ;

[0082] In the formula, and is the weight coefficient, Csz is the CPU usage, Csyz is the disk usage, Nsi is the memory usage, and V is the first correction constant, where 0< ≤1,0< ≤1, and + =1; the weight coefficient can be obtained by referring to the hierarchical analysis method;

[0083] ;

[0084] Where n is the number of monitoring time points, i=1, 2, 3, ..., n, It is expressed as the number of bad blocks at the i-th monitoring time point, It is expressed as the mean number of bad blocks in the monitoring period. It is expressed as the number of I / O errors at the i-th monitoring time point, It is expressed as the average number of I / O errors during the monitoring period.

[0085] In this embodiment, by calculating and obtaining the resource usage coefficient Zsxs and the disk status coefficient Czxs according to the health prediction model, combined with deep learning technology, the health status of the cluster nodes can be accurately evaluated. The resource usage coefficient Zsxs and the disk status coefficient Czxs comprehensively consider multiple factors and provide a scientific basis for the comprehensive evaluation of the health status. Using multiple indicators to calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs fully considers the multi-dimensional health information of the cluster nodes. This multi-dimensional health indicator helps to fully understand the health status of the nodes, discover potential health problems, and provide an important reference for fault prevention and maintenance. Example

[0086] Please refer to Figure 1 Specifically: after linear normalization of the resource usage coefficient Zsxs and the disk status coefficient Czxs, the corresponding data value is mapped to the interval The health index Jkzs of the corresponding fault node is obtained by fitting. The health index Jkzs of the corresponding fault node is obtained by the following formula:

[0087] ;

[0088] Where Ccn is the TCP retransmission rate, Gjs is the failure rate, and e is the Euler number, which is approximately 2.71828.

[0089] The TCP retransmission rate can be monitored and obtained through network monitoring tools and network performance monitoring platforms. Network monitoring tools include but are not limited to tcpdump; network performance monitoring platforms include Prometheus combined with node-exporter;

[0090] The prediction threshold Q is compared with the health index Jkzs of the corresponding faulty node to comprehensively predict the recovery difficulty report of the current faulty node. The specific contents are as follows:

[0091] If the health index Jkzs of the corresponding faulty node is ≥ the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in an abnormal state. At this time, the corresponding faulty node is isolated from the cluster to prevent it from affecting the normal operation of other nodes, and the faulty node is marked as unavailable, and the task allocation and data communication of the faulty node are stopped. At the same time, an early warning instruction is sent to the system administrator, detailing the status and specific problems of the faulty node, and recording the fault log for subsequent analysis and troubleshooting; the backup node in the distributed storage system is then used to restore the data on the faulty node, and the tasks and data on the faulty node are reallocated to the backup node. At this time, the backup node will take over the responsibilities of the faulty node within 5 seconds to ensure that the system tasks can continue to be executed, and try to perform automated fault repair operations. If the automated repair is invalid, wait for the system administrator to intervene manually;

[0092] If the health index Jkzs of the corresponding faulty node is less than the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in a normal state. At this time, the faulty node is automatically repaired. The automatic repair means include restarting the node, restoring the configuration, and reloading the service. The repair process is monitored to ensure that the faulty node can recover normally and rejoin the cluster after repair. After the faulty node is restored, a distributed consistency protocol (such as Paxos or Raft) is used for data synchronization and consistency verification to ensure that the node data is consistent with other nodes. After the faulty node is restored, the health status is verified to confirm that the node has returned to a normal state and can run stably. Perform node health checks regularly to ensure the stability and reliability of the node's long-term operation. After the faulty node is restored to normal, the faulty node is rejoined to the cluster and tasks and resources are reallocated.

[0093] It should be noted that the hierarchical analysis method is a combination of qualitative and quantitative analysis methods. It can decompose complex problems into multiple levels. By comparing the importance of factors at each level, it can help decision makers make decisions on complex issues and determine the final decision plan. In this process, the hierarchical analysis method can be used to determine the weight coefficients of these indicators.

[0094] In this embodiment, by comparing the health index Jkzs of the faulty node with the predicted threshold Q, the recovery capability status of the faulty node can be quickly determined. If the health index Jkzs is greater than or equal to the predicted threshold Q, it indicates that the recovery capability of the faulty node is abnormal, and the faulty node needs to be isolated immediately to prevent it from affecting the normal operation of other nodes. At the same time, the backup node of the distributed storage system is used to restore the data on the faulty node to ensure that the system task can continue to be executed. This fast fault recovery can reduce the downtime of the system and improve the availability and stability of the system. If the health index Jkzs of the faulty node is lower than the predicted threshold Q, it indicates that its recovery capability is in a normal state, and the faulty node can be automatically repaired. The automatic repair means include restarting the node, restoring the configuration, and reloading the service. Through the automated fault repair operation, the normal operation status of the faulty node can be quickly restored, which reduces the manual intervention cost of the system administrator and improves the automation and efficiency of the system. After the faulty node is restored, the distributed consistency protocol is used for data synchronization and consistency verification to ensure that the node data is consistent with other nodes. This data consistency guarantee can avoid data loss or damage, and ensure the data integrity and consistency of the system, and improve the reliability and stability of the system. Regular node health checks are performed to ensure the stability and reliability of the long-term operation of the node. By continuously monitoring and verifying the health status of the faulty nodes, potential problems can be discovered in time and corresponding measures can be taken to ensure the continuous and stable operation of the system. In short, this method makes a comprehensive prediction based on the health index Jkzs of the faulty node, which can quickly and automatically restore the faulty node, ensure data consistency, ensure the stability and availability of the system, and improve the robustness and operation efficiency of the system. Example

[0095] Please refer to Figure 1 and Figure 2 ,Specifically: A cloud operating system includes a building module, a first monitoring module, a fault locking module, a second monitoring module, a health assessment module, and a prediction management module;

[0096] The construction module uses Apache Mesos as a resource manager to build a virtual resource pool, and uses Mesos as the kernel of a distributed operating system to handle resource allocation and centrally manage clusters;

[0097] The first monitoring module, in a distributed operating system, obtains relevant status data information of several groups of nodes in the cluster according to Corosync, and constructs a node data set;

[0098] The fault locking module determines several groups of faulty nodes based on the node data set and combines the distributed consistency algorithm, and makes corresponding marks;

[0099] The second monitoring module detects the operation data information of related resources and the disk status data information in the distributed operating system according to the groups of fault nodes obtained in step S2, so as to construct a health impact set;

[0100] The health assessment module extracts features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz, and number of I / O errors Cwp of the corresponding faulty node, and uses deep learning technology in combination with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and associates the resource usage coefficient Zsxs with the disk status coefficient Czxs to obtain the health index Jkzs of the corresponding faulty node.

[0101] The prediction management module pre-sets a prediction threshold Q, and compares and analyzes the prediction threshold Q with the health index Jkzs of the corresponding fault node, comprehensively predicts the difficulty report of the current fault node recovery, and presents it in a visual form on the computing platform.

[0102] A computing platform, comprising at least a processor, a memory and an input-output unit;

[0103] The memory is used to store computer programs, and the processor is used to call the computer programs stored in the memory to execute the distributed system fault judgment and recovery method.

[0104] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A distributed system fault judgment and recovery method, characterized in that: The following steps are included: S1. Use Apache Mesos as a resource manager to build a virtual resource pool, and use Mesos as the kernel of the distributed operating system to handle resource allocation and centrally manage the cluster; S2. In a distributed operating system, based on Corosync, obtain relevant status data information of several groups of nodes in the cluster, and construct a node data set. Based on the node data set and in combination with a distributed consistency algorithm, determine several groups of faulty nodes and make corresponding marks. S3, according to the groups of faulty nodes obtained in step S2, detecting the operation data information of related resources and the disk status data information in the distributed operating system to construct a health impact set; According to Corosync, cluster information and heartbeat information are transmitted in real time to obtain relevant status data information of several groups of nodes in the cluster and build a node data set, where the node data set includes the number of nodes in the cluster Jdsz, the timestamp of each node sending the heartbeat signal, and the timestamp of each node receiving the heartbeat signal; S4, extracting features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz and number of I / O errors Cwp of the corresponding faulty node respectively, and using deep learning technology and combining it with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and by associating the resource usage coefficient Zsxs and the disk status coefficient Czxs, fitting and obtaining the health index Jkzs of the corresponding faulty node; S5. Preset a prediction threshold Q, and compare and analyze the prediction threshold Q with the health index Jkzs of the corresponding faulty node, comprehensively predict the difficulty report of the current faulty node recovery, and display it in a visual form on the computing platform; Set a fixed time interval TzTz. Each sending node in the cluster sends a heartbeat signal to the receiving node at a fixed time interval TzTz to indicate that it is active. After receiving the heartbeat signal from the sending node, the receiving node in the cluster records the timestamp of receiving the heartbeat. Based on the received heartbeat timestamp, the receiving node makes a preliminary judgment on whether the sending node has a failure risk. The specific preliminary judgment contents are as follows: If the nth sending timestamp - the n-1th sending timestamp > the fixed time interval TzTz, the receiving node will preliminarily determine that the sending node has a failure risk and mark the sending node as a judgment node; If the nth sending timestamp - the n-1th sending timestamp ≤ the fixed time interval TzTz, the receiving node will preliminarily determine that there is no risk of failure in the sending node.

2. The distributed system fault judgment and recovery method according to claim 1, characterized in that: When the receiving node initially determines that the sending node has a risk of failure, the receiving node will send a voting request to the cluster for a comprehensive judgment. The specific contents are as follows: The node that receives the voting request will analyze whether the current judgment node has a risk of failure based on the timestamp of the heartbeat signal it has recently received from the judgment node. When the node that receives the vote analyzes that the judgment node has a risk of failure, it returns the instruction and issues a positive vote. When the node that receives the vote analyzes that the judgment node does not have a risk of failure, it returns the instruction and issues a negative vote. According to the positive votes and negative votes made by the node that received the voting request, the number of positive votes Kts and the number of negative votes Fts are obtained; If the number of positive votes Kts> the number of negative votes Fts, the node is analyzed as a faulty node and marked accordingly for further analysis; If the number of positive votes Kts ≤ the number of negative votes Fts, the node is analyzed as a non-faulty node.

3. The distributed system fault judgment and recovery method according to claim 2, characterized in that: Obtain the number of faulty nodes Gj according to the marked faulty nodes, and calculate the fault ratio Gjs according to the number of nodes Jdsz in the cluster, and detect the relevant resource operation data information and disk status data information in the distributed operating system to construct a health impact set, which includes the relevant resource operation data information and disk status data information; The relevant resource operation data information includes CPU usage Csz, memory usage Nsi, disk usage Csyz and operating temperature; The disk status data information includes the number of bad blocks Hksz at each monitoring time point in the monitoring cycle, the number of I / O errors Cwp at each monitoring time point in the monitoring cycle, and the mean value Hksz of the number of bad blocks in the monitoring cycle is obtained by using a statistical mean algorithm. avg And the average number of I / O errors during the monitoring period Cwp avg ; At the same time, a convolutional neural network is used to build a primary model, and the primary model is trained and tested with relevant resource operation data information and disk status data information. The trained preliminary model is used as an information recognition model, and the feature information therein is obtained respectively. The information recognition model is trained and tested with the obtained feature information. Combined with the obtained fault proportion Gjs, the trained information recognition model is used as a health prediction model.

4. The distributed system fault judgment and recovery method according to claim 3, characterized in that: According to the health prediction model and combined with deep learning technology, the resource usage coefficient Zsxs and the disk status coefficient Czxs are calculated and obtained respectively. The resource usage coefficient Zsxs and the disk status coefficient Czxs are obtained respectively by the following formulas: In the formula, α and β are weight coefficients, Csz represents CPU usage, Csyz represents disk usage, Nsi represents memory usage, and V represents the first correction constant; Where n is the number of monitoring time points, i = 1, 2, 3, ..., n, Hksz i It is expressed as the number of bad blocks at the i-th monitoring time point, Hksz avg It is expressed as the mean number of bad blocks in the monitoring period, Cwp i It is expressed as the number of I / O errors at the i-th monitoring time point, Cwp avg It is expressed as the average number of I / O errors during the monitoring period.

5. The distributed system fault judgment and recovery method according to claim 4, characterized in that: After linear normalization of the resource usage coefficient Zsxs and the disk status coefficient Czxs, the corresponding data values ​​are mapped to the interval 0, 1, and the health index Jkzs of the corresponding fault node is obtained by fitting. The health index Jkzs of the corresponding fault node is obtained by the following formula: Where Ccn is the TCP retransmission rate, Gjs is the failure rate, and e is the Euler number, which is approximately 2.71828.

6. The distributed system fault diagnosis and recovery method according to claim 1, characterized in that: The prediction threshold Q is compared with the health index Jkzs of the corresponding faulty node to comprehensively predict the recovery difficulty report of the current faulty node. The specific contents are as follows: If the health index Jkzs of the corresponding faulty node is ≥ the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in an abnormal state. At this time, the corresponding faulty node is isolated from the cluster, and the task allocation and data communication of the faulty node are stopped, and an early warning instruction is sent to the system administrator. The backup node in the distributed storage system is then used to restore the data on the faulty node, and the tasks and data on the faulty node are reallocated to the backup node. At this time, the backup node will take over the responsibilities of the faulty node within 5 seconds and try to perform automated fault repair operations. If the automated repair is invalid, wait for the system administrator to intervene manually. If the health index Jkzs of the corresponding faulty node is less than the predicted threshold Q, it is comprehensively predicted that the recovery capability of the current faulty node is in a normal state. At this time, an attempt is made to automatically repair the faulty node. The automatic repair means include restarting the node, restoring the configuration, and reloading the service, and monitoring the repair process. After the faulty node is restored, a distributed consistency protocol is used for data synchronization and consistency verification. After the faulty node is restored, a health status verification is performed to confirm that the node has been restored to a normal state and can run stably. After the faulty node is restored to normal, the faulty node is rejoined to the cluster, and tasks and resources are reallocated.

7. A cloud operating system, applying the distributed system fault judgment and recovery method according to any one of claims 1 to 6, characterized in that: it includes a construction module, a first monitoring module, a fault locking module, a second monitoring module, a health assessment module and a prediction management module; The construction module uses Apache Mesos as a resource manager to build a virtual resource pool, and uses Mesos as the kernel of a distributed operating system to handle resource allocation and centrally manage clusters; The first monitoring module, in a distributed operating system, obtains relevant status data information of several groups of nodes in the cluster according to Corosync, and constructs a node data set; The fault locking module determines several groups of faulty nodes based on the node data set and combines the distributed consistency algorithm, and makes corresponding marks; The second monitoring module detects the operation data information of related resources and the disk status data information in the distributed operating system according to the groups of fault nodes obtained in step S2, so as to construct a health impact set; The health assessment module extracts features from the health impact set to obtain the disk usage Csyz, CPU usage Csz, number of bad blocks Hksz, and number of I / O errors Cwp of the corresponding faulty node, and uses deep learning technology in combination with the trained health prediction model to analyze and calculate the resource usage coefficient Zsxs and the disk status coefficient Czxs, and associates the resource usage coefficient Zsxs with the disk status coefficient Czxs to obtain the health index Jkzs of the corresponding faulty node. The prediction management module pre-sets a prediction threshold Q, and compares and analyzes the prediction threshold Q with the health index Jkzs of the corresponding fault node, comprehensively predicts the difficulty report of the current fault node recovery, and presents it in a visual form on the computing platform.

8. A computing platform, characterized in that: The computing platform comprises at least one processor, a memory and an input and output unit; The memory is used to store a computer program, and the processor is used to call the computer program stored in the memory to execute the distributed system fault judgment and recovery method according to any one of claims 1 to 6.