Method for adjusting sampling interval and electronic device

CN122633519BActive Publication Date: 2026-09-29INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611123977.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-28
Publication Date
2026-09-29
Estimated Expiration
2046-07-28

AI Technical Summary

Technical Problem

但是,随着数据中心设备数量的增大、业务场景日趋复杂,采用固定的采样间隔采集性能数据的局限性也逐渐凸显:采样间隔过长会导致核心设备异常检测滞后、故障扩散,而过短则会使低负载设备产生带宽与存储资源浪费

Benefits of technology

[0009]通过本申请,通过数据中心中设备的多个历史性能指标值,量化性能指标趋近预设指标阈值的风险程度,进一步的,通过基础风险值与预设基础风险阈值的比对动态确定风险加权系数,实现对基础风险值的针对性调整,当获取所有性能指标的最终风险值后,基于最终风险值对预设采样间隔进行调整,使得到的第一采样间隔能够在设备高风险运行时缩短采样间隔以捕捉设备指标波动,保障设备异常时能够及时发现,同时,在低风险状态下延长采样间隔以降低设备资源占用、网络带宽消耗及存储成本等,有效解决了相关技术中采用固定采样间隔造成的获取数据不及时与资源浪费的问题。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122633519B_ABST
    Figure CN122633519B_ABST
Patent Text Reader

Abstract

The application discloses a sampling interval adjustment method and an electronic device, and relates to the technical field of computers. The method comprises the following steps: acquiring historical performance index values corresponding to at least one performance index of the device before a current time as a benchmark within a current sampling interval adjustment round; determining a basic risk value corresponding to a first performance index based on the historical performance index value corresponding to the first performance index and a preset index threshold; determining a risk weighting coefficient based on the basic risk value and a preset basic risk threshold; determining a final risk value corresponding to the first performance index based on the basic risk value and the risk weighting coefficient; adjusting a preset sampling interval based on the final risk values corresponding to all performance indexes, to obtain a first sampling interval; and collecting data of the at least one performance index based on the first sampling interval. Through the application, the problem that monitoring is not timely or resources are wasted by using a fixed sampling interval is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer technology, and in particular to a method for adjusting the sampling interval and an electronic device. Background Technology

[0002] With the rapid development of industrial internet, cloud computing, and big data technologies, the clustering and intelligence of equipment are constantly improving. As the core of business operations, real-time monitoring of equipment operating status in data centers is crucial for ensuring business continuity. Equipment performance data collection is a fundamental step, and the rationality of the sampling interval directly affects the timeliness, accuracy, and resource utilization efficiency of the data. Related technologies typically collect equipment performance data through a fixed collection frequency, i.e., a fixed sampling interval. However, as the number of data center devices increases and business scenarios become increasingly complex, the limitations of using a fixed sampling interval for performance data collection are becoming increasingly apparent: an excessively long sampling interval can lead to delayed detection of anomalies in core equipment and the spread of faults, while an excessively short interval can result in wasted bandwidth and storage resources on low-load devices. Therefore, how to rationally set the sampling interval for equipment is a key focus at present. Summary of the Invention

[0003] This application provides a method and electronic device for adjusting the sampling interval, so as to reasonably set the sampling interval of the device.

[0004] This application provides a method for adjusting the sampling interval, applied to data center equipment performance monitoring scenarios. The method includes: Within the current sampling interval adjustment round, obtain the historical performance index values ​​corresponding to at least one performance index of the device before the current time as a reference. The at least one performance index includes one or more of the following: CPU utilization, memory utilization, disk I / O utilization, and network bandwidth utilization. Based on the historical performance index value corresponding to the first performance index and the preset index threshold, the basic risk value corresponding to the first performance index is determined, wherein the first performance index is one of at least one performance index, and the basic risk value is used to characterize the degree of risk of the first performance index approaching the preset index threshold. Based on the basic risk value and the preset basic risk threshold, the risk weighting coefficient is determined, whereby the risk weighting coefficient is used to adjust the basic risk value by weight. Based on the basic risk value and the risk weighting coefficient, determine the final risk value corresponding to the first performance indicator; Once the final risk value corresponding to each of the performance indicators is determined, the preset sampling interval is adjusted based on the final risk value corresponding to each of the performance indicators to obtain the first sampling interval, which is used to collect data on at least one performance indicator based on the first sampling interval.

[0005] This application also provides a sampling interval adjustment device, applied to data center equipment performance indicator monitoring scenarios, including: The acquisition module is used to acquire, within the current sampling interval adjustment round, the historical performance index values ​​corresponding to at least one performance index of the device before the current time as a reference, wherein the at least one performance index includes one or more of the following: CPU utilization, memory utilization, disk input / output utilization, and network bandwidth utilization. The first determining module is used to determine the basic risk value corresponding to the first performance indicator based on the historical performance indicator value corresponding to the first performance indicator and the preset indicator threshold. The first performance indicator is one of at least one performance indicator, and the basic risk value is used to characterize the degree of risk of the first performance indicator approaching the preset indicator threshold. The second determining module is used to determine the risk weighting coefficient based on the basic risk value and the preset basic risk threshold, wherein the risk weighting coefficient is used to adjust the basic risk value by weighting. The third determination module is used to determine the final risk value corresponding to the first performance index based on the basic risk value and the risk weighting coefficient. The adjustment module is used to adjust the preset sampling interval based on the final risk values ​​corresponding to all performance indicators after determining the final risk values ​​corresponding to all performance indicators, to obtain a first sampling interval, which is used to collect data on at least one performance indicator based on the first sampling interval.

[0006] This application also provides an electronic device, including: a memory for storing a computer program; and a processor for implementing the steps of any of the above-described sampling interval adjustment methods when executing the computer program.

[0007] This application also provides a computer-readable storage medium storing a computer program, wherein when the computer program is executed by a processor, it implements the steps of any of the above-described sampling interval adjustment methods.

[0008] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of any of the above-described sampling interval adjustment methods.

[0009] This application quantifies the risk level of performance indicators approaching preset thresholds by using multiple historical performance index values ​​of devices in a data center. Furthermore, it dynamically determines the risk weighting coefficient by comparing the basic risk value with the preset basic risk threshold, enabling targeted adjustments to the basic risk value. After obtaining the final risk value of all performance indicators, the preset sampling interval is adjusted based on the final risk value. This allows the first sampling interval to be shortened during high-risk operation of the device to capture fluctuations in device indicators, ensuring timely detection of device anomalies. At the same time, the sampling interval is extended under low-risk conditions to reduce device resource consumption, network bandwidth consumption, and storage costs, effectively solving the problems of untimely data acquisition and resource waste caused by using a fixed sampling interval in related technologies. Attached Figure Description

[0010] To more clearly illustrate the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0011] Figure 1 A flowchart illustrating a method for adjusting the sampling interval provided in an embodiment of this application; Figure 2 A flowchart illustrating another method for adjusting the sampling interval provided in an embodiment of this application; Figure 3 A schematic diagram of a sampling interval adjustment device provided in an embodiment of this application; Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0012] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of this application.

[0013] It should be noted that, in the description of this application, 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. The terms "first," "second," etc., in this application are used to distinguish similar objects and are not used to describe a specific order or sequence.

[0014] To enable those skilled in the art to better understand the present application, the present application will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0015] First, the application scenarios of the embodiments of this application will be introduced by way of example.

[0016] With the rapid development of industrial internet, cloud computing, and big data technologies, the clustering and intelligence of equipment are constantly improving. As the core of various businesses, the real-time monitoring of the operating status of internal equipment in data centers is crucial to ensuring continuous business operation and improving reliability and service quality. Equipment performance data sampling is a fundamental step, and the rationality of the sampling interval setting directly affects the timeliness and accuracy of the data, as well as impacting equipment resource consumption, network transmission load, and data storage costs.

[0017] In related technologies, a fixed sampling interval, i.e., a fixed sampling frequency, is typically used to collect device performance data. However, with the continuous increase in the number of data center devices and the increasing complexity of business loads and operating scenarios, the limitations of obtaining performance data with a fixed sampling interval are becoming increasingly apparent. On the one hand, for devices carrying core business and operating under high load or high risk conditions, using a longer sampling interval makes it difficult to quickly and timely capture abnormal fluctuations in device indicators, easily causing delays in fault detection, lagging early warnings, and even triggering fault propagation that affects overall business operations. On the other hand, for devices carrying non-core business and operating under low load and low risk conditions, using a shorter sampling interval will continuously generate a large amount of redundant detection data, causing problems such as excessive network bandwidth consumption, a surge in data storage pressure, and waste of device computing resources. Therefore, how to reasonably set the sampling interval for devices is a key focus at present.

[0018] In view of this, embodiments of this application provide a method for adjusting the sampling interval to solve the problems of untimely data acquisition and resource waste caused by using a fixed sampling interval.

[0019] It should be noted that the sampling interval adjustment method provided in this embodiment of the invention can be executed by a sampling interval adjustment device. This device can be implemented as part or all of an electronic device through software, hardware, or a combination of both. The electronic device can be a server or a terminal. In this embodiment, the server can be a single server or a server cluster composed of multiple servers. The terminal in this embodiment can be a smartphone, personal computer, tablet computer, wearable device, or other intelligent hardware device such as an intelligent robot. The following method embodiments will use an electronic device as an example for explanation.

[0020] According to an embodiment of the present invention, a method for adjusting the sampling interval is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0021] Figure 1 This is a flowchart illustrating a method for adjusting the sampling interval according to an embodiment of the present invention. This method is applied to data center equipment performance monitoring scenarios. Figure 1 As shown, the process includes: S101, within the current sampling interval adjustment round, obtain the historical performance index values ​​corresponding to at least one performance index of the device before the current time.

[0022] Among them, at least one of the following performance metrics includes one or more of the following: Central Processing Unit (CPU) utilization, memory utilization, disk input / output (IO) utilization, and network bandwidth utilization.

[0023] Specifically, a single sampling interval adjustment round is a complete process of calculating the final risk value of each performance indicator and adjusting the preset sampling interval based on the final risk value of each performance indicator. The time interval between two sampling interval adjustment rounds can be set according to the actual situation; for example, it can be set to 60 seconds.

[0024] Performance metrics are used to characterize the operating status of a device. For example, taking a server as an example, performance metrics include, but are not limited to, the server's CPU utilization, memory usage, disk I / O utilization, and network bandwidth utilization.

[0025] For example, a preset number of performance indicator values ​​corresponding to each performance indicator of the device before the current time are obtained. In this embodiment, a separate historical data queue is configured for each performance indicator, and the historical data queue of each performance indicator contains a preset number (e.g., 20) of historical performance indicator values. When a newly collected indicator value is added, the indicator value with the earliest collection time is removed to ensure data timeliness. For example, the most recent 10 CPU utilization values ​​are 75%, 82%, 88%, 90%, 85%, 87%, 92%, 91%, 89%, and 86%. In addition, the collection timestamp of each historical performance indicator value can be added to the historical data queue for subsequent abnormal data filtering, such as removing null values ​​from failed collections and abnormal values ​​that exceed reasonable ranges.

[0026] For example, the system retrieves historical performance index values ​​corresponding to at least one performance index of the device within a preset historical period prior to the current time. The preset historical period, which serves as the duration for retrieving historical performance index values, can be set according to actual circumstances. For instance, the preset historical period could be set to 10 minutes prior to the current time.

[0027] S102, Based on the historical performance index value corresponding to the first performance index and the preset index threshold, determine the basic risk value corresponding to the first performance index.

[0028] The first performance indicator is one of at least one performance indicators, and the basic risk value is used to characterize the degree of risk of the first performance indicator approaching a preset indicator threshold.

[0029] Specifically, the preset threshold corresponding to the first performance indicator threshold refers to the critical value for safe operation of that performance indicator, used to determine the degree of risk of the indicator. For example, the preset threshold for CPU utilization is 90%, the preset threshold for memory usage is 85%, the preset threshold for disk I / O utilization is 95%, and the preset threshold for network bandwidth utilization is 80%.

[0030] A higher baseline risk value indicates a higher risk for that indicator. The range of the baseline risk value can be limited according to the actual situation; for example, the range can be set to 0-10. For instance, when the historical CPU utilization value is close to the preset threshold, the baseline risk value can be 8.5; when it is far from the preset threshold, it can be 2.3.

[0031] S103, based on the basic risk value and the preset basic risk threshold, determine the risk weighting coefficient.

[0032] Among them, the risk weighting coefficient is used to adjust the basic risk value with weight.

[0033] Specifically, the risk weighting coefficient is a factor used to adjust the base risk value, either strengthening or weakening it. The base risk value reflects how close the indicator is to its corresponding threshold. By adjusting the base risk value through the risk weighting coefficient, the risk assessment becomes more closely aligned with the actual scenario, such as strengthening the risk value when there is high risk and weakening the risk value when there is low risk.

[0034] A preset basic risk threshold is used to determine the critical value for adjusting the risk weighting coefficient. For example, if the preset basic risk threshold is set to 5, the risk weighting coefficient needs to be dynamically adjusted when the basic risk value is greater than 5, and a fixed preset risk weighting coefficient is used when the basic risk value is less than 5.

[0035] S104. Based on the basic risk value and the risk weighting coefficient, determine the final risk value corresponding to the first performance index.

[0036] Specifically, the final risk value is the risk assessment result after adjusting the basic risk value with a risk weighting coefficient. For example, multiplying the basic risk value by the risk weighting coefficient yields the final risk value.

[0037] S105, after determining the final risk value corresponding to each of the performance indicators, the preset sampling interval is adjusted based on the final risk value corresponding to each of the performance indicators to obtain a first sampling interval, which is used to collect data on at least one performance indicator based on the first sampling interval.

[0038] Specifically, the preset sampling interval is used as the initial time interval for collecting indicators from the device. For example, the preset sampling interval is set to 60 seconds.

[0039] Understandably, if the device has no historical performance index values ​​before the current time, then the first sampling interval determined in the current sampling interval adjustment round will be set as the preset sampling interval.

[0040] In this embodiment, the risk level of performance indicators approaching preset thresholds is quantified by using multiple historical performance index values ​​within the device in the data center. Furthermore, the risk weighting coefficient is dynamically determined by comparing the basic risk value with the preset basic risk threshold, enabling targeted adjustments to the basic risk value. After obtaining the final risk values ​​of all performance indicators, the preset sampling interval is adjusted based on the final risk values. This allows the first sampling interval to be shortened during high-risk device operation to capture fluctuations in device indicators, ensuring timely detection of device anomalies. Simultaneously, the sampling interval is extended during low-risk conditions to reduce device resource consumption, network bandwidth consumption, and storage costs, effectively solving the problems of untimely data acquisition and resource waste caused by using fixed sampling intervals in related technologies.

[0041] Figure 2This is a flowchart of another sampling interval adjustment method provided by an embodiment of the present invention. Figure 2 As shown, the process includes: S201, within the current sampling interval adjustment round, obtain the historical performance index values ​​corresponding to at least one performance index of the device prior to the current time. For details, please refer to [link to relevant documentation]. Figure 1 S101 of the illustrated embodiment will not be described again here.

[0042] S202, Based on the historical performance index value corresponding to the first performance index and the preset index threshold, determine the basic risk value corresponding to the first performance index.

[0043] In this embodiment of the application, S202 includes: S2021, determine the ratio between the historical performance index value corresponding to the first performance index and the preset index threshold.

[0044] Specifically, the ratio between historical performance index values ​​and preset threshold values ​​represents how close the historical performance index values ​​are to the preset threshold values. The higher the ratio, the closer the historical performance index values ​​are to the preset threshold values.

[0045] S2022, according to the preset nonlinear mapping rules, the comparison values ​​are nonlinearly mapped to obtain the basic risk value.

[0046] Specifically, the preset nonlinear mapping rule refers to a nonlinear function or mapping table that converts the ratio into a basic risk value, thereby amplifying the risk of high ratios. The resulting basic risk value can accurately characterize the degree to which the performance index approaches the preset index threshold.

[0047] Optionally, non-linear mapping can be performed by comparing values ​​in the following way: (Formula 1) in, The base risk value for the i-th performance metric. is the ratio between the historical performance index value of the i-th performance index and the preset index threshold, where 'a' is a preset coefficient, for example, a value of 8.

[0048] The above formula shows that the closer the performance indicator is to the preset threshold, the faster the basic risk value increases.

[0049] For example, when there are multiple historical performance index values ​​corresponding to the first performance index, the ratio between each historical performance index value and a preset index threshold can be calculated, and the average of multiple ratios can be non-linearly mapped to obtain the basic risk value. Alternatively, the ratio between the historical performance index value closest to the current time and the preset index threshold among the multiple historical performance index values ​​corresponding to the first performance index can be non-linearly mapped to obtain the basic risk value.

[0050] Furthermore, if the ratio between the historical performance index value and the preset index threshold is greater than 1, a non-linear mapping is performed on the 1; if the ratio is less than or equal to 1, a non-linear mapping is performed on the ratio to obtain the basic risk value corresponding to the first performance index. This is because when the historical performance index value exceeds the preset index threshold, the performance index is already in a high-risk state. If linear calculation is continued based on the actual ratio greater than 1, the basic risk value will be over-amplified, making it impossible to distinguish the risk difference between "slight over-limit" and "severe over-limit," and it is also easy for subsequent risk weighting and sampling interval adjustments to over-respond.

[0051] S203 determines the risk weighting coefficient based on the baseline risk value and a preset baseline risk threshold. For details, please refer to [link to relevant documentation]. Figure 1 S103 of the illustrated embodiment will not be described again here.

[0052] S204, based on the base risk value and risk weighting coefficient, determines the final risk value corresponding to the first performance indicator. For details, please refer to [link to relevant documentation]. Figure 1 S104 of the illustrated embodiment will not be described again here.

[0053] S205: After determining the final risk value corresponding to each performance indicator, the preset sampling interval is adjusted based on the final risk value corresponding to each performance indicator to obtain a first sampling interval, which is used to collect data for at least one performance indicator based on the first sampling interval. For details, please refer to [link to details]. Figure 1 S105 of the illustrated embodiment will not be described again here.

[0054] In this embodiment, the normalization of the degree to which different types of performance indicators approach the threshold is determined by the ratio between historical performance indicator values ​​and preset indicator thresholds, eliminating the evaluation bias caused by differences in indicator thresholds and laying the foundation for cross-indicator risk comparison. Furthermore, the risk of high ratios is amplified by processing the comparison values ​​through nonlinear mapping rules. For example, when the equipment performance indicator approaches the corresponding preset indicator threshold, the basic risk value increases rapidly, so that the obtained basic risk value accurately guarantees the risk level of the performance indicator.

[0055] In one embodiment, based on the foregoing embodiments, the historical performance index value corresponding to the first performance index includes historical performance index values ​​corresponding to multiple historical acquisition times.

[0056] Taking a historical data collection interval of 2 minutes as an example, the historical data of CPU utilization (the primary performance indicator) are as follows: the historical performance indicator value at the collection time of 10:00 is 70%, the historical performance indicator value at the collection time of 10:02 is 76%, the historical performance indicator value at the collection time of 10:04 is 83%, the historical performance indicator value at the collection time of 10:06 is 89%, and the historical performance indicator value at the collection time of 10:08 is 92%.

[0057] In one possible implementation, the risk weighting coefficient is determined based on the base risk value and a preset base risk threshold, specifically including the following: If the basic risk value is less than the preset basic risk threshold, the risk weighting coefficient will be set to the preset risk weighting coefficient.

[0058] Alternatively, if the basic risk value is greater than or equal to the preset basic risk threshold, then based on the historical performance index values ​​corresponding to multiple historical collection times, the index fluctuation characteristics corresponding to the first performance index are determined; based on the index fluctuation characteristics and the preset risk weighting coefficient, the risk weighting coefficient is determined.

[0059] Specifically, a preset basic risk threshold is used as the critical value to trigger the adjustment of the risk weighting coefficient, distinguishing between a performance indicator in a low-risk stable state and a high-risk state. For example, the preset basic risk threshold is set to 2. The preset risk weighting coefficient is a fixed weighting coefficient used in low-risk scenarios; for example, its value is 1.

[0060] Indicator volatility characteristics are used to characterize the trend or dispersion of multiple historical performance indicator values ​​over time. For example, the indicator volatility characteristic is the ratio of the standard deviation to the mean of multiple historical performance indicator values. A larger indicator volatility characteristic indicates more drastic fluctuations, while a smaller characteristic indicates more stable fluctuations.

[0061] If the basic risk value is less than the preset basic risk threshold, it indicates that the equipment is in a low-risk, stable state. In this case, setting the risk weighting coefficient to the preset risk weighting coefficient can reduce the amount of calculation and avoid frequent changes in the weighting coefficient due to small fluctuations. If the basic risk value is greater than or equal to the preset basic risk threshold, it indicates that the equipment is in a high-risk state. In this case, it is necessary to further amplify the risk based on the degree of instability reflected by the indicator fluctuation characteristics. This ensures that the risk adjustment can reflect the degree to which the indicator approaches the threshold and accurately match the intensity and trend of the indicator fluctuation, making the risk weighting coefficient more closely match the differences in actual risk scenarios.

[0062] Optionally, when the basic risk value is greater than or equal to a preset basic risk threshold, the risk weighting coefficient is determined using the following formula: (Formula 2) in, Let be the risk weighting coefficient corresponding to the i-th performance index. Let represent the fluctuation characteristics of the performance index corresponding to the i-th performance index. Here, For example, to preset risk weighting coefficients, The value is 1.

[0063] In one possible implementation, the historical performance index values ​​corresponding to multiple historical acquisition times are fitted by linear regression to obtain the curve slope; based on the curve slope and the preset mapping relationship between the curve slope and the risk weighting coefficient, the risk weighting coefficient is determined.

[0064] Specifically, linear regression analysis is used to analyze the linear correlation between historical performance indicators and the data collection time. The slope of the curve refers to a parameter in the linear regression equation, representing the rate and direction of change of the performance indicator value per unit time. A slope greater than 0 indicates an upward trend, a slope less than 0 indicates a downward trend, and a slope equal to 0 indicates a stable state. In particular, the slope of the curve visually reflects the risk development trend; for example, an upward trend indicates escalating risk, thereby improving the accuracy of risk assessment.

[0065] Furthermore, by establishing a pre-defined mapping relationship between the curve slope and the risk weighting coefficient, the curve slope is quantified into a risk weighting coefficient. For example, when the curve slope is 1.5, the corresponding risk weighting coefficient is 1.5, thus amplifying the base risk value.

[0066] In this way, by fitting the time series of historical index values ​​through linear regression, the changing trend and rate of performance index can be captured. Then, by using a preset mapping relationship, the trend can be quantified into a risk weighting coefficient to achieve dynamic adjustment of risk.

[0067] In one possible implementation, the number of times the performance index value exceeds a preset threshold is counted based on the historical performance index values ​​corresponding to multiple historical collection times; the risk weighting coefficient is determined based on the number of times the preset threshold is exceeded and the mapping relationship between the preset number of times and the risk weighting coefficient.

[0068] Specifically, the number of times the preset indicator threshold is exceeded refers to the number of times the indicator value is greater than or equal to the preset indicator threshold among multiple historical performance indicator values, which is used to quantify the frequency of the indicator being in the high-risk range.

[0069] In this way, by statistically analyzing the number of times performance indicators exceeded the threshold at multiple historical data collection times, the frequency of indicators being in the high-risk range was quantified, and the risk weighting coefficient was determined by combining the preset mapping relationship, thus achieving a precise match between high-risk frequency and risk weighting coefficient.

[0070] In some embodiments, based on any of the foregoing embodiments, the historical performance index value corresponding to the first performance index includes historical performance index values ​​corresponding to multiple historical acquisition times.

[0071] Based on the baseline risk value and risk weighting coefficient, the final risk value corresponding to the first performance indicator is determined, which includes the following steps: First, the basic risk value is adjusted based on the risk weighting coefficient to obtain the adjusted risk value.

[0072] Specifically, the risk weighting coefficient reflects the characteristics of the indicator's volatility intensity and trend. By weighting and strengthening the basic risk value, the adjusted risk value is initially adapted to the volatility scenario.

[0073] For example, the risk weighting factor is multiplied by the base risk value to obtain the adjusted risk value.

[0074] Then, based on the historical performance index values ​​corresponding to multiple historical acquisition times, the average historical performance index is determined.

[0075] Next, determine the difference between the first historical performance index value and the historical performance index mean.

[0076] The first historical performance index value is the historical performance index value of the historical acquisition time closest to the current time.

[0077] Finally, based on the difference and the preset indicator threshold, the adjusted risk value is adjusted again to obtain the final risk value corresponding to the first performance indicator.

[0078] In one possible implementation, the difference is compared with a preset indicator threshold of a preset ratio, and an adjustment value is determined based on the comparison result. Further, based on the adjustment value and a preset maximum risk value, the adjusted risk value is adjusted again to obtain the final risk value.

[0079] Optionally, if the difference is greater than a preset threshold value of a preset ratio, it indicates a sharp increase in the first historical performance indicator value, and the adjustment value is set to a first preset adjustment value, such as 0.5. If the difference is less than or equal to a preset threshold value of a preset ratio, it indicates that the first historical performance indicator value has not changed abruptly, and the adjustment value is set to a second preset adjustment value, such as 0, that is, the adjusted risk value is used as the final risk value. The preset ratio can be set based on the actual situation, for example, a preset ratio of 0.1.

[0080] Furthermore, based on the adjusted value and the preset maximum risk value, the adjusted risk value is adjusted again to obtain the final risk value, specifically including: (Formula 3) in, This represents the final risk value corresponding to the first performance indicator. This is the adjusted risk value. To adjust the value, To preset the maximum risk, for example, The value is 10.

[0081] In some embodiments, based on any of the foregoing embodiments, after determining the final risk value corresponding to each of the performance indicators, the preset sampling interval is adjusted based on the final risk value corresponding to each of the performance indicators to obtain a first sampling interval, which specifically includes the following: a1, based on the preset device weight value corresponding to the device, adjust the preset sampling interval to obtain the second sampling interval.

[0082] Specifically, the preset device weight value corresponding to each device can be set based on the device's business priority and importance. The more important the device, the higher the corresponding preset device weight value. For example, the preset device weight of the core business server (key device) is set to 1.4; the preset device weight of the ordinary server (non-key device) is set to 1.0; and the preset device weight of other devices (idle devices) is set to 0.8.

[0083] For example, the second sampling interval is obtained in the following manner: (Formula 4) in, This is the second sampling interval. The preset sampling interval is w, the preset device weight is w, which means that the higher the preset device weight of the device, the smaller the second sampling interval and the higher the sampling frequency. b is a preset coefficient, for example, b is 2.

[0084] a2. Based on the final risk values ​​corresponding to all performance indicators, determine the overall risk value of the equipment.

[0085] Specifically, the overall risk value of the equipment integrates the final risk value of all performance indicators, reflecting the overall operational risk of the equipment.

[0086] For example, the overall risk value of a device can be determined as follows: (Formula 5) in, For the comprehensive risk value, Let i be the final risk value corresponding to the i-th performance metric. Let be the weight value corresponding to the i-th performance metric, and n be the total number of performance metrics. The weight of each performance metric can be set according to actual needs. For example, the weight values ​​for CPU utilization, memory usage, disk I / O utilization, and network bandwidth utilization are 0.4, 0.3, 0.2, and 0.1, respectively.

[0087] In addition, if at least one performance metric fails to be collected, the weights of each performance metric are adjusted so that the sum of the weights of the remaining performance metrics is 1.

[0088] For example, if the network bandwidth utilization rate fails to be collected among the four indicators (the corresponding weight value of this performance indicator is 0.1), then the weight of CPU utilization rate is adjusted to 0.4 / (1-0.1)≈0.44, the weight of memory utilization rate is 0.3 / (1-0.1)≈0.33, and the weight of disk I / O utilization rate is 0.2 / (1-0.1)≈0.23, which still satisfies the requirement that the weight sum is 1.

[0089] a3, based on the comprehensive risk value and the preset minimum sampling interval, adjust the second sampling interval to obtain the first sampling interval.

[0090] In one possible implementation, the first sampling interval is determined by the following formula.

[0091] (Formula 6) in, The first sampling interval, This is the second sampling interval. The minimum sampling interval, For the comprehensive risk value, This is the preset maximum value for overall risk.

[0092] Taking a key piece of equipment in an extremely high-risk state as an example, assuming the preset sampling interval is 60 seconds, the minimum sampling interval is 5 seconds, the comprehensive risk value is 10, the preset maximum comprehensive risk value is 10, and the preset equipment weight is 1.4, then the second sampling interval is calculated to be 36 seconds using the above formula four, and the first sampling interval is calculated to be 5 seconds using the above formula six.

[0093] Taking a non-critical device in a low-risk state as an example, assuming the preset sampling interval is 60 seconds, the minimum sampling interval is 5 seconds, the comprehensive risk value is 0, the preset maximum comprehensive risk value is 10, and the preset device weight is 0.8, then the second sampling interval calculated by Formula 4 above is 72 seconds, and the first sampling interval obtained by Formula 6 above is still 72 seconds.

[0094] Taking conventional equipment at medium to high risk as an example, assuming the preset sampling interval is 60 seconds, the minimum sampling interval is 5 seconds, the comprehensive risk value is 6, the preset maximum comprehensive risk value is 10, and the preset equipment weight is 1, then the second sampling interval is 60 seconds calculated by formula four above, and the first sampling interval is 27 seconds obtained by formula six above.

[0095] In this embodiment, the preset sampling interval is first adjusted based on the preset device weights, so that core devices can obtain a more intensive sampling frequency, while non-core devices can appropriately reduce the sampling frequency and lengthen the sampling interval to optimize the rationality of resource distribution. Then, the comprehensive risk value of the device is obtained by fusing the final risk value of all performance indicators, and the second sampling interval is optimized in combination with the preset minimum sampling interval. This ensures that the sampling interval can be shortened under high-risk conditions to improve the timeliness of data, while avoiding excessive resource consumption through the minimum interval limit.

[0096] In some embodiments, based on any of the foregoing embodiments, after adjusting the preset sampling interval based on the final risk value corresponding to each of the performance indicators to obtain the first sampling interval, the method provided in this application embodiment further includes the following: First, obtain the historical sampling interval used by the device during the most recent historical performance index collection.

[0097] Specifically, the historical sampling interval is the actual sampling interval used when the device last collected performance index data. For example, if the most recent collection time was 10:05 and the previous collection time was 10:00, the historical sampling interval is 300 seconds. For instance, the historical sampling interval can be derived by using the timestamp of the most recent collection and the timestamp of the previous collection.

[0098] Then, based on the historical sampling interval and the first sampling interval, a third sampling interval is determined to collect data on at least one performance indicator based on the third sampling interval.

[0099] Specifically, the third sampling interval is the final effective interval after fusing the historical sampling interval and the first sampling interval, and is used for the next data collection.

[0100] In one possible implementation, if the first sampling interval is greater than the historical sampling interval, the smaller of the first sampling interval and the historical sampling interval (which is a preset multiple) is determined as the third sampling interval.

[0101] Specifically, when the first sampling interval is greater than the historical sampling interval, if the first sampling interval is amplified without constraints, it may cause a sudden change in the sampling interval, leading to frequent switching of the acquisition device. The amplification process is smoothly transitioned by using a historical sampling interval of a preset multiple, reducing the operating pressure of the equipment.

[0102] For example, assuming the historical sampling interval is 40 seconds, the first sampling interval is 65 seconds, and the preset multiple is 1.5, then the historical sampling interval with the preset multiple is 40 × 1.5 = 60 seconds. The smaller one, 60 seconds, is selected from the first sampling interval and the historical sampling interval with the preset multiple as the third sampling interval.

[0103] In another possible implementation, if the first sampling interval is less than the historical sampling interval, the larger of the first sampling interval and the historical sampling interval of a preset ratio is determined as the third sampling interval.

[0104] Specifically, when the first sampling interval is less than the historical sampling interval, if the first sampling interval decreases without constraint, it will also cause the sampling interval to change abruptly, resulting in frequent switching of the acquisition device. The shrinkage process is smoothly transitioned through the historical sampling interval of the preset ratio.

[0105] For example, assuming the historical sampling interval is 40 seconds, the first sampling interval is 25 seconds, and the preset ratio is 0.5, then the historical sampling interval with the preset ratio is 40 × 0.5 = 20 seconds. The larger of the first sampling interval and the historical sampling interval with the preset ratio, i.e., 25 seconds, is selected as the third sampling interval.

[0106] Furthermore, in this embodiment, a maximum sampling interval can be set to prevent excessively large sampling intervals and low collection frequencies from failing to detect device performance anomalies and faults in a timely manner. A minimum sampling interval can be set to prevent excessively frequent collection due to excessively small sampling intervals, which would consume too much of the device's storage, network, and other resources. If the third sampling interval is greater than the maximum sampling interval, data for each performance indicator is collected at the maximum sampling interval; if the third sampling interval is less than the minimum sampling interval, data for each performance indicator is collected at the minimum sampling interval. In this way, by constraining the third sampling interval between the minimum and maximum sampling intervals, the final sampling interval is ensured to be within a reasonable, safe, and controllable range, avoiding unreasonable sampling intervals. For example, the maximum sampling interval is set to 300 seconds, and the minimum sampling interval is set to 5 seconds.

[0107] In this embodiment, the sampling interval is adjusted by combining the historical sampling interval used in the most recent data collection with the first sampling interval corresponding to the current comprehensive risk. This ensures the adaptability of the sampling interval to the real-time risk, reflects the current risk requirements through the first sampling interval, and avoids sudden changes in the pressure on the data collection device due to excessive adjustment through the historical sampling interval.

[0108] In some embodiments, before determining the risk weighting coefficient based on the basic risk value and the preset basic risk threshold, the method provided in this application embodiment further includes the following: First, obtain the historical baseline risk values ​​corresponding to the first performance index in multiple consecutive historical sampling interval adjustment rounds prior to the current time.

[0109] Specifically, multiple consecutive historical sampling interval adjustment rounds are continuous complete sampling interval adjustment cycles that trace back from the current time. For example, if the current round is the 5th round, then the three consecutive historical rounds are the 2nd, 3rd, and 4th rounds.

[0110] The historical baseline risk value is the baseline risk value obtained in each historical adjustment round by applying the first performance indicator through the ratio calculation and nonlinear mapping described above.

[0111] Then, based on multiple historical sampling intervals, the historical baseline risk values ​​corresponding to the first performance index in each round are adjusted to determine the risk change trend of the first performance index.

[0112] Specifically, risk change trend refers to the direction and rate of risk change obtained based on the changing patterns of multiple consecutive historical baseline risk values. For example, risk change trend includes, but is not limited to, continuous rise (e.g., historical baseline risk values ​​of 6.2, 6.8, and 7.1), continuous fall (e.g., historical baseline risk values ​​of 7.1, 6.8, and 6.2), and stable fluctuation (6.2, 6.5, and 6.1).

[0113] Optionally, the risk change trend of the first performance indicator can be determined in the following way: First, based on multiple historical sampling intervals, the historical baseline risk values ​​corresponding to the first performance index in each adjustment round are determined to determine the change in historical baseline risk values ​​between adjacent rounds.

[0114] Specifically, the change in historical baseline risk value between adjacent rounds refers to the difference in historical baseline risk value corresponding to two adjacent historical sampling interval adjustment rounds, representing the magnitude of increase or decrease in baseline risk value between the two rounds.

[0115] Then, based on the changes in historical baseline risk values ​​between adjacent rounds and the preset weights corresponding to each adjacent round, the comprehensive change value is determined.

[0116] Specifically, the preset weights of adjacent rounds characterize the degree to which changes in the historical baseline risk value affect the risk trend. For example, the closer the preset weight of an adjacent round is to the current time, the greater its weight. This allows recent risk changes to have a greater impact on trend assessment, making trend identification more closely reflect the current reality.

[0117] Finally, based on the comprehensive change amount and the preset mapping relationship between the comprehensive change amount and the risk change trend, the risk change trend of the first performance indicator is determined.

[0118] For example, when the overall change value is greater than 0, the risk change trend is determined to be an upward trend; when the overall change value is less than 0, the risk change trend is determined to be a downward trend; and when the overall change value is 0, the risk change trend is determined to be a stable trend.

[0119] In this way, by first calculating the changes in historical basic risk values ​​between adjacent rounds and then combining the preset weights of each adjacent round to comprehensively determine the risk change trend, the direction and magnitude of risk changes in the first performance indicator can be accurately identified. At the same time, by assigning higher weights to recent changes, the risk trend judgment is more in line with the current operating status of the equipment, effectively improving the accuracy of risk trend identification.

[0120] Optionally, a curve of round number versus historical baseline risk value is fitted using linear regression. The round number is set as x, and the risk value as y. The slope is calculated using the least squares method. If the slope is greater than or equal to a first preset slope (e.g., 0.5), the risk trend is determined to be a continuous upward trend. If the slope is less than or equal to a second preset slope (e.g., -0.5), the risk trend is determined to be a continuous downward trend. If the slope is less than the first preset slope but greater than the second preset slope, the risk trend is determined to be a stable fluctuation trend.

[0121] Finally, based on the risk change trend, the basic risk value is processed to obtain the processed basic risk value, which is used to determine the risk weighting coefficient based on the processed basic risk value and the preset basic risk threshold.

[0122] For example, if the risk trend is continuously rising, the product of the base risk value and the preset amplification factor will be used as the processed base risk value. This is because a continuous upward trend indicates that the risk is escalating, and by amplifying the base risk value, the adjustment of the high-risk weighting factor can be triggered earlier, improving the timeliness of early warning.

[0123] For example, if the risk trend is continuously decreasing, the product of the base risk value and the preset weakening coefficient is used as the processed base risk value. This is because a continuous downward trend indicates that the risk is mitigating, and by weakening the base risk value, unnecessary amplification by the weighting coefficient is avoided, thus saving resources.

[0124] For example, if the risk change trend is a stable fluctuation trend, then no additional processing is applied to the basic risk value; that is, the basic risk value is used as the processed basic risk value.

[0125] Understandably, if there were no previous sampling interval adjustment rounds before the current time, meaning this is the first sampling interval adjustment round, then the basic risk value calculated in the current round will be used as the processed risk value.

[0126] In this embodiment, by adjusting the historical baseline risk value of multiple consecutive historical sampling intervals, the risk change trend of the first performance indicator is accurately identified, and then the current baseline risk value is differentiated and corrected. This makes the processed baseline risk value reflect both the degree to which the performance indicator approaches the corresponding threshold and the direction and rate of risk evolution. For example, the risk value is amplified to strengthen the warning under a continuous upward trend, and the risk value is weakened to avoid over-adjustment under a continuous downward trend. This improves the accuracy of the baseline risk value and optimizes the resource utilization efficiency under a low-risk trend while ensuring the timeliness of warnings for high-risk trends.

[0127] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods according to the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method.

[0128] This application also provides a sampling interval adjustment device for implementing the above embodiments and preferred embodiments, which will not be repeated hereafter. As used below, the term "module" can be a combination of software and / or hardware that implements a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.

[0129] This embodiment provides a sampling interval adjustment device, applied to data center equipment performance indicator monitoring scenarios, such as... Figure 3 As shown, it includes: The acquisition module 301 is used to acquire, within the current sampling interval adjustment round, the historical performance index values ​​corresponding to at least one performance index of the device before the current time as a reference, wherein the at least one performance index includes one or more of the following: CPU utilization, memory utilization, disk input / output utilization, and network bandwidth utilization. The first determining module 302 is used to determine the basic risk value corresponding to the first performance indicator based on the historical performance indicator value corresponding to the first performance indicator and the preset indicator threshold. The first performance indicator is one of at least one performance indicator, and the basic risk value is used to characterize the degree of risk of the first performance indicator approaching the preset indicator threshold. The second determining module 303 is used to determine the risk weighting coefficient based on the basic risk value and the preset basic risk threshold, wherein the risk weighting coefficient is used to adjust the basic risk value by weighting. The third determining module 304 is used to determine the final risk value corresponding to the first performance index based on the basic risk value and the risk weighting coefficient. The adjustment module 305 is used to adjust the preset sampling interval based on the final risk values ​​corresponding to all performance indicators after determining the final risk values ​​corresponding to all performance indicators, to obtain a first sampling interval, which is used to collect data on at least one performance indicator based on the first sampling interval.

[0130] In one possible implementation, the first determining module 302 is specifically used to determine the ratio between the historical performance index value corresponding to the first performance index and the preset index threshold. According to the preset nonlinear mapping rules, the comparison values ​​are nonlinearly mapped to obtain the basic risk value.

[0131] In one possible implementation, the historical performance index value corresponding to the first performance index includes the historical performance index values ​​corresponding to multiple historical collection times. The second determining module 303 is specifically used to determine the risk weighting coefficient as the preset risk weighting coefficient if the basic risk value is less than the preset basic risk threshold. or, If the basic risk value is greater than or equal to the preset basic risk threshold, then the indicator fluctuation characteristics corresponding to the first performance indicator are determined based on the historical performance indicator values ​​corresponding to multiple historical collection times; and the risk weighting coefficient is determined based on the indicator fluctuation characteristics and the preset risk weighting coefficient.

[0132] In one possible implementation, the third determining module 304 is specifically used to perform weighted adjustment on the basic risk value based on the risk weighting coefficient to obtain the adjusted risk value; The average historical performance index is determined based on the historical performance index values ​​corresponding to multiple historical data collection times. Determine the difference between the first historical performance index value and the average historical performance index value, wherein the first historical performance index value is the historical performance index value of the most recent historical acquisition time. Based on the difference and the preset indicator threshold, the adjusted risk value is adjusted again to obtain the final risk value corresponding to the first performance indicator.

[0133] In one possible implementation, the adjustment module 305 is specifically used to adjust the preset sampling interval based on the preset device weight value corresponding to the device to obtain the second sampling interval; Based on the final risk values ​​corresponding to all performance indicators, determine the overall risk value of the equipment; Based on the comprehensive risk value and the preset minimum sampling interval, the second sampling interval is adjusted to obtain the first sampling interval.

[0134] In one possible implementation, the adjustment module 305 obtains the first sampling interval in the following manner:

[0135] in, The first sampling interval, This is the second sampling interval. The minimum sampling interval, For the comprehensive risk value, This is the preset maximum value for overall risk.

[0136] In one possible implementation, the device further includes a fourth determining module, which is used to adjust the preset sampling interval based on the final risk value corresponding to each of the performance indicators, and after obtaining the first sampling interval, obtain the historical sampling interval used by the device in the most recent historical performance indicator collection. Based on the historical sampling interval and the first sampling interval, a third sampling interval is determined, which is used to collect data on at least one performance indicator based on the third sampling interval.

[0137] In one possible implementation, the fourth determining module is specifically used to determine the smaller of the first sampling interval and the historical sampling interval (which is a preset multiple) as the third sampling interval if the first sampling interval is greater than the historical sampling interval. or, If the first sampling interval is less than the historical sampling interval, then the larger of the first sampling interval and the historical sampling interval of the preset ratio is determined as the third sampling interval.

[0138] In one possible implementation, the second determining module 303 is further configured to obtain, before determining the risk weighting coefficient based on the basic risk value and the preset basic risk threshold, the historical basic risk values ​​corresponding to the first performance index in multiple consecutive historical sampling interval adjustment rounds prior to the current time. Based on the historical baseline risk values ​​corresponding to the first performance indicator in multiple historical sampling intervals, the risk change trend of the first performance indicator is determined. Based on the trend of risk changes, the basic risk value is processed to obtain the processed basic risk value, which is then used to determine the risk weighting coefficient based on the processed basic risk value and the preset basic risk threshold.

[0139] The apparatus provided in this application quantifies the risk level of performance indicators approaching preset thresholds by using multiple historical performance index values ​​of devices in a data center. Furthermore, it dynamically determines the risk weighting coefficient by comparing the basic risk value with the preset basic risk threshold, thereby enabling targeted adjustments to the basic risk value. After obtaining the final risk values ​​of all performance indicators, the preset sampling interval is adjusted based on the final risk values. This allows the first sampling interval to be shortened during high-risk device operation to capture fluctuations in device indicators and ensure timely detection of device anomalies. Simultaneously, the sampling interval is extended during low-risk conditions to reduce device resource consumption, network bandwidth consumption, and storage costs, effectively solving the problems of untimely data acquisition and resource waste caused by using fixed sampling intervals in related technologies.

[0140] For a description of the features in the embodiment corresponding to the sampling interval adjustment device, please refer to the relevant description of the embodiment corresponding to the sampling interval adjustment method, which will not be repeated here.

[0141] This application also provides a sampling interval adjustment system. The system includes a data acquisition device, a storage device, a computing device, a configuration management device, and a log and monitoring device.

[0142] The data acquisition device is used to collect performance index values ​​of devices in data center equipment performance monitoring scenarios. For example, the data acquisition device communicates with the devices through acquisition protocols (such as Simple Network Management Protocol (SNMP), Intelligent Platform Management Interface (IPMI), etc.) to obtain various performance index values.

[0143] The storage device is used to store the performance index values ​​of the equipment collected by the acquisition device. In addition, the storage device is also used to store predefined parameters such as preset index thresholds, preset basic risk thresholds, preset sampling intervals, preset nonlinear mapping rules, preset risk weighting coefficients, and preset equipment weight values. For example, the storage device can store the above data using a combination of time-series databases and relational databases.

[0144] The computing device is used to adjust the preset sampling interval based on the collected performance indicators and predefined parameters, so as to sample the device based on the adjusted sampling interval.

[0145] The configuration management device provides a web-based graphical user interface or application programming interface (API) for operations and maintenance personnel to configure the aforementioned predefined parameters.

[0146] The log and monitoring device records sampling interval adjustment logs and supports queries by device, time period, risk value, and other dimensions. It also provides a visual interface to display data such as the current sampling interval, the final risk value corresponding to a specific performance indicator of the device, and generates a sampling interval adjustment trend chart to show the sampling interval change curve. Furthermore, the device has an alarm function; when the final risk value of the device exceeds a preset threshold, it generates an alarm message to promptly notify maintenance personnel.

[0147] Embodiments of this application also provide an electronic device, such as... Figure 4 As shown, it includes a memory 10 and a processor 20. The memory 10 stores a computer program, and the processor 20 is configured to run the computer program to perform the steps in any of the above-described methods for adjusting the sampling interval.

[0148] Embodiments of this application also provide a computer-readable storage medium storing a computer program configured to execute the steps in any of the above-described methods for adjusting the sampling interval.

[0149] In one exemplary embodiment, the aforementioned computer-readable storage medium may include, but is not limited to, various media capable of storing computer programs, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard disk, magnetic disk, or optical disk.

[0150] Embodiments of this application also provide a computer program product, which includes a computer program that, when executed by a processor, implements the steps in any of the above-described methods for adjusting the sampling interval.

[0151] Embodiments of this application also provide another computer program product, including a non-volatile computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps in any of the above-described methods for adjusting the sampling interval.

[0152] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0153] The above provides a detailed description of a sampling interval adjustment method and electronic device provided in this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The descriptions of the embodiments above are merely for the purpose of helping to understand the method and its core ideas. It should be noted that those skilled in the art can make various improvements and modifications to this application without departing from its principles, and these improvements and modifications also fall within the protection scope of the claims of this application.

Claims

1. A method for adjusting the sampling interval, characterized in that, The method, applied to data center equipment performance monitoring scenarios, includes: Within the current sampling interval adjustment round, obtain the historical performance index values ​​corresponding to at least one performance index of the device before the current time as a reference, wherein the at least one performance index includes one or more of the following: CPU utilization, memory utilization, disk input / output utilization, and network bandwidth utilization. Based on the historical performance index value corresponding to the first performance index and the preset index threshold, a basic risk value corresponding to the first performance index is determined, wherein the first performance index is one of the at least one performance index, and the basic risk value is used to characterize the degree of risk of the first performance index approaching the preset index threshold. Based on the basic risk value and the preset basic risk threshold, a risk weighting coefficient is determined, wherein the risk weighting coefficient is used to adjust the basic risk value by weighting. Based on the basic risk value and the risk weighting coefficient, the final risk value corresponding to the first performance index is determined. Once the final risk value corresponding to each of the performance indicators is determined, the preset sampling interval is adjusted based on the final risk value corresponding to each of the performance indicators to obtain a first sampling interval, which is used to collect data on the at least one performance indicator based on the first sampling interval. After determining the final risk value corresponding to each of the performance indicators, the preset sampling interval is adjusted based on the final risk value corresponding to each of the performance indicators to obtain a first sampling interval, including: Based on the preset device weight value corresponding to the device, the preset sampling interval is adjusted to obtain the second sampling interval; Based on the final risk values ​​corresponding to all the aforementioned performance indicators, the overall risk value of the equipment is determined. Based on the comprehensive risk value and the preset minimum sampling interval, the second sampling interval is adjusted to obtain the first sampling interval; The step of adjusting the second sampling interval based on the comprehensive risk value and the preset minimum sampling interval to obtain the first sampling interval includes: in, The first sampling interval, The second sampling interval, The minimum sampling interval, For the comprehensive risk value, This is the preset maximum value for overall risk.

2. The method according to claim 1, characterized in that, The step of determining the basic risk value corresponding to the first performance indicator based on the historical performance indicator value corresponding to the first performance indicator and the preset indicator threshold includes: Determine the ratio between the historical performance index value corresponding to the first performance index and the preset index threshold; The ratio is nonlinearly mapped according to a preset nonlinear mapping rule to obtain the basic risk value.

3. The method according to claim 1 or 2, characterized in that, The historical performance index value corresponding to the first performance index includes historical performance index values ​​corresponding to multiple historical collection times. The step of determining the risk weighting coefficient based on the basic risk value and a preset basic risk threshold includes: If the basic risk value is less than the preset basic risk threshold, then the risk weighting coefficient is determined as the preset risk weighting coefficient; If the basic risk value is greater than or equal to the preset basic risk threshold, then based on the historical performance index values ​​corresponding to the multiple historical collection times, the index fluctuation characteristics corresponding to the first performance index are determined; based on the index fluctuation characteristics and the preset risk weighting coefficient, the risk weighting coefficient is determined.

4. The method according to claim 3, characterized in that, The step of determining the final risk value corresponding to the first performance index based on the basic risk value and the risk weighting coefficient includes: Based on the risk weighting coefficient, the basic risk value is weighted and adjusted to obtain the adjusted risk value; Based on the historical performance index values ​​corresponding to the multiple historical acquisition times, the average historical performance index is determined. Determine the difference between a first historical performance index value and the average historical performance index value, wherein the first historical performance index value is the historical performance index value of the historical acquisition time most recent to the current time; Based on the difference and the preset index threshold, the adjusted risk value is adjusted again to obtain the final risk value corresponding to the first performance index.

5. The method according to claim 1 or 2, characterized in that, After adjusting the preset sampling interval based on the final risk value corresponding to each of the performance indicators to obtain the first sampling interval, the method further includes: Obtain the historical sampling interval used by the device in the most recent historical performance index collection; Based on the historical sampling interval and the first sampling interval, a third sampling interval is determined for data collection of the at least one performance indicator based on the third sampling interval.

6. The method according to claim 5, characterized in that, The step of determining the third sampling interval based on the historical sampling interval and the first sampling interval includes: If the first sampling interval is greater than the historical sampling interval, then the smaller of the first sampling interval and the historical sampling interval of a preset multiple is determined as the third sampling interval; If the first sampling interval is less than the historical sampling interval, then the larger of the first sampling interval and the historical sampling interval of the preset ratio is determined as the third sampling interval.

7. The method according to claim 1 or 2, characterized in that, Before determining the risk weighting coefficient based on the basic risk value and the preset basic risk threshold, the method further includes: Obtain the historical baseline risk values ​​corresponding to the first performance index in multiple consecutive historical sampling interval adjustment rounds prior to the current time; Based on the historical baseline risk values ​​corresponding to the first performance indicator in the adjustment rounds of the multiple historical sampling intervals, the risk change trend of the first performance indicator is determined. Based on the risk change trend, the basic risk value is processed to obtain a processed basic risk value, which is used to determine the risk weighting coefficient based on the processed basic risk value and the preset basic risk threshold.

8. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, configured to implement the steps of the sampling interval adjustment method as described in any one of claims 1-7 when executing the computer program.

Citation Information

Patent Citations

  • Method and system for actively reporting equipment state information

    CN119967020A

  • Voltage droop control optimization method and system based on parameter self-adaption and medium

    CN121150087A