Methods, systems, terminals, and storage media for dynamic monitoring of hard drive performance

By dynamically monitoring the frequency of hard drive performance data collection and adjusting the frequency according to the actual business scenarios of the server, the problems of resource waste and untimely monitoring in existing technologies are solved, and flexible hard drive performance monitoring is achieved.

CN116680151BActive Publication Date: 2026-06-30INSPUR SUZHOU INTELLIGENT TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
INSPUR SUZHOU INTELLIGENT TECH CO LTD
Filing Date
2023-06-16
Publication Date
2026-06-30

Smart Images

  • Figure CN116680151B_ABST
    Figure CN116680151B_ABST
Patent Text Reader

Abstract

This invention relates to the field of server technology, specifically providing a method, system, terminal, and storage medium for dynamic monitoring of hard disk performance. The method includes: setting a matching hard disk performance data collection frequency for a business scenario based on the performance requirements of that scenario; monitoring the actual business scenario of the server and obtaining a target collection frequency matching the actual business scenario; periodically collecting hard disk performance data by calling a hard disk performance data collection script according to the target collection frequency; and using pre-stored standard performance data to determine anomalies in the hard disk performance data and identifying the data as abnormal. This invention can flexibly update the hard disk performance monitoring frequency according to the server's business scenario, thereby avoiding resource waste or untimely hard disk performance monitoring.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of server technology, specifically relating to a method, system, terminal, and storage medium for dynamic monitoring of hard disk performance. Background Technology

[0002] Servers are increasingly used in various business scenarios, such as handling diverse network tasks like data storage, file transfer, network communication, and website hosting. In the internet age, servers play a crucial role as a core component of internet infrastructure. Different business scenarios have varying impacts on hard drive read / write performance and specification requirements.

[0003] Most existing hard drive performance monitoring methods involve periodically collecting hard drive performance data and then monitoring for anomalies. The data collection period is a fixed parameter in the configuration file, and the monitoring period remains the same regardless of the server's workload across different business scenarios. Since some servers have a large number of hard drives, collecting hard drive performance data consumes significant server computing resources. This means that if the pre-configured period is too short, it will lead to wasted computing and communication resources for business scenarios with low hard drive requirements; conversely, if the pre-configured period is too long, it will result in untimely monitoring for business scenarios with high hard drive requirements. Summary of the Invention

[0004] To address the problems of inflexible hard drive performance monitoring in existing technologies, which leads to resource waste or untimely monitoring, this invention provides a method, system, terminal, and storage medium for dynamic monitoring of hard drive performance, in order to solve the aforementioned technical problems.

[0005] In a first aspect, the present invention provides a method for dynamic monitoring of hard disk performance, comprising:

[0006] Set a matching hard drive performance data collection frequency for each business scenario based on the business scenario's requirements for hard drive performance.

[0007] Monitor the actual business scenarios of the monitoring server and obtain the target collection frequency that matches the actual business scenarios.

[0008] According to the target acquisition frequency, the hard disk performance data acquisition script is invoked to periodically collect hard disk performance data;

[0009] The hard drive performance data is anomaly determined using pre-stored standard performance data, and the data is identified as anomalous.

[0010] In one optional implementation, a matching hard drive performance data collection frequency is set for the business scenario based on the business scenario's requirements for hard drive performance, including:

[0011] Statistical analysis includes the duration of business scenarios and the number of data interactions with the hard drive;

[0012] The demand index is obtained by calculating the quotient of the number of data interactions to the duration.

[0013] Multiple demand levels and demand index ranges corresponding to each demand level are pre-set, and the demand level of the business scenario is determined based on the demand index range to which the demand index belongs.

[0014] Pre-set the collection frequency corresponding to each demand level, and bind the matching hard disk performance data collection frequency to the business scenario according to the demand level of the business scenario.

[0015] In one optional implementation, monitoring the actual business scenario of the server and obtaining a target sampling frequency matching the actual business scenario includes:

[0016] Monitor the server's task queue and extract the task type from the task queue;

[0017] Obtain the matching business scenario for the task type;

[0018] The matched business scenario is output as the actual business scenario.

[0019] In an optional implementation, obtaining the matching business scenario for the task type includes:

[0020] Statistics on task types and the percentage of tasks corresponding to each task type in business scenarios are compiled and saved as standard parameters for business scenarios.

[0021] Statistically analyze the actual task types and the proportion of each type of task in the server task queue, and convert the actual task types and the proportion of each type of task into feature vectors.

[0022] Calculate the similarity between the feature vector and the standard parameters of the business scenario, and select the business scenario with the highest similarity as the matching business scenario.

[0023] In an optional implementation, a hard disk performance data acquisition script is invoked periodically to collect hard disk performance data according to the target acquisition frequency, including:

[0024] The percentage of server resources used is collected periodically according to the target collection frequency.

[0025] Determine whether the percentage of used resources has reached a set threshold:

[0026] If so, skip the current hard disk performance data acquisition task and generate a delayed acquisition prompt message;

[0027] If not, the hard drive performance acquisition script will be called to obtain hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters.

[0028] In an optional implementation, after generating the delayed acquisition prompt message, the method further includes:

[0029] The number of delayed collection prompt messages is counted, and the number of messages is converted into a frequency coefficient using a pre-set conversion ratio, wherein the frequency coefficient is less than 1;

[0030] Calculate the product of the target acquisition frequency and the frequency coefficient, and use the product as the new target acquisition frequency.

[0031] In one optional implementation, the hard disk performance data is anomaly determined using pre-stored standard performance data, and the data is identified as anomalous, including:

[0032] Pre-configure standard hard drive read / write parameters, standard RAID array parameters, standard hard drive SMART information, and standard network parameters;

[0033] The hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters acquired each time are cached as data to be processed.

[0034] Use a loop function to determine whether each piece of data to be processed is within the corresponding standard parameter range, and output the data that is not within the standard parameter range as abnormal data;

[0035] Clear the data to be processed after the comparison is completed.

[0036] Secondly, the present invention provides a hard disk performance dynamic monitoring system, comprising:

[0037] The frequency setting module is used to set a matching hard drive performance data acquisition frequency for the business scenario based on the business scenario's requirements for hard drive performance.

[0038] The frequency matching module is used to monitor the actual business scenario of the server and obtain the target acquisition frequency that matches the actual business scenario;

[0039] The data acquisition module is used to periodically collect hard disk performance data by calling the hard disk performance data acquisition script according to the target acquisition frequency;

[0040] The anomaly detection module is used to use pre-stored standard performance data to detect anomalies in the hard disk performance data and identify the data as anomalous.

[0041] In one optional implementation, the frequency setting module includes:

[0042] The scenario statistics unit is used to count the duration of a business scenario and the number of data interactions with the hard drive.

[0043] An index calculation unit is used to calculate the quotient of the number of data interactions and the duration to obtain the demand index.

[0044] The level matching unit is used to pre-set multiple demand levels and the demand index range corresponding to each demand level, and to determine the demand level of the business scenario based on the demand index range to which the demand index belongs.

[0045] The frequency binding unit is used to pre-set the collection frequency corresponding to each demand level, and bind the matching hard disk performance data collection frequency to the business scenario according to the demand level of the business scenario.

[0046] In one optional implementation, the frequency matching module includes:

[0047] A queue monitoring unit is used to monitor the server's task queue and extract task types from the task queue.

[0048] The scenario matching unit is used to obtain the matching business scenario of the task type;

[0049] The scenario output unit is used to output the matched business scenario as an actual business scenario.

[0050] In one optional implementation, the scene matching unit includes:

[0051] The task statistics unit is used to count the task types and the percentage of tasks corresponding to each task type in a business scenario, and save them as standard parameters for the business scenario.

[0052] The data transformation unit is used to statistically analyze the actual task types and the proportion of each type of task in the server task queue, and convert the actual task types and the proportion of each type of task into feature vectors.

[0053] The similarity calculation unit is used to calculate the similarity between the feature vector and the standard parameters of the business scenario, and to select the business scenario with the highest similarity as the matching business scenario.

[0054] In one optional implementation, the data acquisition module includes:

[0055] The resource acquisition unit is used to periodically collect the percentage of server resources used according to the target acquisition frequency.

[0056] A resource determination unit is used to determine whether the percentage of used resources has reached a set threshold.

[0057] The acquisition delay unit is used to skip the current hard disk performance data acquisition task and generate a delay acquisition prompt message if the percentage of used resources reaches a set threshold.

[0058] The data acquisition and execution unit is used to call the hard disk performance acquisition script to obtain hard disk read / write parameters, RAID array parameters, hard disk SMART information, and network parameters if the percentage of used resources has not reached the set threshold.

[0059] Furthermore, the data acquisition module also includes:

[0060] An information statistics unit is used to count the number of delayed collection prompt messages and convert the number of messages into a frequency coefficient using a preset conversion ratio, wherein the frequency coefficient is less than 1.

[0061] The frequency adjustment unit is used to calculate the product of the target acquisition frequency and the frequency coefficient, and use the product as the new target acquisition frequency.

[0062] In one optional implementation, the anomaly detection module includes:

[0063] The standard configuration unit is used to preset standard hard drive read / write parameters, standard RAID array parameters, standard hard drive SMART information, and standard network parameters;

[0064] The data caching unit is used to cache the hard disk read / write parameters, RAID array parameters, hard disk SMART information, and network parameters acquired each time as data to be processed.

[0065] The data comparison unit is used to determine whether each piece of data to be processed is within the corresponding standard parameter range using a loop function, and outputs the data to be processed that is not within the standard parameter range as abnormal data.

[0066] The data clearing unit is used to clear the data to be processed after the comparison is completed.

[0067] Thirdly, a terminal is provided, including:

[0068] Processor, memory, among which,

[0069] This memory is used to store computer programs.

[0070] The processor is used to retrieve and run the computer program from memory, causing the terminal to perform the terminal method described above.

[0071] Fourthly, a computer storage medium is provided, wherein instructions are stored therein, which, when executed on a computer, cause the computer to perform the methods described in the above aspects.

[0072] The beneficial effects of this invention are that the hard disk performance dynamic monitoring method, system, terminal, and storage medium provided by this invention, by setting the hard disk performance data collection frequency for different business scenarios, and then monitoring the actual business scenarios of the server, can adjust the hard disk performance data collection frequency in a timely manner according to the actual business scenarios of the server. This invention can flexibly update the hard disk performance monitoring frequency according to the server's business scenarios, thereby avoiding resource waste or untimely hard disk performance monitoring.

[0073] This invention quantifies the hard drive requirements of various business scenarios by statistically analyzing the number of data interactions between the CPU and hard drive in different business scenarios and calculating a demand index, thereby specifying the corresponding data collection frequency. This method is more accurate than manual assessment.

[0074] This invention monitors the server's task queue, extracts data such as task type and percentage, and uses this data as the basis for similarity calculation. This data is then compared with corresponding data from various business scenarios to identify the correct business scenario. This method can quickly identify the server's actual business scenario, allowing for timely adjustments to the data collection frequency.

[0075] Furthermore, the design principle of this invention is reliable, the structure is simple, and it has a very wide range of application prospects. Attached Figure Description

[0076] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0077] Figure 1 This is a schematic flowchart of a method according to an embodiment of the present invention.

[0078] Figure 2 This is another illustrative flowchart of a method according to an embodiment of the present invention.

[0079] Figure 3 This is an example diagram illustrating the data acquisition time of a method according to an embodiment of the present invention.

[0080] Figure 4 This is a schematic block diagram of a system according to an embodiment of the present invention.

[0081] Figure 5 This is a schematic diagram of the structure of a terminal provided in an embodiment of the present invention. Detailed Implementation

[0082] To enable those skilled in the art to better understand the technical solutions of this invention, the technical solutions of the embodiments of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this invention, and not all embodiments. Based on the embodiments of this invention, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this invention.

[0083] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used herein in the description of the invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention.

[0084] The key terms used in this invention will be explained below.

[0085] BMC, short for Baseboard Management Controller, is a remote server management controller. It allows for operations such as firmware upgrades and device monitoring even when the machine is not powered on. Fully implementing IPMI functionality in a BMC requires a powerful 16-bit or 32-bit microcontroller, RAM for data storage, flash memory for non-volatile data storage, and firmware. It provides basic remote manageability for secure remote reboots, secure power-on, LAN alerts, and system health monitoring. In addition to basic IPMI and system monitoring functions, the mBMC can also enable fast BIOS component selection and protection by utilizing one of the two flash memories to store the previous BIOS. For example, if the system fails to boot after a remote BIOS upgrade, remote administrators can switch back to the previous BIOS image to boot the system. Once the BIOS is upgraded, the BIOS image can also be locked to effectively prevent virus attacks.

[0086] BIOS is an abbreviation for "Basic Input Output System." On IBM PC-compatible systems, it's an industry-standard firmware interface. It's a set of programs embedded in a ROM chip on the computer's motherboard. It stores the computer's most important basic input / output programs, power-on self-test (POST) programs, and system boot programs. It can read and write specific system settings from the CMOS. Its main function is to provide the lowest-level, most direct hardware settings and control for the computer. In addition, the BIOS provides some system parameters to the operating system. Changes to system hardware are hidden by the BIOS; programs use BIOS functions rather than directly controlling the hardware. Modern operating systems often bypass the abstraction layer provided by the BIOS and directly control hardware components.

[0087] The CPU (Central Processing Unit) is the core of a computer system for computation and control, and is the final execution module for information processing and program execution.

[0088] The hard disk performance dynamic monitoring method provided in this embodiment of the invention is executed by a computer device, and correspondingly, the hard disk performance dynamic monitoring system runs in the computer device.

[0089] Figure 1 This is a schematic flowchart illustrating a method according to an embodiment of the present invention. Wherein, Figure 1 The executing entity can be a dynamic hard drive performance monitoring system. Depending on different requirements, the order of the steps in this flowchart can be changed, and some can be omitted.

[0090] like Figure 1 As shown, the method includes:

[0091] Step 110: Set a matching hard drive performance data collection frequency for the business scenario based on the business scenario's requirements for hard drive performance.

[0092] Step 120: Monitor the actual business scenario of the server and obtain the target collection frequency that matches the actual business scenario;

[0093] Step 130: According to the target acquisition frequency, call the hard disk performance data acquisition script to periodically collect hard disk performance data;

[0094] Step 140: Use the pre-stored standard performance data to determine the anomalies in the hard disk performance data and identify it as abnormal data.

[0095] To facilitate understanding of the present invention, the following description further illustrates the method for dynamic monitoring of hard disk performance provided by the present invention, based on the principle of the present invention and in conjunction with the process of dynamic monitoring of hard disk performance in the embodiments.

[0096] For details, please refer to Figure 2 The method for dynamic monitoring of hard drive performance includes:

[0097] S1. Set a matching hard drive performance data collection frequency for the business scenario based on the business scenario's requirements for hard drive performance.

[0098] The system collects the duration of business scenarios and the number of data interactions with the hard drive; calculates the quotient of the number of data interactions and the duration to obtain a demand index; pre-sets multiple demand levels and the corresponding demand index ranges for each demand level, and determines the demand level of the business scenario based on the demand index range to which the demand index belongs; pre-sets the collection frequency corresponding to each demand level, and binds a matching hard drive performance data collection frequency to the business scenario according to the demand level of the business scenario.

[0099] For example, if a server is set to run continuously for 1 hour in a first business scenario, and the number of data interactions between the CPU and hard drive within that hour is recorded (i.e., the sum of data reads and writes, X), then the demand index for the first business scenario is X. Then, based on multiple pre-set demand levels and their corresponding demand index ranges, the index range to which X belongs is determined, thus identifying the demand level for the first business scenario. Based on the pre-set collection frequencies corresponding to each demand level, a matching hard drive performance data collection frequency is assigned to the business scenario according to its demand level. This method is used to obtain the corresponding collection frequencies for all business scenarios the server will run.

[0100] S2. Monitor the actual business scenario of the monitoring server and obtain the target collection frequency that matches the actual business scenario.

[0101] The task queue of the monitoring server is used to extract task types; the matching business scenarios of the task types are obtained; and the matching business scenarios are output as actual business scenarios.

[0102] The scenario matching method includes: statistically analyzing the task types and the proportion of tasks corresponding to each task type in a business scenario, and saving them as standard parameters of the business scenario; statistically analyzing the actual task types and the proportion of actual tasks of each type in the server task queue, and converting the actual task types and the proportion of actual tasks of each type into feature vectors; calculating the similarity between the feature vectors and the standard parameters of the business scenario, and selecting the business scenario with the highest similarity as the matching business scenario.

[0103] For example, monitoring the server's task queue reveals 30% data write tasks, 30% data read tasks, and 30% and 30% data sending tasks to third parties. A method for pre-calculating the task types and their corresponding percentages for each business scenario is as follows: Run business scenario A for 1 hour, count all tasks executed by the server within that hour, and parse out all task types and their corresponding percentages. Sort the percentages from highest to lowest, and select the top three task types and their corresponding percentages. Save the selected task types and their corresponding percentages as standard parameters for business scenario A. Calculate the similarity between the current "30% data write tasks, 30% data read tasks, and 30% and 30% data sending tasks to third parties" and the standard parameters for each business scenario. Select the business scenario with the highest similarity as the server's actual business scenario.

[0104] S3. Call the hard disk performance data acquisition script to periodically collect hard disk performance data according to the target acquisition frequency.

[0105] The server's used resource ratio is collected periodically according to the target collection frequency; it is then determined whether the used resource ratio has reached a set threshold: if yes, the current hard disk performance data collection task is skipped and a delayed collection prompt message is generated; if no, the hard disk performance collection script is called to obtain hard disk read / write parameters, RAID array parameters, hard disk SMART information, and network parameters.

[0106] The number of delayed acquisition prompt messages is counted, and the number of messages is converted into a frequency coefficient using a pre-set conversion ratio. The frequency coefficient is less than 1. The product of the target acquisition frequency and the frequency coefficient is calculated, and the product is used as the new target acquisition frequency.

[0107] The frequency of information collection during system operation also affects system performance, so the collection frequency needs to be controlled. Specifically, when setting the conversion ratio, a busy level can be preset. For example, 1-5 items is level one, 5-10 items is level two, and more than 10 items is level three. The frequency coefficient for level one is 0.8, for level two it is 0.6, and for level three it is 0.4. The corresponding frequency coefficient is obtained based on the actual number of delayed collection prompt messages. If the original collection frequency was once every 5 hours and the number of prompt messages was 2, then the new collection frequency would be once every 4 hours.

[0108] In other embodiments of the present invention, real-time data collection can be adopted during the first week of system deployment to quickly obtain current system operating status information as a reference benchmark. After one week of operation, data can be collected once per hour, with each collection lasting 10 minutes, and the cycle repeating every 6 hours. This reduces the system pressure caused by data collection and also covers all time periods.

[0109] The hard drive performance monitoring script collects information from the server, including: hard drive I / O read / write parameters: iostat reads hard drive read / write parameters; CPU / memory utilization: the top 5 applications by utilization are read using the top command; RAID array parameters: if an array exists, array configuration parameters and error count are read; hard drive SMART information: smartctl reads hard drive SMART information; BIOS parameters: power saving settings are read; OS parameters: power saving settings and service-related parameters are read; network parameters: network latency settings and network card error count are read.

[0110] S4. Use the pre-stored standard performance data to determine the anomalies in the hard disk performance data and identify it as abnormal data.

[0111] Pre-set standard hard drive read / write parameters, standard RAID array parameters, standard hard drive SMART information, and standard network parameters; cache the hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters acquired each time as data to be processed; use a loop function to determine whether each piece of data to be processed is within the corresponding standard parameter range, and output the data to be processed that is not within the standard parameter range as abnormal data; clear the data to be processed after comparison.

[0112] Specifically, users input preset performance parameters in advance. The collected information and processing results are stored and archived. The collected information is compared with the preset values ​​to confirm whether it is normal.

[0113] S5, parameter adjustment.

[0114] If abnormal data exists, that is, when IO read / write performance is abnormal, the system parameters are dynamically adjusted according to preset parameters to keep the IO read / write performance at a normal level.

[0115] In some embodiments, the hard disk performance dynamic monitoring system 400 may include multiple functional modules composed of computer program segments. The computer programs of each program segment in the hard disk performance dynamic monitoring system 400 may be stored in the memory of a computer device and executed by at least one processor to perform (see details). Figure 1 (Description) Functionality for dynamic monitoring of hard drive performance.

[0116] In this embodiment, the hard disk performance dynamic monitoring system 400 can be divided into multiple functional modules according to the functions it performs, such as... Figure 4 As shown. The functional modules may include: a frequency setting module 410, a frequency matching module 420, a data acquisition module 430, and an anomaly detection module 440. The module referred to in this invention is a series of computer program segments that can be executed by at least one processor and perform a fixed function, and are stored in memory. In this embodiment, the functions of each module will be described in detail in subsequent embodiments.

[0117] The frequency setting module 410 is used to set a matching hard drive performance data acquisition frequency for the business scenario based on the business scenario's requirements for hard drive performance.

[0118] The frequency matching module 420 is used to monitor the actual business scenario of the server and obtain the target acquisition frequency that matches the actual business scenario.

[0119] The data acquisition module 430 is used to periodically collect hard disk performance data by calling the hard disk performance data acquisition script according to the target acquisition frequency.

[0120] The anomaly detection module 440 is used to use pre-stored standard performance data to detect anomalies in the hard disk performance data and obtain the data as anomalies.

[0121] Optionally, as an embodiment of the present invention, the frequency setting module includes:

[0122] The scenario statistics unit is used to count the duration of a business scenario and the number of data interactions with the hard drive.

[0123] An index calculation unit is used to calculate the quotient of the number of data interactions and the duration to obtain the demand index.

[0124] The level matching unit is used to pre-set multiple demand levels and the demand index range corresponding to each demand level, and to determine the demand level of the business scenario based on the demand index range to which the demand index belongs.

[0125] The frequency binding unit is used to pre-set the collection frequency corresponding to each demand level, and bind the matching hard disk performance data collection frequency to the business scenario according to the demand level of the business scenario.

[0126] Optionally, as an embodiment of the present invention, the frequency matching module includes:

[0127] A queue monitoring unit is used to monitor the server's task queue and extract task types from the task queue.

[0128] The scenario matching unit is used to obtain the matching business scenario of the task type;

[0129] The scenario output unit is used to output the matched business scenario as an actual business scenario.

[0130] Optionally, as an embodiment of the present invention, the scene matching unit includes:

[0131] The task statistics unit is used to count the task types and the percentage of tasks corresponding to each task type in a business scenario, and save them as standard parameters for the business scenario.

[0132] The data transformation unit is used to statistically analyze the actual task types and the proportion of each type of task in the server task queue, and convert the actual task types and the proportion of each type of task into feature vectors.

[0133] The similarity calculation unit is used to calculate the similarity between the feature vector and the standard parameters of the business scenario, and to select the business scenario with the highest similarity as the matching business scenario.

[0134] Optionally, as an embodiment of the present invention, the data acquisition module includes:

[0135] The resource acquisition unit is used to periodically collect the percentage of server resources used according to the target acquisition frequency.

[0136] A resource determination unit is used to determine whether the percentage of used resources has reached a set threshold.

[0137] The acquisition delay unit is used to skip the current hard disk performance data acquisition task and generate a delay acquisition prompt message if the percentage of used resources reaches a set threshold.

[0138] The data acquisition and execution unit is used to call the hard disk performance acquisition script to obtain hard disk read / write parameters, RAID array parameters, hard disk SMART information, and network parameters if the percentage of used resources has not reached the set threshold.

[0139] Optionally, as an embodiment of the present invention, the data acquisition module further includes:

[0140] An information statistics unit is used to count the number of delayed collection prompt messages and convert the number of messages into a frequency coefficient using a preset conversion ratio, wherein the frequency coefficient is less than 1.

[0141] The frequency adjustment unit is used to calculate the product of the target acquisition frequency and the frequency coefficient, and use the product as the new target acquisition frequency.

[0142] Optionally, as an embodiment of the present invention, the anomaly determination module includes:

[0143] The standard configuration unit is used to preset standard hard drive read / write parameters, standard RAID array parameters, standard hard drive SMART information, and standard network parameters;

[0144] The data caching unit is used to cache the hard disk read / write parameters, RAID array parameters, hard disk SMART information, and network parameters acquired each time as data to be processed.

[0145] The data comparison unit is used to determine whether each piece of data to be processed is within the corresponding standard parameter range using a loop function, and outputs the data to be processed that is not within the standard parameter range as abnormal data.

[0146] The data clearing unit is used to clear the data to be processed after the comparison is completed.

[0147] Figure 5 This is a schematic diagram of the structure of a terminal 500 provided in an embodiment of the present invention. The terminal 500 can be used for

[0148] The hard disk performance dynamic monitoring method provided in this embodiment of the invention is executed.

[0149] The terminal 500 may include a processor 510, a memory 520, and a communication module 530. These components communicate via one or more buses. Those skilled in the art will understand that the server structure shown in the figure does not constitute a limitation of the present invention. It may be a bus topology or a star topology, and may include more or fewer components than shown, or combine certain components, or have different component arrangements.

[0150] The memory 520 can be used to store the execution instructions of the processor 510. The memory 520 can be implemented using any type of volatile or non-volatile storage terminal or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. When the execution instructions in the memory 520 are executed by the processor 510, the terminal 500 is able to perform some or all of the steps in the above method embodiments.

[0151] The processor 510 serves as the control center of the storage terminal, connecting various parts of the electronic terminal via various interfaces and lines. It executes software programs and / or modules stored in the memory 520, and calls data stored in the memory to perform various functions of the electronic terminal and / or process data. The processor can be composed of integrated circuits (ICs), such as a single packaged IC or multiple packaged ICs with the same or different functions connected together. For example, the processor 510 may consist only of a central processing unit (CPU). In this embodiment of the invention, the CPU may have a single processing core or include multiple processing cores.

[0152] The communication module 530 is used to establish a communication channel, enabling the storage terminal to communicate with other terminals. It receives user data sent by other terminals or sends user data to other terminals.

[0153] The present invention also provides a computer storage medium, wherein the computer storage medium may store a program, which, when executed, may include some or all of the steps provided in the embodiments of the present invention. The storage medium may be a magnetic disk, an optical disk, read-only memory (ROM), or random access memory (RAM), etc.

[0154] Therefore, this invention sets the hard disk performance data collection frequency for different business scenarios and then monitors the actual business scenarios of the server, thereby adjusting the hard disk performance data collection frequency in a timely manner according to the actual business scenarios of the server. This invention can flexibly update the hard disk performance monitoring frequency according to the server's business scenarios, thereby avoiding resource waste or untimely hard disk performance monitoring. The technical effects achieved by this embodiment can be found in the description above, and will not be repeated here.

[0155] Those skilled in the art will clearly understand that the techniques in the embodiments of the present invention can be implemented using software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solutions in the embodiments of the present invention, or the parts that contribute to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, or any other medium capable of storing program code. It includes several instructions to cause a computer terminal (which may be a personal computer, a server, or a second terminal, a network terminal, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.

[0156] The same or similar parts between the various embodiments in this specification can be referred to mutually. In particular, the terminal embodiments are basically similar to the method embodiments, so the description is relatively simple, and the relevant parts can be referred to the description in the method embodiments.

[0157] In the embodiments provided by this invention, it should be understood that the disclosed systems and methods can be implemented in other ways. For example, the system embodiments described above are merely illustrative. For instance, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between systems or modules may be electrical, mechanical, or other forms.

[0158] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.

[0159] In addition, the functional modules in the various embodiments of the present invention can be integrated into one processing module, or each module can exist physically separately, or two or more modules can be integrated into one module.

[0160] Although the present invention has been described in detail with reference to the accompanying drawings and preferred embodiments, the invention is not limited thereto. Various equivalent modifications or substitutions can be made to the embodiments of the invention by those skilled in the art without departing from the spirit and essence of the invention, and such modifications or substitutions should all be within the scope of the invention. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in the invention should also be covered within the protection scope of the invention. Therefore, the protection scope of the invention should be determined by the scope of the claims.

Claims

1. A method for dynamic monitoring of hard disk performance, characterized in that, include: Set a matching hard drive performance data collection frequency for each business scenario based on the business scenario's requirements for hard drive performance. Monitor the actual business scenarios of the monitoring server and obtain the target sampling frequency that matches the actual business scenarios. According to the target acquisition frequency, the hard disk performance data acquisition script is invoked to periodically collect hard disk performance data; The hard drive performance data is anomaly determined using pre-stored standard performance data, and the data is identified as anomalous. Based on the business scenario's requirements for hard drive performance, set a matching hard drive performance data collection frequency for the business scenario, including: Statistical analysis includes the duration of business scenarios and the number of data interactions with the hard drive; The demand index is obtained by calculating the quotient of the number of data interactions to the duration. Multiple demand levels and demand index ranges corresponding to each demand level are pre-set, and the demand level of the business scenario is determined based on the demand index range to which the demand index belongs. Pre-set the collection frequency corresponding to each demand level, and bind the matching hard disk performance data collection frequency to the business scenario according to the demand level of the business scenario; According to the target acquisition frequency, the hard disk performance data acquisition script is invoked to periodically collect hard disk performance data, including: The percentage of server resources used is collected periodically according to the target collection frequency. Determine whether the percentage of used resources has reached a set threshold: If so, skip the current hard disk performance data acquisition task and generate a delayed acquisition prompt message; If not, the hard drive performance acquisition script is called to obtain hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters; After generating the delayed acquisition prompt message, the method further includes: The number of delayed collection prompt messages is counted, and the number of messages is converted into a frequency coefficient using a pre-set conversion ratio, wherein the frequency coefficient is less than 1; Calculate the product of the target acquisition frequency and the frequency coefficient, and use the product as the new target acquisition frequency.

2. The method according to claim 1, characterized in that, Monitoring the actual business scenarios of the server, and obtaining the target collection frequency that matches the actual business scenarios, including: Monitor the server's task queue and extract the task type from the task queue; Obtain the matching business scenario for the task type; The matched business scenario is output as the actual business scenario.

3. The method according to claim 2, characterized in that, Obtaining the matching business scenario for the task type includes: Statistics on task types and the percentage of tasks corresponding to each task type in business scenarios are compiled and saved as standard parameters for business scenarios. Statistically analyze the actual task types and the proportion of each type of task in the server task queue, and convert the actual task types and the proportion of each type of task into feature vectors. Calculate the similarity between the feature vector and the standard parameters of the business scenario, and select the business scenario with the highest similarity as the matching business scenario.

4. The method according to claim 1, characterized in that, The hard drive performance data is anomaly identified using pre-stored standard performance data, including: Pre-configure standard hard drive read / write parameters, standard RAID array parameters, standard hard drive SMART information, and standard network parameters; The hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters acquired each time are cached as data to be processed. Use a loop function to determine whether each piece of data to be processed is within the corresponding standard parameter range, and output the data that is not within the standard parameter range as abnormal data; Clear the data to be processed after the comparison is completed.

5. A dynamic monitoring system for hard disk performance, characterized in that, include: The frequency setting module is used to set a matching hard drive performance data acquisition frequency for the business scenario based on the business scenario's requirements for hard drive performance. The frequency matching module is used to monitor the actual business scenario of the server and obtain the target acquisition frequency that matches the actual business scenario; The data acquisition module is used to periodically collect hard disk performance data by calling the hard disk performance data acquisition script according to the target acquisition frequency; An anomaly detection module is used to use pre-stored standard performance data to detect anomalies in the hard disk performance data and identify the data as anomalous. Based on the business scenario's requirements for hard drive performance, set a matching hard drive performance data collection frequency for the business scenario, including: Statistical analysis includes the duration of business scenarios and the number of data interactions with the hard drive; The demand index is obtained by calculating the quotient of the number of data interactions to the duration. Multiple demand levels and demand index ranges corresponding to each demand level are pre-set, and the demand level of the business scenario is determined based on the demand index range to which the demand index belongs. Pre-set the collection frequency corresponding to each demand level, and bind the matching hard disk performance data collection frequency to the business scenario according to the demand level of the business scenario; According to the target acquisition frequency, the hard disk performance data acquisition script is invoked to periodically collect hard disk performance data, including: The percentage of server resources used is collected periodically according to the target collection frequency. Determine whether the percentage of used resources has reached a set threshold: If so, skip the current hard disk performance data acquisition task and generate a delayed acquisition prompt message; If not, the hard drive performance acquisition script is called to obtain hard drive read / write parameters, RAID array parameters, hard drive SMART information, and network parameters; After generating the delayed data collection notification message, the following is also included: The number of delayed collection prompt messages is counted, and the number of messages is converted into a frequency coefficient using a pre-set conversion ratio, wherein the frequency coefficient is less than 1; Calculate the product of the target acquisition frequency and the frequency coefficient, and use the product as the new target acquisition frequency.

6. A terminal, characterized in that, include: Storage device, used to store programs for dynamic monitoring of hard drive performance; A processor is configured to implement the steps of the hard disk performance dynamic monitoring method as described in any one of claims 1-4 when executing the hard disk performance dynamic monitoring program.

7. A computer-readable storage medium storing a computer program, characterized in that, The readable storage medium stores a hard disk performance dynamic monitoring program, which, when executed by a processor, implements the steps of the hard disk performance dynamic monitoring method as described in any one of claims 1-4.