CN-116069542-B - Cloud platform cluster health state detection method and device, electronic equipment and medium
Abstract
The embodiment of the application provides a cloud platform cluster health state detection method, a cloud platform cluster health state detection device, electronic equipment and a cloud platform cluster health state detection medium, and belongs to the technical field of cloud platforms. The method comprises the steps of generating a configuration file according to detection items of a cloud platform cluster, issuing detection tasks to all nodes of the cloud platform cluster according to the configuration file, controlling all the nodes to execute corresponding detection tasks according to the detection tasks to obtain detection results of all the detection items, determining final detection scores of all the detection items according to the detection results of all the detection items, determining total scores of the cloud platform cluster according to the final detection scores of all the detection items, and determining the health state of the cloud platform cluster according to the total scores of the cloud platform cluster. Therefore, the detection efficiency of the cloud platform cluster is improved through the health detection of the key service and the hardware resource of the cloud platform cluster.
Inventors
- FU BINGGEN
- SUN LIJIE
- CHEN SONGZHENG
Assignees
- 湖南麒麟信安科技股份有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20230227
Claims (6)
- 1. The cloud platform cluster health state detection method is applied to a cloud platform cluster health state detection system and is characterized by comprising the following steps: Generating a configuration file according to the detection items of the cloud platform cluster, wherein the configuration file comprises a variable configuration file which comprises variable configuration required by executing a detection task; Issuing a detection task to each node of the cloud platform cluster according to the configuration file, wherein the detection task comprises a plurality of detection items, and controlling each node to execute the corresponding detection task to obtain a detection result of each detection item; Determining a final detection score of each detection item according to the detection result of each detection item; Determining the total score of the cloud platform cluster according to the final detection score of each detection item, and determining the health state of the cloud platform cluster according to the total score of the cloud platform cluster; each of the test items includes a plurality of test sub-items, and determining a final test score for each of the test items based on a test result of each of the test items includes: Determining the final detection result of the specific detection sub-item and the number of abnormal detection sub-items of each detection item according to the final detection result of each detection sub-item of each detection item; Determining a final detection score of each detection item according to the final detection result of the specific detection sub item of each detection item and the number of abnormal detection sub items; the number of abnormal detection sub-items includes the number of alarm sub-items and the number of fault sub-items, and the determining the final detection score of each detection item according to the number of abnormal detection sub-items of each detection item includes: Determining a final detection score of each detection item according to the number of alarm sub-items and the number of fault sub-items, the initial score value of each detection item, the number of detection sub-items of each detection item and the number of hosts; the obtaining of the initial score value of each detection item comprises the following steps: Determining an initial score value of each detection item according to a preset score threshold and the weight of each detection item, wherein the weight of each detection item is determined according to the importance degree of each detection item in the cloud platform cluster; The rule for the initial value of the score for each test item is as follows: Equation 1: ; Equation 2: ; Wherein the sum of the weights of all the detection items at present is obtained by the formula 1, wherein W represents the weight sum, Representing the weight of the ith test item, n representing the number of test items selected, calculating the initial score value of each test item by equation 2, An initial value representing a score of the i-th detection item; Each detection item comprises a plurality of detection sub-items, and the acquisition of the detection result of each detection item comprises the following steps: determining the final detection result of each detection item according to the final detection result of each detection sub-item of each detection item; If the specific detection sub-item is included, the specific detection sub-item is an alarm, the final score of the whole detection item is half of an initial value, and if the detection result of the specific detection sub-item is a fault, the score of the whole detection item is 0; if no specific detection sub-term is included, the score of the detection term is calculated using the following equation 3: equation 3: ; wherein S represents the final test score of the test item, Represents an initial score value assigned to the test item during initialization, Representing the product of the number of detection sub-items corresponding to the detection item and the number of hosts; Representing the number of alert sub-items in the detection results of all detection sub-items on all hosts, Representing the number of failed sub-items in the detection results of all detection sub-items on all hosts.
- 2. The method of claim 1, wherein the hardware resource status detection items comprise hardware configuration parameter detection sub-items of each node of the cloud platform cluster.
- 3. The method according to claim 1, wherein the method further comprises: determining the detection progress of each detection item according to the number of the detection items and the estimated detection time; And determining the detection progress of the detection task according to the detection progress of each detection item.
- 4. The utility model provides a cloud platform cluster health state detection device which characterized in that is applied to cloud platform cluster health state detecting system, the device includes: The system comprises a cloud platform cluster, a detection task management module and a control module, wherein the detection task management module is used for generating a configuration file according to detection items of the cloud platform cluster, the configuration file comprises a variable configuration file, the variable configuration file comprises variable configuration needed by executing a detection task, and initializing of a detection result file is completed; The detection result analysis module is used for determining the final detection score of each detection item according to the detection result of each detection item, determining the total score of the cloud platform cluster according to the final detection score of each detection item, and determining the health state of the cloud platform cluster according to the total score of the cloud platform cluster; each of the test items includes a plurality of test sub-items, and determining a final test score for each of the test items based on a test result of each of the test items includes: Determining the final detection result of the specific detection sub-item and the number of abnormal detection sub-items of each detection item according to the final detection result of each detection sub-item of each detection item; Determining a final detection score of each detection item according to the final detection result of the specific detection sub item of each detection item and the number of abnormal detection sub items; the number of abnormal detection sub-items includes the number of alarm sub-items and the number of fault sub-items, and the determining the final detection score of each detection item according to the number of abnormal detection sub-items of each detection item includes: Determining a final detection score of each detection item according to the number of alarm sub-items and the number of fault sub-items, the initial score value of each detection item, the number of detection sub-items of each detection item and the number of hosts; the obtaining of the initial score value of each detection item comprises the following steps: Determining an initial score value of each detection item according to a preset score threshold and the weight of each detection item, wherein the weight of each detection item is determined according to the importance degree of each detection item in the cloud platform cluster; The rule for the initial value of the score for each test item is as follows: Equation 1: ; Equation 2: ; Wherein the sum of the weights of all the detection items at present is obtained by the formula 1, wherein W represents the weight sum, Representing the weight of the ith test item, n representing the number of test items selected, calculating the initial score value of each test item by equation 2, An initial value representing a score of the i-th detection item; Each detection item comprises a plurality of detection sub-items, and the acquisition of the detection result of each detection item comprises the following steps: determining the final detection result of each detection item according to the final detection result of each detection sub-item of each detection item; If the specific detection sub-item is included, the specific detection sub-item is an alarm, the final score of the whole detection item is half of an initial value, and if the detection result of the specific detection sub-item is a fault, the score of the whole detection item is 0; if no specific detection sub-term is included, the score of the detection term is calculated using the following equation 3: equation 3: ; wherein S represents the final test score of the test item, Represents an initial score value assigned to the test item during initialization, Representing the product of the number of detection sub-items corresponding to the detection item and the number of hosts; Representing the number of alert sub-items in the detection results of all detection sub-items on all hosts, Representing the number of failed sub-items in the detection results of all detection sub-items on all hosts.
- 5. An electronic device comprising a memory and a processor, the memory storing a computer program that, when executed by the processor, performs the cloud platform cluster health status detection method of any of claims 1 to 3.
- 6. A computer readable storage medium, characterized in that it stores a computer program which, when run on a processor, performs the cloud platform cluster health status detection method of any of claims 1 to 3.
Description
Cloud platform cluster health state detection method and device, electronic equipment and medium Technical Field The present application relates to the field of cloud platform technologies, and in particular, to a cloud platform cluster health status detection method, device, electronic apparatus, and medium. Background In recent years, cloud computing technology is continuously developed, more and more companies discard traditional office modes, office computers are not distributed to staff, and the office computers of the staff and even key business machines are moved to the cloud. The cloud platform is an infrastructure platform for bearing the services, and the office computers and the service machines are moved on the cloud platform to be deployed, so that the office requirements are met, the operation and maintenance work is greatly reduced, and the cloud platform is safer. At the same time, however, a large number of virtual machines run on the cloud platform cluster, and the smooth running of the cloud platform cluster must be ensured. At this time, the health detection of the cloud platform cluster is particularly important, and the health detection must be regularly performed on the cloud platform cluster to discover the problem existing in the cluster in advance, so that the situation that the cloud desktop cannot be used in a large area is avoided. At present, the health detection of the cloud platform cluster does not have a relatively universal scheme, each cloud platform solution provider has a scheme for detecting the health condition of the cloud platform cluster, and the problem of low detection efficiency is generally existed. Disclosure of Invention In order to solve the technical problems, the embodiment of the application provides a cloud platform cluster health state detection method, a cloud platform cluster health state detection device, electronic equipment and a cloud platform cluster health state detection medium. In a first aspect, an embodiment of the present application provides a cloud platform cluster health status detection method, which is applied to a cloud platform cluster health status detection system, where the method includes: Generating a configuration file according to the detection items of the cloud platform cluster; Issuing a detection task to each node of the cloud platform cluster according to the configuration file, wherein the detection task comprises a plurality of detection items, and controlling each node to execute the corresponding detection task to obtain a detection result of each detection item; Determining a final detection score of each detection item according to the detection result of each detection item; And determining the total score of the cloud platform cluster according to the final detection score of each detection item, and determining the health state of the cloud platform cluster according to the total score of the cloud platform cluster. In a second aspect, an embodiment of the present application provides a cloud platform cluster health status detection device, where the device includes: the detection task management module is used for generating a configuration file according to detection items of the cloud platform cluster, issuing detection tasks to all nodes of the cloud platform cluster according to the configuration file, wherein the detection tasks comprise a plurality of detection items, and controlling all the nodes to execute corresponding detection tasks to obtain detection results of all the detection items; The detection result analysis module is used for determining the final detection score of each detection item according to the detection result of each detection item, determining the total score of the cloud platform cluster according to the final detection score of each detection item, and determining the health state of the cloud platform cluster according to the total score of the cloud platform cluster. In a third aspect, an embodiment of the present application provides an electronic device, including a memory and a processor, where the memory is configured to store a computer program, and the computer program executes, when the processor runs, the cloud platform cluster health status detection method provided in the first aspect. In a fourth aspect, an embodiment of the present application provides a computer readable storage medium storing a computer program, where the computer program when run on a processor performs the cloud platform cluster health status detection method provided in the first aspect. The cloud platform cluster health state detection method, device, electronic equipment and medium provided by the application generate a configuration file according to detection items of a cloud platform cluster, send detection tasks to each node of the cloud platform cluster according to the configuration file, control each node to execute a corresponding detection task to obtain a detection result of each d