Method, device and equipment for detecting power consumption of column head tank and storage medium
By acquiring the key performance indicators of the server controlled by the column head cabinet, and using a weighted sum probability density algorithm to construct an indicator feature set, the problem of inaccurate judgment of power consumption anomalies in the column head cabinet is solved, and accurate power consumption anomaly detection and prompting are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- CHINA MOBILE INFORMATION TECHNOLOGY CO LTD
- Filing Date
- 2023-02-20
- Publication Date
- 2026-06-19
AI Technical Summary
In existing technologies, the judgment of abnormal power consumption of the cabinet is inaccurate, and it is impossible to accurately understand the internal factors affecting the abnormal power consumption of the cabinet, resulting in difficulties in operation and maintenance.
By acquiring data on the CPU utilization, disk I/O read/write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data of the server controlled by the cabinet, a set of indicator features is constructed using weighted rules and probability density algorithms to detect abnormal power consumption of the cabinet.
It improves the accuracy of detecting abnormal power consumption of the cabinet head unit, and can generate abnormal prompts in a timely manner, reducing the difficulty of operation and maintenance.
Smart Images

Figure CN116107842B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of communication technology, and in particular relates to a method, apparatus, device and storage medium for detecting the power consumption of a power supply cabinet. Background Technology
[0002] With the popularization of big data and cloud computing technologies, and the increase in business volume and data volume, the scale of server clusters is growing rapidly. As the basic unit for power consumption control in a server cluster, the accurate determination of whether the power consumption of the server head unit is abnormal is a fundamental aspect of improving cloud computing capabilities. Currently, existing methods for determining whether the power consumption of the server head unit is abnormal rely solely on directly measuring the actual power consumption of the server head unit with instruments, leading to inaccurate judgments. Summary of the Invention
[0003] This application provides a method, apparatus, device, and storage medium for detecting the power consumption of a power supply cabinet. It can determine whether the power consumption of the power supply cabinet is abnormal by combining the CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data of the server controlled by the power supply cabinet.
[0004] In a first aspect, embodiments of this application provide a method for detecting the power consumption of a column head cabinet, comprising:
[0005] Acquire first collection data from at least one server controlled by the column head cabinet within a first preset time period. The first collection data of each server includes multiple first sub-collection data. Each first sub-collection data includes at least three types of collection data from CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0006] According to the preset weighting rules, the maximum value of each type of data in the multiple first sub-collected data of each server is weighted to obtain the weighted value corresponding to each type of data.
[0007] Calculate the weighted value for each type of collected data from at least one server and then average it to obtain the weighted average value for each type of collected data.
[0008] The power consumption detection value of the cabinet is determined based on the weighted average value corresponding to each type of collected data.
[0009] If the power consumption detection value exceeds the preset power consumption threshold, a prompt message indicating abnormal power consumption of the column head cabinet will be generated.
[0010] Optionally, the maximum value of each type of data in the multiple first sub-collected data of each server is weighted according to a preset weighting rule to obtain a weighted value corresponding to each type of data, including:
[0011] Obtain the rated power of each of at least one of the servers;
[0012] Calculate the average rated power of at least one server;
[0013] The ratio of the rated power of each server to the average rated power is determined as the weighting coefficient for the corresponding server;
[0014] The maximum value of each type of data in the multiple first sub-collected data of each server is weighted according to the weighting coefficient.
[0015] Optionally, the power consumption detection value of the cabinet is determined based on the weighted average value corresponding to each type of collected data, satisfying the following conditions:
[0016]
[0017] Where y is the power consumption detection value, a, b, c , d as well as n It is a constant. These are the weighted average values for each type of collected data.
[0018] Optionally, the method further includes:
[0019] Acquire second collection data from at least one server controlled by the column head cabinet within a second preset time period. The second collection data of each server includes multiple second sub-collection data. Each second sub-collection data includes at least three types of collection data from the following: CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0020] Based on the preset probability density algorithm, the probability density corresponding to each type of data in each first sub-collection data of each server is calculated, and the probability density corresponding to each type of data in each second sub-collection data of each server is calculated.
[0021] Based on a preset detection scoring algorithm, the first detection score for each first sub-collected data point of each server is determined using the probability density corresponding to each type of collected data in each first sub-collected data point of each server.
[0022] Based on the preset detection score algorithm, the second detection score corresponding to each second sub-collection data of each server is determined by the probability density corresponding to each type of collection data in each second sub-collection data of each server.
[0023] Sort the first and second detection scores;
[0024] If, among a large number of preset detection scores, there is a detection score type greater than the threshold that is the first detection score, a prompt message is generated indicating that the power consumption of the column head cabinet is abnormal due to abnormal server power consumption.
[0025] Optionally, according to a preset probability density algorithm, the probability density corresponding to each type of data in each first sub-collection data of each server is calculated, and the probability density corresponding to each type of data in each second sub-collection data of each server is calculated, including:
[0026] Normalize each type of data in each first sub-collection data of each server to obtain the normalized value corresponding to each type of data in each first sub-collection data of each server, and
[0027] Normalize each type of data in each second sub-collection data of each server to obtain the normalized value corresponding to each type of data in each second sub-collection data of each server.
[0028] Calculate the probability that the normalized value of each type of data in each first sub-collection data of each server falls within a preset interval, thus obtaining the probability density of each type of data in each first sub-collection data of each server.
[0029] Calculate the probability that the normalized value of each type of data in each second sub-collection data of each server falls within a preset interval, and the probability density of each type of data in each second sub-collection data of each server.
[0030] Optionally, each type of data in each first sub-collection data of each server is normalized to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and each type of data in each second sub-collection data of each server is normalized to obtain a normalized value corresponding to each type of data in each second sub-collection data of each server, satisfying the following conditions:
[0031]
[0032] in, The first sub-collection data in each i The first type of collected data corresponds to thei Normalized value, For the first i The normalized value corresponds to the first sub-collection data in the first data segment. i This type of data collection For multiple first sub-collected data, the first i The minimum value of the collected data, For multiple first sub-collected data, the first i The maximum value of the collected data, among which i It is an integer; or
[0033] The first in each second sub-collected data j The first type of collected data corresponds to the j Normalized value, The first in each second sub-collected data j This type of data collection For multiple second sub-collected data, the first j The minimum value of the collected data, For multiple second sub-collected data, the first j The maximum value of the collected data, among which j It is an integer.
[0034] Optionally, based on a preset detection scoring algorithm, the first detection score corresponding to each first sub-collected data of each server is determined by the probability density corresponding to each type of collected data in each first sub-collected data.
[0035] Based on the preset detection score algorithm, the second detection score for each second sub-collection data of each server is determined by the probability density corresponding to each type of data in each second sub-collection data, satisfying the following conditions:
[0036]
[0037] in, HBOS ( P The first detection score is ) These are the probability densities corresponding to each type of data in each of the first sub-collections, or HBOS ( P The second detection score is ) These represent the probability densities for each type of data collected in each second sub-collection.
[0038] Optionally, the first sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization.
[0039] The second sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization. Secondly, embodiments of this application provide a device for detecting the power consumption of a column-head cabinet, comprising:
[0040] The acquisition module is used to acquire first collection data of at least one server controlled by the column head cabinet within a first preset time period. The first collection data of each server includes multiple first sub-collection data. Each first sub-collection data includes at least three types of collection data among CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0041] The weighting module is used to weight the maximum value of each type of data in the multiple first sub-collected data of each server according to the preset weighting rules, so as to obtain the weighted value corresponding to each type of data.
[0042] The calculation module is used to calculate the average value of each type of collected data from at least one server, and obtain the weighted average value for each type of collected data.
[0043] The determination module is used to determine the power consumption detection value of the column head cabinet based on the weighted average value corresponding to each type of collected data;
[0044] The prompt module is used to generate a prompt message indicating abnormal power consumption of the column head cabinet when the power consumption detection value is greater than the preset power consumption threshold.
[0045] Optionally, the weighting module weights the maximum value of each type of data in the multiple first sub-collected data of each server according to a preset weighting rule, to obtain a weighted value corresponding to each type of data, including:
[0046] The acquisition module is also used to acquire the rated power of each of at least one of the servers;
[0047] The calculation module is also used to calculate the average rated power of at least one server;
[0048] The determination module is also used to determine the weighting coefficient of the corresponding server as the ratio of the rated power of each server to the average rated power.
[0049] The weighting module is also used to weight the maximum value of each type of data in multiple first sub-collected data of each server according to the weighting coefficient.
[0050] Optionally, the determining module determines the power consumption detection value of the column head cabinet based on the weighted average value corresponding to each type of collected data, satisfying the following conditions:
[0051]
[0052] Where y is the power consumption detection value, a, b, c , d as well as n It is a constant. These are the weighted average values for each type of collected data.
[0053] Optionally, the device further includes:
[0054] The acquisition module is also used to acquire second collection data of at least one server controlled by the column head cabinet within a second preset time period. The second collection data of each server includes multiple second sub-collection data. Each second sub-collection data includes at least three types of collection data among CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0055] The calculation module is also used to calculate the probability density of each type of data in each first sub-collection data of each server according to the preset probability density algorithm, and to calculate the probability density of each type of data in each second sub-collection data of each server.
[0056] The determination module is also used to determine the first detection score corresponding to each first sub-collected data of each server based on a preset detection score algorithm and the probability density corresponding to each type of collected data in each first sub-collected data of each server.
[0057] Based on the preset detection score algorithm, the second detection score corresponding to each second sub-collection data of each server is determined by the probability density corresponding to each type of collection data in each second sub-collection data of each server.
[0058] The sorting module is used to sort the first detection score and the second detection score;
[0059] The prompt module is also used to generate a prompt message indicating abnormal power consumption of the column head cabinet due to abnormal server power consumption when there is a detection score type greater than a threshold among a large number of preset detection scores.
[0060] Optionally, the calculation module calculates the probability density of each type of data in each first sub-collection data of each server, and the probability density of each type of data in each second sub-collection data of each server, according to a preset probability density algorithm, including:
[0061] The calculation module is also used to normalize each type of data in each first sub-collection data of each server, to obtain the normalized value corresponding to each type of data in each first sub-collection data of each server, and
[0062] Normalize each type of data in each second sub-collection data of each server to obtain the normalized value corresponding to each type of data in each second sub-collection data of each server.
[0063] The calculation module is also used to calculate the probability that the normalized value corresponding to each type of data in each first sub-collection data of each server falls within a preset interval, thereby obtaining the probability density corresponding to each type of data in each first sub-collection data of each server, and
[0064] The calculation module is also used to calculate the probability that the normalized value corresponding to each type of data in each second sub-collection data of each server falls into a preset interval, and the probability density corresponding to each type of data in each second sub-collection data of each server.
[0065] Optionally, the calculation module normalizes each type of data in each first sub-collection data of each server to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and normalizes each type of data in each second sub-collection data of each server to obtain a normalized value corresponding to each type of data in each second sub-collection data of each server, satisfying the following conditions:
[0066]
[0067] in, The first sub-collection data in each i The first type of collected data corresponds to the i Normalized value, For the first i The normalized value corresponds to the first sub-collection data in the first data segment. i This type of data collection For multiple first sub-collected data, the first i The minimum value of the collected data, For multiple first sub-collected data, the first i The maximum value of the collected data, among which i It is an integer; or
[0068] The first in each second sub-collected data j The first type of collected data corresponds to the j Normalized value, The first in each second sub-collected dataj This type of data collection For multiple second sub-collected data, the first j The minimum value of the collected data, For multiple second sub-collected data, the first j The maximum value of the collected data, among which j It is an integer.
[0069] Optionally, the determining module determines the first detection score for each first sub-collected data point of each server based on a preset detection score algorithm and the probability density corresponding to each type of collected data in each first sub-collected data point.
[0070] Based on the preset detection score algorithm, the second detection score for each second sub-collection data of each server is determined by the probability density corresponding to each type of data in each second sub-collection data, satisfying the following conditions:
[0071]
[0072] in, HBOS ( P The first detection score is ) Let be the probability density corresponding to each type of data in each first sub-data set, , or . HBOS ( P The second detection score is ) These represent the probability densities for each type of data collected in each second sub-collection.
[0073] Optionally, the first sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization.
[0074] The second sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization.
[0075] Thirdly, embodiments of this application provide an electronic device, the device comprising:
[0076] Processor and memory storing computer program instructions;
[0077] The method for detecting the power consumption of the column head cabinet used by the processor to execute the computer program instructions described in the first aspect above.
[0078] Fourthly, embodiments of this application provide a computer storage medium storing computer program instructions, which, when executed by a processor, implement the method for detecting the power consumption of the column head cabinet described in the first aspect.
[0079] This application embodiment detects abnormal power consumption of the power supply cabinet by acquiring first collection data from at least one server. This first collection data includes multiple first sub-collection data consisting of at least three types of data: CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. This links the abnormal power consumption information of the power supply cabinet to the aforementioned performance indicators of the server controlled by the power supply cabinet, avoiding the inaccuracy of directly measuring the power consumption of the power supply cabinet with instruments, and improving the accuracy of detecting abnormal power consumption. Subsequently, calculating the weighted average of the maximum values of each type of collection data from multiple servers reduces calculation errors and further improves the accuracy of detecting the power consumption value of the power supply cabinet. Finally, the power consumption detection value of the power supply cabinet is determined based on the weighted average of the multiple collection data. This method of comparing the detection value with a threshold is simple to implement and does not excessively increase the system's computational load.
[0080] Therefore, the above method not only improves the accuracy of detecting whether the power consumption of the cabinet head is abnormal, but also has universality. Attached Figure Description
[0081] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments of this application will be briefly introduced below. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0082] Figure 1 This is a flowchart illustrating a method for detecting the power consumption of a column cabinet, provided as an embodiment of this application.
[0083] Figure 2 This is a flowchart illustrating a preset weighting rule method provided in one embodiment of this application.
[0084] Figure 3 This is a flowchart illustrating another method for detecting the power consumption of a cabinet head unit, provided as an embodiment of this application.
[0085] Figure 4 This application provides an exemplary probability density distribution histogram of server CPU utilization as an embodiment of the present application.
[0086] Figure 5 This is a schematic diagram of a power consumption detection device for a cabinet head unit, provided as an embodiment of this application.
[0087] Figure 6 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0088] The features and exemplary embodiments of various aspects of this application will be described in detail below. To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only intended to explain this application and not to limit it. For those skilled in the art, this application can be implemented without some of these specific details. The following description of the embodiments is merely to provide a better understanding of this application by illustrating examples.
[0089] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus that includes the element.
[0090] To address the problems of the prior art, embodiments of this application provide a method, apparatus, device, and computer storage medium for detecting the power consumption of a power-saving cabinet. The method for detecting the power consumption of a power-saving cabinet provided in this application embodiment will be described first below.
[0091] Current methods for determining whether the power consumption of data center cabinets is abnormal rely solely on directly measuring the actual power consumption of the cabinets, leading to inaccurate assessments. Furthermore, existing technologies can only detect whether the power consumption is abnormal, failing to identify the internal factors influencing this abnormality. Therefore, detecting abnormal power consumption without further investigation into its cause poses a significant challenge for data center maintenance personnel. This application provides a method, apparatus, device, and computer storage medium for detecting the power consumption of data center cabinets, thereby solving or partially solving the aforementioned problems.
[0092] First, this application requires identifying a set of server resource utilization metrics that have the greatest impact on the power consumption of the power supply cabinet. The power consumption of the power supply cabinet is determined by the combined power consumption of all the servers it controls. Obviously, changes in server resource utilization will lead to changes in server power consumption, and will also affect the total power consumption of the power supply cabinet. There are various server resource utilization metrics, such as: Central Processing Unit (CPU) utilization, memory utilization, disk input / output (IO) read / write utilization, network card bandwidth utilization, CPU fan temperature, and graphics card data. However, not all of these parameters can cause changes in server power consumption. Current research results only indicate that these parameters are correlated with the actual power consumption of the server. Therefore, it is necessary to identify the parameters with the highest correlation to server power consumption to construct a set of metric features.
[0093] Step 1: This application obtained detection data of various server utilization indicators, including: CPU utilization, memory utilization, disk I / O read / write utilization, network card bandwidth utilization, CPU fan temperature, and graphics card data.
[0094] Step 2: Construct a feature matrix based on the power consumption of the cabinet and the detection data, and then calculate the covariance of each pair to obtain the covariance matrix.
[0095] Step 3: Based on the magnitude of the covariance coefficient between each type of detection data and the power consumption of the cabinet in the covariance matrix, the indicator features that have the greatest impact on the power consumption of the cabinet are finally selected, thereby constructing an indicator feature set.
[0096] As an example, this application uses the total power consumption of the cabinet as X, and the server resource utilization rate as Y, Z, and W, with 6 sample data points for illustration. Specific data is shown in the table below:
[0097]
[0098] Based on the above sample data, a 5*4 feature matrix was constructed as follows:
[0099]
[0100]
[0101] The covariance matrix is obtained by taking the pairwise covariance of the data in the feature matrix as follows:
[0102]
[0103] Due to the properties of the covariance matrix, we obtain , Furthermore, the covariance matrix shows that the covariance coefficients of the server CPU utilization and server disk I / O read / write rate are relatively large, thus concluding that the server CPU utilization and server disk I / O read / write rate have a significant impact on the power consumption of the rack cabinet.
[0104] Ultimately, this application embodiment identifies three key metrics that have the greatest impact on the power consumption of the rack-mount cabinet: server CPU utilization, disk I / O read / write rate, and network interface card bandwidth utilization. The rack-mount cabinet is then used to detect abnormal power consumption based on these three metrics, as follows:
[0105] like Figure 1 As shown, a method for detecting the power consumption of a cabinet head unit includes:
[0106] S110: Acquire first collected data from at least one server controlled by the rack-mount cabinet within a first preset time period. The first collected data for each server includes multiple first sub-collected data, each of which includes at least three of the following: CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. As the basic unit for power consumption control in a server cluster, the rack-mount cabinet may control multiple servers. Therefore, this embodiment acquires first collected data from at least one server controlled by the rack-mount cabinet. Furthermore, since the purpose is to detect whether the power consumption of the rack-mount cabinet is abnormal, to improve the accuracy of the detection, data collected within the first preset time period closest to the current time is often selected. For example, if the current time is 12:00 AM, data collected within one hour before 12:00 AM can be selected, that is, data collected within the first preset time period from 11:00 AM to 12:00 PM.
[0107] Meanwhile, under normal circumstances, there may be multiple sets of data collected from each server within the first preset time period. Therefore, the first set of collected data may include multiple first sub-collected data sets. Each first sub-collected data set includes at least three of the following: CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. It is conceivable that the data collection frequency of the server can be manually set, for example, data can be collected every 5 minutes. Within the first preset time period of 11:00 AM to 12:00 PM, each server may include 12 different sets of first sub-collected data sets, including CPU utilization, disk I / O read / write rate, and network card bandwidth utilization.
[0108] S120: According to the preset weighting rules, the maximum value of each type of data in the multiple first sub-collected data of each server is weighted to obtain the weighted value corresponding to each type of data.
[0109] After acquiring multiple first sub-collected data from at least one server, the maximum value of each type of collected data from the multiple first sub-collected data of each server can be weighted according to a preset weighting rule to obtain the corresponding weighted value.
[0110] In some examples, taking the first sub-collected data as including CPU utilization, disk I / O read / write rate, and network card bandwidth utilization, the maximum values of multiple CPU utilization, disk I / O read / write rates, and network card bandwidth utilization can be selected from the first collected data, and then weighted to obtain the first weighted value, the second weighted value, and the third weighted value.
[0111] In some embodiments, several of the largest values among the CPU utilization, disk I / O read / write rate, and network card bandwidth utilization of each server can be selected respectively. Then, the average of the several largest values among the CPU utilization, disk I / O read / write rate, and network card bandwidth utilization of each server can be calculated. Then, the average of the several largest values among the largest values of each server can be weighted according to a preset weighting rule to obtain the corresponding first weighted value, second weighted value, and third weighted value.
[0112] S130: Calculate the weighted average value corresponding to each type of collected data from at least one server, and obtain the weighted average value corresponding to each type of collected data.
[0113] To improve the detection rate of abnormal power consumption of the cabinet, after obtaining the weighted value corresponding to each type of data collected by each server, the average value of the weighted value corresponding to each type of data collected by each server can be calculated to obtain the weighted average value corresponding to each type of data collected.
[0114] S140: Determine the power consumption detection value of the cabinet head based on the weighted average value corresponding to each type of collected data.
[0115] The power consumption detection value of the rack-mounted array can be determined based on the weighted average of each type of data collected from at least one server controlled by the rack-mounted array. Continuing with the example of the first sub-collected data including CPU utilization, disk I / O read / write rate, and network card bandwidth utilization, the first weighted average, second weighted average, and third weighted average are obtained by averaging the weighted averages of the maximum values of the three data points. These three weighted averages are then substituted into a preset detection function to obtain the power consumption detection value of the rack-mounted array.
[0116] S150: If the power consumption detection value is greater than the preset power consumption threshold, generate a prompt message indicating abnormal power consumption of the column head cabinet.
[0117] After obtaining the power consumption detection value of the power supply cabinet, it can be compared with a preset power consumption threshold. If the detected power consumption value exceeds the preset threshold, an abnormal power consumption warning message is generated. For example, the warning message could indicate that an indicator light has been installed on the power supply cabinet to remind maintenance personnel to perform maintenance or other operations.
[0118] In this embodiment, the information on whether the power consumption of the cabinet is abnormal is linked to at least three types of collected data from at least one server controlled by the cabinet, including CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. Then, based on a preset weighting rule, the maximum value of each type of collected data for each server is weighted to obtain the corresponding weighted value for each type of collected data. Selecting the maximum value for weighting can improve the detection accuracy of whether the power consumption of the cabinet is abnormal. Then, the average value of the weighted values corresponding to each type of collected data from at least one server is calculated. The average value of the weighted values is used to determine the power consumption detection value of the power supply cabinet. The power consumption detection value is then judged to be within the preset power consumption threshold to determine whether the power supply cabinet is abnormal. This method uses the weighted average value of at least three types of collected data from at least one server controlled by the power supply cabinet, namely, CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data, to determine whether the power consumption of the power supply cabinet is abnormal. This improves the accuracy of detecting abnormal power consumption of the power supply cabinet and also provides a new approach to detecting abnormal power consumption of the power supply cabinet.
[0119] like Figure 2 As shown, in some embodiments, S120, the maximum values of CPU utilization, disk I / O read / write rate, and network card bandwidth utilization in multiple first sub-collected data of each server are weighted according to preset weighting rules to obtain corresponding first weighted values, second weighted values, and third weighted values, including:
[0120] S1201: Obtain the rated power of each of at least one of the servers.
[0121] To obtain the rated power of each server in at least one server, it is conceivable that each server will have its own rated power, for example, the rated power of each server will be described in the instruction manual of each server. Therefore, the rated power of the server controlled by the rack can be obtained directly through the instruction manual of each server.
[0122] S1202: Calculate the average rated power of at least one server.
[0123] After obtaining the rated power of each server, the average rated power of at least one server can be calculated. By calculating the average rated power, a "baseline power" of at least one server controlled by the array head unit can be determined.
[0124] S1203: The ratio of each server's rated power to its average rated power is determined as the weighting coefficient for that server. Using the ratio of each server's rated power to its average rated power as the weighting coefficient is equivalent to using the ratio of each server's rated power to the baseline power as the weighting coefficient. By taking the rated power of each server into account, the accuracy of the final detection of whether the power consumption of the rack head unit is abnormal can be improved.
[0125] S1204: Weight the maximum value of each type of data in the multiple first sub-collected data of each server according to the weighting coefficient. The maximum value of each type of data in the multiple first sub-collected data of each server is weighted according to the weighting coefficient corresponding to each server. The weighting coefficient can be directly multiplied by the maximum value of each type of data to obtain the corresponding weighted value for each type of data.
[0126] After acquiring multiple first sub-collected data from at least one server controlled by the column head cabinet, this application embodiment proposes a weighting method to address the issue of the impact of hardware differences on server power consumption in different server manufacturers and models. This method calculates the average rated power of all servers as the baseline power based on the rated power of each server controlled by the column head cabinet, thereby calculating the weighting coefficient of the servers.
[0127] Optionally, S140 determines the power consumption detection value of the column head cabinet based on the weighted average value corresponding to each type of collected data, satisfying the following conditions:
[0128] (1)
[0129] Where y is the power consumption detection value, a, b, c , d as well as n It is a constant. These are the weighted average values for each type of collected data.
[0130] When determining the power consumption detection value of the cabinet based on the weighted average value corresponding to each type of collected data, the weighted average value corresponding to each type of collected data can be substituted into the above formula (1) to obtain the power consumption detection value. a, b, c , d as well as n It is a constant. Continuing with the example of the first sub-collected data including CPU utilization, disk I / O read / write rate, and network card bandwidth utilization, after obtaining the first weighted average, second weighted average, and third weighted average, we substitute them into formula (1) to calculate the power consumption detection value. The formula contains... a, b, c as well as d It is a constant. The first weighted average, Second weighted average, This is the third weighted average. It's conceivable that the constants in the above formula can be determined through training.
[0131] For example, taking the first sub-collection data, which includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization, as an example, the specific training process is as follows:
[0132] Step 1: Randomly set four constants as... a, b, c as well as d The initial value, for example in this embodiment, is selected to be set. a =2.6, b =1.3, c =2.2, d Using 1.5 as the initial value, the initial detection function is obtained as follows: .
[0133] Step 2: Select different first-weighted averages, second-weighted averages, and third-weighted averages within different preset time periods as training samples. For example, the training samples selected in this embodiment for training the first-weighted averages, second-weighted averages, and third-weighted averages within different time periods are shown in the table below:
[0134]
[0135] Step 3: Substitute the weighted average value for different time periods into the initial detection function to calculate the power consumption detection value for each time period, and calculate the difference between the power consumption monitoring value and the power consumption of the column head cabinet in that time period. In this embodiment, the first sub-collection data of at least one server is collected every 5 minutes. Therefore, the specific data of the weighted average value are shown in the table below:
[0136]
[0137] Step 4: Set the loss function and loss threshold, determine the magnitude of the loss value and the loss threshold, and decide whether to adjust the parameters in the detection function. a, b, c as well as d The iteration process is as follows:
[0138] Set the loss function: Calculate the loss value L(w), with a loss threshold of L=0.01.
[0139] In this embodiment, the calculated loss value is
[0140] ,
[0141] Therefore, the calculated loss value is greater than the preset loss threshold, so it is necessary to iterate the parameters in the detection function.
[0142] Step 4: Set the iterative formulas for the parameters as follows:
[0143]
[0144] in, The learning rate is a constant and can be set manually; in this embodiment, it is set as follows: ,
[0145] These are the sample values of the first weighted average, second weighted average, and third weighted average measured each time. Therefore, after the first iteration, the four parameters of the detection function are as follows:
[0146]
[0147] Therefore, the detection function obtained after iteration is:
[0148] Step 5: Repeat steps 3 and 4 above to continue training the four parameters of the detection function until the final loss value is less than the loss threshold.
[0149] In this embodiment, the optimal detection function is finally obtained as follows: .
[0150] The iterative process described above for the detection function parameters allows for the selection of optimal parameters, improving the accuracy of using the calculated detection values to determine whether the power consumption of the cabinet is abnormal. Furthermore, it's conceivable that in practical applications, the detection function can be trained and then directly used in the application.
[0151] like Figure 3 As shown, in some embodiments, the method further includes:
[0152] S160: Acquire second collection data from at least one server controlled by the column head cabinet within a second preset time period. The second collection data of each server includes multiple second sub-collection data. Each second sub-collection data includes at least three types of collection data from the following: CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0153] After determining that the power consumption of the cabinet is abnormal, in order to determine whether the abnormal power consumption of the cabinet is caused by the abnormal power consumption of the server, this embodiment of the application continues to acquire second collection data of at least one server controlled by the cabinet within a second preset time period. The second collection data of each server includes multiple second sub-collection data, and each second sub-collection data includes at least three types of collection data among CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0154] It's conceivable that the second preset time period is completely different from the first preset time period. In practice, the second preset time period can be a period preceding the first preset time period. For example, if the current time is 12:00 PM, after detecting abnormal power consumption of the power supply cabinet by acquiring the first collection data within the first preset time period of 11:00 AM to 12:00 PM, you can choose to acquire the second collection data within the 5 hours of 6:00 AM to 11:00 AM. Taking data acquisition every 5 minutes as an example, each server will have 60 second sub-collection data points within 5 hours.
[0155] S170: Based on the preset probability density algorithm, calculate the probability density corresponding to each type of data in each first sub-collection data of each server, and calculate the probability density corresponding to each type of data in each second sub-collection data of each server.
[0156] The algorithm calculates the probability density for each type of data in each first sub-collection data set of each server using a preset probability density algorithm. For example, when each first sub-collection data set includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization, the algorithm can be used to obtain the first, second, and third probability densities corresponding to these parameters. Similarly, when each second sub-collection data set includes the same parameters, the algorithm can be used to calculate the fourth, fifth, and sixth probability densities corresponding to these parameters in each second sub-collection data set of each server. Using a preset time period of 1 hour and a preset time period of 5 hours, with data collected every 5 minutes, this results in 12 sets of first, second, and third probability densities, and 60 sets of fourth, fifth, and sixth probability densities.
[0157] In some embodiments, the preset probability density algorithm may involve separately calculating different probability density intervals, counting the number of each type of collected data within each interval, and obtaining the corresponding probability by calculating the ratio of the number of each type of collected data falling within each interval to the total number. It is conceivable that the aforementioned intervals can be manually set, and each type of collected data obtained through the above method will have the same probability density.
[0158] In some embodiments, based on the probability density algorithm described above, after calculating the probability density of each type of collected data falling into different intervals, a probability density curve can be obtained by fitting. Therefore, the corresponding probability density can be obtained on the corresponding probability density curve based on each type of collected data.
[0159] By using a preset probability density algorithm, multiple probability densities for each server are calculated simultaneously, avoiding the situation where incorrect judgments are made when determining the impact of server power consumption on the power consumption of the rack head unit due to calculating only the collected data within one time period.
[0160] S180: Based on the preset detection score algorithm, the first detection score corresponding to each first sub-collected data of each server is determined by the probability density corresponding to each type of collected data in each first sub-collected data of each server.
[0161] Based on the preset detection score algorithm, the second detection score corresponding to each second sub-collected data of each server is determined by the probability density corresponding to each type of collected data in each second sub-collected data of each server.
[0162] After obtaining the probability density corresponding to each type of data in each first sub-collection data of each server, the first detection score corresponding to each first sub-collection data of each server can be determined according to the preset detection score algorithm. At the same time, according to the preset detection score algorithm, the second detection score corresponding to each second sub-collection data of each server can also be determined by the probability density corresponding to each type of data in each second sub-collection data of each server. The preset detection score algorithm can be a pre-set detection function. By substituting multiple different probability densities into the detection function, the corresponding detection score is obtained. Therefore, each server will have two different preset time periods corresponding to the first detection score and the second detection score respectively.
[0163] S190: Sort the first detection score and the second detection score.
[0164] After obtaining multiple first detection scores and second detection scores for each server, the multiple first detection scores and second detection scores can be sorted to obtain the sorting results.
[0165] S200: If, among a large number of preset detection scores, there is a detection score type greater than the threshold that is the first detection score, a prompt message is generated indicating that the power consumption of the column head cabinet is abnormal due to abnormal server power consumption.
[0166] Based on the sorting results, a preset number of detection scores with relatively large values can be selected. Continuing with the example of obtaining 12 first sub-collected data points and 60 second sub-collected data points, the above method yields 12 first detection scores and 60 second detection scores. These 72 detection scores are then sorted. The detection scores with larger values are selected; for example, the top 10 highest-scoring detection values can be chosen.
[0167] After selecting a preset number of detection scores representing a significant portion of the total detection scores, the type of these scores can be determined, classifying each score within this subset as either a first or second detection score. Each detection score is obtained from either the original first or second sub-collected data, thus providing access to the original collected data corresponding to each score. Since the first and second sub-collected data have different preset time periods, the type of detection score can be determined by analyzing the collection time of the original collected data for each score. After identifying the type of each detection score within this subset, if a number of detection scores exceeding a threshold are classified as first detection scores, it indicates a potential anomaly in the server's power consumption. Because the server's power consumption is closely related to the power consumption of the display cabinet, a notification message indicating an anomaly in the display cabinet's power consumption due to abnormal server power consumption can be generated.
[0168] For example, after the top 10 with the largest detection scores, the type of each detection score can be determined by the acquisition time of the original data corresponding to each detection score. A threshold of 8 can be set. When it is determined that more than 8 out of 10 detection scores are the first detection scores, a prompt message can be generated indicating that the power consumption of the column head cabinet is abnormal due to abnormal power consumption of the server.
[0169] The above method can be used to determine whether the abnormal power consumption of the server is caused by abnormal power consumption of the server. The above method links the cause of the abnormal power consumption of the server to the power consumption of the server controlled by the server, thus providing convenience for maintenance personnel when troubleshooting the cause of abnormal power consumption of the server.
[0170] In some embodiments, according to a preset probability density algorithm, the probability density corresponding to each type of data in each first sub-collection data of each server is calculated, and the probability density corresponding to each type of data in each second sub-collection data of each server is calculated, including: S1701: Normalizing each type of data in each first sub-collection data of each server to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and
[0171] Normalize each type of data in each second sub-collection data of each server to obtain the normalized value corresponding to each type of data in each second sub-collection data of each server.
[0172] In some embodiments, each type of data in each first sub-collection data of each server is normalized to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and each type of data in each second sub-collection data of each server is normalized to obtain a normalized value corresponding to each type of data in each second sub-collection data of each server, satisfying the following condition:
[0173]
[0174] in, The first sub-collection data in each i The first type of collected data corresponds to the i Normalized value, For the first i The normalized value corresponds to the first sub-collection data in the first data segment. i This type of data collection For multiple first sub-collected data, the first i The minimum value of the collected data, For multiple first sub-collected data, the first i The maximum value of the collected data, among which i It is an integer; or
[0175] The first in each second sub-collected data j The first type of collected data corresponds to the j Normalized value, The first in each second sub-collected data j This type of data collection For multiple second sub-collected data, the first j The minimum value of the collected data, For multiple second sub-collected data, the first j The maximum value of the collected data, among which j It is an integer.
[0176] In some embodiments, when each first sub-collection data includes CPU utilization, disk I / O read / write rate, and network interface card bandwidth utilization, and each second sub-collection data includes CPU utilization, disk I / O read / write rate, and network interface card bandwidth utilization:
[0177] The first normalized value, CPU utilization in each first sub-collection of data. The minimum CPU utilization among multiple first-sub-collection data sets. The maximum CPU utilization among the multiple first-sub-collection data; or
[0178] This is the second normalized value. Disk input / output read / write rate in each of the first sub-collected data sets. The minimum disk input / output read / write rate among multiple first-sub-collection data sets. The maximum value among the disk input / output read / write rates in multiple first-sub-collection data sets; or
[0179] This is the third normalized value. The network interface card bandwidth utilization in each of the first sub-collected data sets. This represents the minimum network interface card bandwidth utilization among multiple first-sub-collection data sets. The maximum value among the network interface card bandwidth utilization rates in multiple first-sub-collection data sets; or
[0180] This is the fourth normalized value. Central processor utilization in each second sub-collection data set. The minimum CPU utilization among multiple second-sub-collection data sets. The maximum CPU utilization among multiple second-sub-collection data sets; or
[0181] This is the fifth normalized value. Disk input / output read / write rates in each of the second sub-collected data sets. The minimum disk I / O read / write rate among multiple second-sub-collection data. The maximum value among the disk input / output read / write rates in multiple second-sub-collection data sets; or
[0182] The sixth normalized value, The network interface card bandwidth utilization in each second sub-collection data point. This represents the minimum network interface card bandwidth utilization among multiple second-sub-collected data sets. This represents the maximum network interface card bandwidth utilization among multiple second-sub-collected data sets.
[0183] The normalization algorithm described above can transform each type of collected data from each server into a constant between 0 and 1, which facilitates the subsequent calculation of the probability density of each collected data.
[0184] S1702: Calculate the probability that the normalized value of each type of data in each first sub-data set of each server falls within a preset interval, thus obtaining the probability density of each type of data in each first sub-data set of each server.
[0185] Calculate the probability that the normalized value of each type of data in each second sub-collection data of each server falls within a preset interval, and the probability density of each type of data in each second sub-collection data of each server.
[0186] When calculating the probability that different normalized values fall into different preset intervals, the following steps may be included:
[0187] First, different preset intervals are set between 0 and 1. These preset intervals can be equally spaced; for example, you could choose to divide them into 10 preset intervals: 0-0.1, 0.1-0.2, ..., 0.9-1. Then, the number of normalized values within each interval is counted. Next, the number of normalized values in each interval is divided by the total number of each type of normalized value. Therefore, using this method, normalized values within the same interval have the same probability density. For example, when calculating the first normalized value, the count of the first normalized value in each interval can be calculated as follows: Figure 4Using the histogram shown, when calculating the probability density corresponding to the first normalized value, for example, the number of first normalized values in the interval 0.2-0.3 is 4. Therefore, the probability density of each first normalized value in this interval is:
[0188] The method described above for calculating probability density is simple and easy to implement, and can quickly obtain the probability density corresponding to each normalized value, which facilitates the subsequent calculation of detection scores.
[0189] In some embodiments, based on a preset detection scoring algorithm, a first detection score corresponding to each first sub-collected data of each server is determined using the probability density corresponding to each type of collected data in each first sub-collected data.
[0190] Based on the preset detection score algorithm, the second detection score for each second sub-collection data of each server is determined by the probability density corresponding to each type of data in each second sub-collection data, satisfying the following conditions:
[0191]
[0192] in, HBOS ( P The first detection score is ) These are the probability densities corresponding to each type of data in each of the first sub-collections, or HBOS ( P The second detection score is ) These represent the probability densities for each type of data collected in each second sub-collection.
[0193] In some examples, HBOS ( P The first detection score is ) The first probability density, The second probability density, For the third probability density, or HBOS ( P The second detection score is ) The fourth probability density, This is the fifth probability density. This is the sixth probability density.
[0194] The above method can be used to calculate the first detection score corresponding to each first sub-collected data of each server and the second detection score corresponding to each second sub-collected data of each server, thereby improving the judgment of whether the server has abnormal power consumption.
[0195] As one implementation method, this application embodiment can construct two models: a power consumption anomaly detection model for the power supply cabinet and a server power consumption anomaly detection model based on the Histogram-based Outlier Score (HBOS) algorithm with linear complexity. The power consumption anomaly detection model for the power supply cabinet is used to detect whether the power consumption of the power supply cabinet is abnormal, and the server power consumption anomaly detection model based on the HBOS algorithm is used to detect whether the power consumption of the server controlled by the power supply cabinet is abnormal. Finally, the cause of the power consumption anomaly of the power supply cabinet is linked to the power consumption anomaly of the server. By combining the two analysis models, the advantages of 1+1>2 are brought into play, which can effectively solve the problem of linking the power consumption anomaly of the power supply cabinet with the power consumption of the server it controls. It can not only give an early warning of the power consumption anomaly of the power supply cabinet, but also give the cause of the anomaly at the same time, that is, which server power consumption anomalies caused the power consumption anomaly of the power supply cabinet, thus providing convenience for operation and maintenance personnel.
[0196] like Figure 5 As shown in the figure, this application embodiment provides a device for detecting the power consumption of a column cabinet, including:
[0197] The acquisition module 201 is used to acquire first collection data of at least one server controlled by the column head cabinet within a first preset time period. The first collection data of each server includes multiple first sub-collection data. Each first sub-collection data includes at least three types of collection data, including CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0198] The weighting module 202 is used to weight the maximum value of each type of data in the multiple first sub-collected data of each server according to the preset weighting rules, so as to obtain the weighted value corresponding to each type of data.
[0199] The calculation module 203 is used to calculate the average value of each type of collected data from at least one server, and obtain the weighted average value for each type of collected data.
[0200] The determination module 204 is used to determine the power consumption detection value of the column head cabinet based on the weighted average value corresponding to each type of collected data.
[0201] The prompt module 205 is used to generate a prompt message indicating abnormal power consumption of the column head cabinet when the power consumption detection value is greater than the preset power consumption threshold.
[0202] In some embodiments, the weighting module weights the maximum value of each type of data in multiple first sub-collected data of each server according to a preset weighting rule, to obtain a weighted value corresponding to each type of data, including:
[0203] The acquisition module is also used to acquire the rated power of each of at least one of the servers.
[0204] The calculation module is also used to calculate the average rated power of at least one server.
[0205] The determination module is also used to determine the weighting coefficient of the corresponding server as the ratio of the rated power of each server to the average rated power.
[0206] The weighting module is also used to weight the maximum value of each type of data in multiple first sub-collected data of each server according to the weighting coefficient.
[0207] In some embodiments, the determining module determines the power consumption detection value of the cabinet based on the weighted average value corresponding to each type of collected data, satisfying the following conditions:
[0208]
[0209] Where y is the power consumption detection value, a, b, c , d as well as n It is a constant. These are the weighted average values for each type of collected data.
[0210] In some embodiments, the apparatus further includes:
[0211] The acquisition module is also used to acquire second acquisition data of at least one server controlled by the column head cabinet within a second preset time period. The second acquisition data of each server includes multiple second sub-acquisition data. Each second sub-acquisition data includes at least three types of acquisition data among CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data.
[0212] The calculation module is also used to calculate the probability density of each type of data in each first sub-collection data of each server, and the probability density of each type of data in each second sub-collection data of each server, according to a preset probability density algorithm.
[0213] The determination module is also used to determine the first detection score corresponding to each first sub-collected data of each server based on a preset detection score algorithm and the probability density corresponding to each type of collected data in each first sub-collected data of each server.
[0214] Based on the preset detection score algorithm, the second detection score corresponding to each second sub-collected data of each server is determined by the probability density corresponding to each type of collected data in each second sub-collected data of each server.
[0215] The sorting module is used to sort the first detection score and the second detection score.
[0216] The prompt module is also used to generate a prompt message indicating abnormal power consumption of the column head cabinet due to abnormal server power consumption when there is a detection score type greater than a threshold among a large number of preset detection scores.
[0217] In some embodiments, the calculation module calculates the probability density corresponding to each type of data in each first sub-collection data of each server, and calculates the probability density corresponding to each type of data in each second sub-collection data of each server, according to a preset probability density algorithm, including:
[0218] The calculation module is also used to normalize each type of data in each first sub-collection data of each server, to obtain the normalized value corresponding to each type of data in each first sub-collection data of each server, and
[0219] Normalize each type of data in each second sub-collection data of each server to obtain the normalized value corresponding to each type of data in each second sub-collection data of each server.
[0220] The calculation module is also used to calculate the probability that the normalized value corresponding to each type of data in each first sub-collection data of each server falls within a preset interval, thereby obtaining the probability density corresponding to each type of data in each first sub-collection data of each server, and
[0221] The calculation module is also used to calculate the probability that the normalized value corresponding to each type of data in each second sub-collection data of each server falls into a preset interval, and the probability density corresponding to each type of data in each second sub-collection data of each server.
[0222] In some embodiments, the calculation module normalizes each type of data in each first sub-collection data of each server to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and normalizes each type of data in each second sub-collection data of each server to obtain a normalized value corresponding to each type of data in each second sub-collection data of each server, satisfying the following conditions:
[0223]
[0224] in, The first sub-collection data in each i The first type of collected data corresponds to the i Normalized value, For the firsti The normalized value corresponds to the first sub-collection data in the first data segment. i This type of data collection For multiple first sub-collected data, the first i The minimum value of the collected data, For multiple first sub-collected data, the first i The maximum value of the collected data, among which i It is an integer.
[0225] The first in each second sub-collected data j The first type of collected data corresponds to the j Normalized value, The first in each second sub-collected data j This type of data collection For multiple second sub-collected data, the first j The minimum value of the collected data, For multiple second sub-collected data, the first j The maximum value of the collected data, among which j It is an integer.
[0226] In some embodiments, the determining module determines the first detection score for each first sub-collected data of each server based on a preset detection score algorithm and the probability density corresponding to each type of collected data in each first sub-collected data.
[0227] Based on the preset detection score algorithm, the second detection score for each second sub-collection data of each server is determined by the probability density corresponding to each type of data in each second sub-collection data, satisfying the following conditions:
[0228]
[0229] in, HBOS ( P The first detection score is ) Let be the probability density corresponding to each type of data in each first sub-data set, , or . HBOS ( P The second detection score is ) These represent the probability densities for each type of data collected in each second sub-collection.
[0230] In some embodiments, the first sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network interface card bandwidth utilization.
[0231] The second set of data collected for each server includes CPU utilization, disk I / O read / write rate, and network interface card bandwidth utilization.
[0232] The apparatus described above is used to implement the power consumption detection method of the corresponding column head cabinet in any of the foregoing embodiments, and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0233] Figure 6 A schematic diagram of the hardware structure of an electronic device is provided in the application embodiment.
[0234] The electronic device may include a processor 301 and a memory 302 storing computer program instructions.
[0235] Specifically, the processor 301 may include a central processing unit (CPU), an application-specific integrated circuit (ASIC), or one or more integrated circuits that can be configured to implement the embodiments of this application.
[0236] Memory 302 may include mass storage for data or instructions. For example, and not limitingly, memory 302 may include a hard disk drive (HDD), floppy disk drive, flash memory, optical disk, magneto-optical disk, magnetic tape, or Universal Serial Bus (USB) drive, or a combination of two or more of these. Where appropriate, memory 302 may include removable or non-removable (or fixed) media. Where appropriate, memory 302 may be internal or external to the integrated gateway disaster recovery device. In a particular embodiment, memory 302 is non-volatile solid-state memory.
[0237] In a particular embodiment, memory 302 includes read-only memory (ROM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (PROM), an erasable PROM (EPROM), an electrically erasable PROM (EEPROM), an electrically rewritable ROM (EAROM), or flash memory, or a combination of two or more of these.
[0238] Memory may include read-only memory (ROM), random access memory (RAM), disk storage media devices, optical storage media devices, flash memory devices, and electrical, optical, or other physical / tangible memory storage devices. Therefore, typically, memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., memory devices) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the method according to the first aspect of this application.
[0239] The processor 301 reads and executes computer program instructions stored in the memory 302 to implement any of the power consumption detection methods for the column head cabinet in the above embodiments.
[0240] In one example, the electronic device may also include a communication interface 303 and a bus 310. Wherein, as... Figure 6 The processor 301, memory 302, and communication interface 303 are connected through bus 310 and complete communication with each other.
[0241] The communication interface 303 is mainly used to realize communication between various modules, devices, units and / or equipment in the embodiments of this application.
[0242] Bus 310 includes hardware, software, or both, that couples components of an online data traffic metering device together. For example, and not limitingly, the bus may include an Accelerated Graphics Port (AGP) or other graphics bus, an Enhanced Industry Standard Architecture (EISA) bus, a Front Side Bus (FSB), HyperTransport (HT) interconnect, an Industry Standard Architecture (ISA) bus, an Infinite Bandwidth Interconnect, a Low Pin Count (LPC) bus, a memory bus, a Microchannel Architecture (MCA) bus, a Peripheral Component Interconnect (PCI) bus, a PCI-Express (PCI-X) bus, a Serial Advanced Technology Attachment (SATA) bus, a Video Electronics Standards Association Local (VLB) bus, or other suitable buses, or combinations of two or more of these. Where appropriate, bus 310 may include one or more buses. Although specific buses are described and illustrated in embodiments of this application, any suitable bus or interconnect is contemplated herein.
[0243] The electronic devices described above are used to implement the power consumption detection method of the corresponding column head cabinet in any of the foregoing embodiments, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.
[0244] Furthermore, in conjunction with the power consumption detection method for the row-head cabinet in the above embodiments, this application embodiment can provide a computer storage medium for implementation. The computer storage medium stores computer program instructions; when these computer program instructions are executed by a processor, they implement any of the power consumption detection methods for the row-head cabinet in the above embodiments.
[0245] Those skilled in the art should understand that the discussion of any of the above embodiments is merely exemplary and is not intended to imply that the scope of this application (including the claims) is limited to these examples; under the concept of this application, the technical features of the above embodiments or different embodiments can also be combined, the steps can be implemented in any order, and there are many other variations of different aspects of the above embodiments of this application, which are not provided in detail for the sake of brevity.
[0246] The functional blocks shown in the above block diagram can be implemented as hardware, software, firmware, or a combination thereof. When implemented in hardware, they can be, for example, electronic circuits, application-specific integrated circuits (ASICs), appropriate firmware, plug-ins, function cards, etc. When implemented in software, the elements of this application are programs or code segments used to perform the required tasks. Programs or code segments can be stored on a machine-readable medium or transmitted over a transmission medium or communication link via data signals carried on a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, fiber optic media, radio frequency (RF) links, etc. Code segments can be downloaded via computer networks such as the Internet, intranets, etc.
[0247] It should also be noted that the exemplary embodiments mentioned in this application describe methods or apparatuses based on a series of steps or devices. However, this application is not limited to the order of the above steps; that is, the steps can be performed in the order mentioned in the embodiments, or in a different order, or several steps can be performed simultaneously.
[0248] The aspects of this application have been described above with reference to flowchart illustrations and / or block diagrams of methods, apparatus (devices), and computer program products according to embodiments of this application. It should be understood that each block in the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus to produce a machine such that these instructions, executable via the processor of the computer or other programmable data processing apparatus, enable the implementation of the functions / actions specified in one or more blocks of the flowchart illustrations and / or block diagrams. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field-programmable logic circuit. It is also understood that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can also be implemented by dedicated hardware performing the specified functions or actions, or can be implemented by a combination of dedicated hardware and computer instructions.
[0249] The above are merely specific embodiments of this application. Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the devices, modules, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here. It should be understood that the protection scope of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the protection scope of this application.
Claims
1. A method for detecting the power consumption of a power supply cabinet, characterized in that, include: Acquire first collection data from at least one server controlled by the column head cabinet within a first preset time period. The first collection data of each server includes multiple first sub-collection data. Each first sub-collection data includes at least three types of collection data from CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. According to the preset weighting rules, the maximum value of each type of data in the multiple first sub-collected data of each server is weighted to obtain the weighted value corresponding to each type of data. Calculate the weighted value for each type of collected data from at least one server and then average it to obtain the weighted average value for each type of collected data. The power consumption detection value of the column head cabinet is determined based on the weighted average value corresponding to each type of collected data. If the power consumption detection value is greater than the preset power consumption threshold, a prompt message indicating abnormal power consumption of the column head cabinet is generated; The step involves weighting the maximum value of each type of data among multiple first sub-collected data from each server according to a preset weighting rule, to obtain a weighted value corresponding to each type of data, including: Obtain the rated power of each of the at least one server; Calculate the average rated power of the at least one server; The ratio of the rated power of each server to the average rated power is determined as the weighting coefficient for the corresponding server; The maximum value of each type of data in the plurality of first sub-collected data of each server is weighted according to the weighting coefficient.
2. The method for detecting the power consumption of the column head cabinet according to claim 1, characterized in that, The power consumption detection value of the column head cabinet is determined based on the weighted average value corresponding to each type of collected data, satisfying the following conditions: Where y is the power consumption detection value, a, b, c , d as well as n These are the weight parameters obtained through training based on the detection function. These are the weighted average values for each type of collected data.
3. The method for detecting the power consumption of the column head cabinet according to claim 1, characterized in that, The method further includes: Acquire second collection data from at least one server controlled by the column head cabinet within a second preset time period. The second collection data of each server includes multiple second sub-collection data. Each second sub-collection data includes at least three types of collection data from the following: CPU utilization rate, disk input / output read / write rate, network card bandwidth utilization rate, CPU fan temperature, memory utilization rate, and graphics card data. Based on the preset probability density algorithm, the probability density corresponding to each type of data in each first sub-collection data of each server is calculated, and the probability density corresponding to each type of data in each second sub-collection data of each server is calculated. According to a preset detection scoring algorithm, the first detection score for each first sub-collected data point of each server is determined based on the probability density corresponding to each type of collected data in each first sub-collected data point of each server. According to the preset detection score algorithm, the second detection score corresponding to each second sub-collection data of each server is determined by the probability density corresponding to each type of collection data in each second sub-collection data of each server. The first detection score and the second detection score are sorted. If, among a large number of preset detection scores, there is a detection score type greater than a threshold that is the first detection score, a prompt message is generated indicating that the power consumption of the column head cabinet is abnormal due to abnormal power consumption of the server.
4. The method for detecting the power consumption of the column head cabinet according to claim 3, characterized in that, The step of calculating the probability density of each type of data in each first sub-collection data of each server, and calculating the probability density of each type of data in each second sub-collection data of each server, according to a preset probability density algorithm, includes: Normalize each type of data in each first sub-collection data of each server to obtain the normalized value corresponding to each type of data in each first sub-collection data of each server, and Normalize each type of data in each second sub-collection data of each server to obtain the normalized value corresponding to each type of data in each second sub-collection data of each server. Calculate the probability that the normalized value of each type of data in each first sub-collection data of each server falls within a preset interval, thus obtaining the probability density of each type of data in each first sub-collection data of each server. Calculate the probability that the normalized value of each type of data in each second sub-collection data of each server falls into a preset interval, and the probability density of each type of data in each second sub-collection data of each server.
5. The method for detecting the power consumption of the column head cabinet according to claim 4, characterized in that, The process of normalizing each type of data in each first sub-collection data of each server to obtain a normalized value corresponding to each type of data in each first sub-collection data of each server, and normalizing each type of data in each second sub-collection data of each server to obtain a normalized value corresponding to each type of data in each second sub-collection data of each server, satisfies the following condition: in, The first sub-collection data in each of the first sub-collection data i The first type of collected data corresponds to the i Normalized value, For the first i The normalized value corresponds to the first sub-collection data in the first data segment. i This type of data collection The first sub-collected data in multiple first sub-collected data i The minimum value of the collected data, The first sub-collected data in multiple first sub-collected data i The maximum value of the collected data, among which i It is an integer; or The first in each second sub-collected data j The first type of collected data corresponds to the j Normalized value, The first in each second sub-collected data j This type of data collection The first of multiple second sub-collected data j The minimum value of the collected data, The first of multiple second sub-collected data j The maximum value of the collected data, among which j It is an integer.
6. The method for detecting the power consumption of the column head cabinet according to claim 3, characterized in that, Based on the preset detection scoring algorithm, the first detection score for each first sub-collected data point of each server is determined by the probability density corresponding to each type of data point in each first sub-collected data point. Based on the preset detection score algorithm, the second detection score for each second sub-collection data of each server is determined by the probability density corresponding to each type of data in each second sub-collection data, satisfying the following conditions: in, HBOS ( P The first detection score is ) These are the probability densities corresponding to each type of data in each of the first sub-collections, or HBOS ( P The second detection score is ) These represent the probability densities for each type of data collected in each second sub-collection.
7. The method for detecting the power consumption of the column head cabinet according to any one of claims 1 or 3, characterized in that, include: The first sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization. The second sub-collected data for each server includes CPU utilization, disk I / O read / write rate, and network card bandwidth utilization.
8. A device for detecting the power consumption of a cabinet head unit, characterized in that, include: The acquisition module is used to acquire first collection data of at least one server controlled by the column head cabinet within a first preset time period. The first collection data of each server includes multiple first sub-collection data. Each first sub-collection data includes at least three types of collection data among CPU utilization, disk I / O read / write rate, network card bandwidth utilization, CPU fan temperature, memory utilization, and graphics card data. The weighting module is used to weight the maximum value of each type of data in the multiple first sub-collected data of each server according to the preset weighting rules, so as to obtain the weighted value corresponding to each type of data. The calculation module is used to calculate the average value of each type of collected data from at least one server, and obtain the weighted average value for each type of collected data. The determination module is used to determine the power consumption detection value of the column head cabinet based on the weighted average value corresponding to each type of collected data; The prompting module is used to generate a prompt message indicating abnormal power consumption of the column head cabinet when the power consumption detection value is greater than a preset power consumption threshold. The step involves weighting the maximum value of each type of data among multiple first sub-collected data from each server according to a preset weighting rule, to obtain a weighted value corresponding to each type of data, including: Obtain the rated power of each of the at least one server; Calculate the average rated power of the at least one server; The ratio of the rated power of each server to the average rated power is determined as the weighting coefficient for the corresponding server; The maximum value of each type of data in the plurality of first sub-collected data of each server is weighted according to the weighting coefficient.
9. An electronic device, characterized in that, The device includes: a processor and a memory storing computer program instructions; When the processor executes the computer program instructions, it implements the power consumption detection method for the column head cabinet as described in any one of claims 1-7.
10. A computer storage medium, characterized in that, The computer storage medium stores computer program instructions, which, when executed by a processor, implement the power consumption detection method for the column head cabinet as described in any one of claims 1-7.