Time delay monitoring method and device, time delay monitoring equipment and system, medium and product
By obtaining the delay data of concurrent I/O commands and comprehensively evaluating the target delay, the problem that the existing technology cannot fully evaluate SSD performance, and achieve more accurate performance evaluation and delay optimization.
Patent Information
- Application Number
- CN202411362399.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-27
- Publication Date
- 2025-02-25
- Estimated Expiration
- 2044-09-27
AI Technical Summary
The prior art evaluates the performance of a solid-state drive by measuring the delay of a single I/O, which cannot reflect the real delay under concurrent I/O operations and cannot fully evaluate the performance of SSDs.
By obtaining the command data of the hard disk, including at least two concurrent commands, delay triggering is performed, the first and second delay data are obtained, the target delay data is comprehensively determined, the hard disk delay status is evaluated based on the target delay data, and based on the The delay optimization rules perform delay optimization and determine the delay monitoring optimization results.
It realizes more comprehensive and accurate processing of command data containing multiple concurrent commands, can more accurately evaluate the performance of the hard disk, and improve the overall performance of the system through delay optimization rules.
Smart Images

Figure CN119517136A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of delay monitoring technology, and in particular to a delay monitoring method, device, delay monitoring equipment, system, medium and product. Background Art
[0002] With the development of information technology and the increasing demand for data processing, solid state disks (SSDs) have been widely used in modern computer systems as a high-performance storage medium. SSDs have the advantages of fast read and write speeds, low power consumption, and impact resistance, and are particularly suitable for application scenarios such as high-performance computing and big data processing. Gradually, the input / output (I / O) latency problem has become an important factor affecting the overall system performance and user experience.
[0003] Currently, in the existing technology, for the experimental measurement of I / O latency, a single command experimental measurement is usually used, that is, the performance of the solid-state drive is evaluated by measuring the latency of a single I / O. This method is simple and intuitive, but it cannot reflect the actual latency under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. Summary of the invention
[0004] The present invention provides a latency monitoring method, apparatus, latency monitoring equipment, system, medium and product, which are used to solve the defects in the prior art that the performance of a solid-state hard disk is evaluated by measuring the latency of a single I / O, which cannot reflect the actual latency situation under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. The present invention realizes command data containing multiple concurrent commands, comprehensively determines the target latency data of the command data, evaluates the latency of the hard disk based on the target latency data, optimizes the latency based on latency optimization rules, determines the latency monitoring optimization result, realizes more comprehensive and accurate processing of the command data, and comprehensively evaluates the performance of the hard disk.
[0005] The present invention provides a delay monitoring method, comprising the following steps.
[0006] Obtain command data of the hard disk; wherein the command data is data containing at least two concurrent commands.
[0007] After delay triggering according to the command data of the hard disk, first delay data is obtained, and the command type corresponding to the command data is distinguished and processed according to the command data to obtain a partition processing result.
[0008] After delay triggering is performed according to the partition processing result, second delay data is obtained.
[0009] The target delay data is determined according to the first delay data and the second delay data.
[0010] The delay monitoring optimization result is determined according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
[0011] According to a latency monitoring method provided by the present invention, command data of a hard disk is obtained, including: obtaining an initial cache command of the hard disk; when the command number of the initial cache command is equal to a preset number, determining all the initial cache commands as command data; wherein the preset number is a preset number of cache commands; when the command number of the initial cache command is less than the preset number, continuing to obtain the initial cache number until the command number is equal to the preset number.
[0012] According to a delay monitoring provided by the present invention, the command type corresponding to the command data is differentiated and processed according to the command data to obtain a partition processing result, including: distinguishing and processing the command type corresponding to the command data according to the command data to determine whether the command type is a computer interface command; when it is determined that the command type is a computer interface command, obtaining the partition processing result according to the command data and a partition processing algorithm.
[0013] According to a latency monitoring provided by the present invention, before determining the latency monitoring optimization result according to the target latency data and the latency optimization rule, the method further includes: configuring a latency threshold; wherein the latency threshold is a preset threshold for determining the latency of the hard disk; when the target latency data is less than or equal to the latency threshold, determining that the command data is normal; when the target latency data is greater than the latency threshold, determining that the command data is abnormal, obtaining an alarm message, and continuing to execute the step of determining the latency monitoring optimization result according to the target latency data and the latency optimization rule; wherein the alarm message is used to inform the hard disk that there is a latency abnormality.
[0014] The present invention also provides a delay monitoring device, comprising the following modules.
[0015] The data acquisition module is used to acquire command data of the hard disk; wherein the command data is data containing at least two concurrent commands.
[0016] The data trigger module is used to obtain first delay data after delay triggering according to the command data of the hard disk, and to distinguish and process the command type corresponding to the command data according to the command data to obtain a partition processing result.
[0017] The result triggering module is used to obtain second delay data after delay triggering according to the partition processing result.
[0018] The data determination module is used to determine the target delay data according to the first delay data and the second delay data.
[0019] The result determination module is used to determine the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
[0020] The present invention also provides a delay monitoring device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements any of the delay monitoring methods described above when executing the computer program.
[0021] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the computer program implements any of the delay monitoring methods described above.
[0022] The present invention also provides a computer program product, including a computer program, and when the computer program is executed by a processor, any of the delay monitoring methods described above is implemented.
[0023] The present invention provides a delay monitoring method, device, delay monitoring equipment, system, medium and product, which obtain command data of a hard disk; wherein the command data is data containing at least two concurrent commands; after delay triggering according to the command data of the hard disk, first delay data is obtained, and the command type corresponding to the command data is distinguished and processed according to the command data to obtain a partition processing result; after delay triggering according to the partition processing result, second delay data is obtained; target delay data is determined according to the first delay data and the second delay data; delay monitoring optimization results are determined according to the target delay data and delay optimization rules; wherein the delay optimization rules refer to rules for optimizing target delay data. The technical solution of the present invention is used to solve the defects in the prior art that the performance of the solid-state hard disk is evaluated by measuring the latency of a single I / O, which cannot reflect the actual latency situation under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. The technical solution of the present invention is used to solve the defects in the prior art that the performance of the solid-state hard disk is evaluated by measuring the latency of a single I / O, which cannot reflect the actual latency situation under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. The technical solution of the present invention is used to solve the defects in the prior art that the performance of the solid-state hard disk is evaluated by comprehensively determining the target latency data of the command data for command data containing multiple concurrent commands, evaluating the latency situation of the hard disk based on the target latency data, optimizing the latency based on latency optimization rules, determining the latency monitoring optimization result, realizing more comprehensive and accurate processing of the command data, and comprehensively evaluating the performance of the hard disk. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0025] Figure 1 It is a flow chart of the delay monitoring method provided by the present invention.
[0026] Figure 2 It is a structural schematic diagram of the delay monitoring device provided by the present invention.
[0027] Figure 3 It is a structural schematic diagram of the delay monitoring device provided by the present invention.
[0028] Figure 4 This is one of the structural schematic diagrams of the delay monitoring system provided by the present invention.
[0029] Figure 5 This is the second structural schematic diagram of the delay monitoring system provided by the present invention.
[0030] Figure 6 This is the third structural schematic diagram of the delay monitoring system provided by the present invention.
[0031] Reference numerals: 40: delay monitoring system; 41: host; 42: delay monitoring device; 421: command acquisition module; 422: command completion module; 423: data processing module; 4231: direct memory access unit; 4232: near field communication unit; 4233: firmware data processing unit; 424: delay monitoring module; 4241: delay recording unit; 4242: data storage unit; 4243: threshold alarm unit; 4244: firmware interaction unit. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0033] Combine the following Figure 1 -Describe the delay monitoring method provided by the present invention. The delay monitoring method provided by the present invention can be applicable to hard disk-based delay monitoring situations. The executor of the method can be a delay monitoring device or a delay monitoring device arranged in the delay monitoring device. The delay monitoring can be achieved through software, hardware or a combination of both. Figure 1 is a flow chart of the delay monitoring method provided by the present invention, such as Figure 1 As shown, the method includes the following steps 101, 102, 103, 104 and 105.
[0034] Step 101: Get command data of the hard disk.
[0035] In this step, the command data is data containing at least two concurrent commands.
[0036] Specifically, command data of at least two concurrent commands of the hard disk sent by the host to the latency monitoring device are received.
[0037] In a specific embodiment, the specific implementation method of obtaining the command data of the hard disk includes: obtaining the initial cache command of the hard disk; when the command number of the initial cache command is equal to a preset number, determining all the initial cache commands as command data; wherein the preset number is a pre-set number of cache commands; when the command number of the initial cache command is less than the preset number, continuing to obtain the initial cache number until the command number is equal to the preset number.
[0038] In this step, the preset number is a preset number of cache commands, for example, 8, 10, etc., which is not limited in this embodiment.
[0039] Specifically, the initial cache command of the hard disk is obtained, and the initial cache command is stored in the command queue. The number of commands that can be stored in the command queue can be, for example, a preset number. When the number of initial cache commands is equal to the preset number, the cache queue is full, and all initial cache commands in the cache queue are determined to be command data. When the number of initial cache commands is less than the preset number, the initial cache number is continuously obtained until the number of commands is equal to the preset number.
[0040] Step 102: After delay triggering according to the command data of the hard disk, first delay data is obtained, and the command type corresponding to the command data is distinguished and processed according to the command data to obtain a partition processing result.
[0041] In this step, the first delay trigger data is the data when the command data is delayed triggered.
[0042] In a specific implementation, the command type corresponding to the command data is differentiated according to the command data, and the specific implementation method for obtaining the partition processing result includes: distinguishing the command type corresponding to the command data according to the command data, and determining whether the command type is a computer interface command; when it is determined that the command type is a computer interface command, obtaining the partition processing result according to the command data and the partition processing algorithm.
[0043] Specifically, after acquiring the command data, a delay trigger is performed based on the command data, and the first delay data is obtained. After the delay trigger is performed, the command type corresponding to the command data is differentiated and processed according to the command data. When the command type is a computer interface command, the partition processing result is obtained according to the command data and the partition processing algorithm.
[0044] Step 103: After delay triggering according to the partition processing result, obtain second delay data.
[0045] In this step, the second delay data is the delay data after the partition processing result is triggered.
[0046] Specifically, after obtaining the partition processing result, delay triggering is performed again according to the partition processing result to obtain second delay data.
[0047] Step 104: Determine target delay data according to the first delay data and the second delay data.
[0048] In this step, the target delay data is the delay of the command data determined based on the first delay data and the second delay data.
[0049] Specifically, after obtaining the first delay data and the second delay data, the target delay data is determined based on the first delay data and the second delay data. The target delay data may be determined, for example, by the sum of the first delay data and the second delay data, or by the average of the first delay data and the second delay data, or by a weight ratio based on the first delay data and the second delay data. This embodiment does not limit this.
[0050] Step 105: Determine the delay monitoring optimization result according to the target delay data and the delay optimization rule.
[0051] In this step, the delay optimization rule refers to a rule for optimizing target delay data.
[0052] In a specific embodiment, before determining the latency monitoring optimization result according to the target latency data and the latency optimization rule, it also includes: configuring the latency threshold; wherein the latency threshold is a preset threshold for determining the latency of the hard disk; when the target latency data is less than or equal to the latency threshold, determining that the command data is normal; when the target latency data is greater than the latency threshold, determining that the command data is abnormal, obtaining an alarm message, and continuing to execute the step of determining the latency monitoring optimization result according to the target latency data and the latency optimization rule; wherein the alarm message is used to inform the hard disk that there is a latency abnormality.
[0053] In this step, the latency threshold is a preset threshold for determining the latency of the hard disk, which is not limited in this embodiment.
[0054] Specifically, configure a delay threshold, determine whether the target delay data is less than or equal to the delay threshold, and when the target delay data is less than or equal to the delay threshold, determine that the command data is normal; when the target delay data is greater than the delay threshold, determine that the command data is abnormal, obtain an alarm message, and continue to execute the step of determining the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the alarm message is used to inform the host hard disk that there is a delay abnormality.
[0055] The present invention provides a delay monitoring method, which obtains command data of a hard disk; wherein the command data is data containing at least two concurrent commands; after delay triggering according to the command data of the hard disk, first delay data is obtained, and the command type corresponding to the command data is differentiated and processed according to the command data to obtain a partition processing result; after delay triggering according to the partition processing result, second delay data is obtained; target delay data is determined according to the first delay data and the second delay data; and delay monitoring optimization results are determined according to the target delay data and delay optimization rules; wherein the delay optimization rules refer to rules for optimizing the target delay data. On the basis of the above embodiments, the technical solution of the present invention is used to solve the defects in the prior art that the performance of the solid-state hard disk is evaluated by measuring the latency of a single I / O, which cannot reflect the actual latency situation under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. It can realize command data containing multiple concurrent commands, comprehensively determine the target latency data of the command data, evaluate the latency of the hard disk based on the target latency data, and optimize the latency based on latency optimization rules, determine the latency monitoring optimization result, realize more comprehensive and accurate processing of command data, and comprehensively evaluate the performance of the hard disk.
[0056] The delay monitoring device provided by the present invention is described below. The delay monitoring device described below and the delay monitoring method described above can be referenced to each other.
[0057] Figure 2 is a schematic diagram of the structure of the delay monitoring device provided by the present invention, referring to Figure 2 As shown, the delay monitoring device 200 includes: a data acquisition module 201, a data triggering module 202, a result triggering module 203, a data determination module 204 and a result determination module 205.
[0058] The data acquisition module 201 is used to acquire command data of the hard disk; wherein the command data is data containing at least two concurrent commands.
[0059] The data trigger module 202 is used to obtain first delay data after delay triggering according to the command data of the hard disk, and to distinguish and process the command type corresponding to the command data according to the command data to obtain a partition processing result.
[0060] The result triggering module 203 is used to obtain second delay data after delay triggering according to the partition processing result.
[0061] The data determination module 204 is configured to determine target delay data according to the first delay data and the second delay data.
[0062] The result determination module 205 is used to determine the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
[0063] In an exemplary embodiment, the data acquisition module 201 is specifically used to: obtain the initial cache command of the hard disk; when the command number of the initial cache command is equal to a preset number, determine all the initial cache commands as command data; wherein the preset number is a preset number of cache commands; when the command number of the initial cache command is less than the preset number, continue to obtain the initial cache number until the command number is equal to the preset number.
[0064] In an exemplary embodiment, the data trigger module 202 is specifically used to: distinguish and process the command type corresponding to the command data according to the command data, and determine whether the command type is a computer interface command; when it is determined that the command type is a computer interface command, obtain a partition processing result according to the command data and the partition processing algorithm.
[0065] In an exemplary embodiment, the device further includes: an alarm module. The alarm module is used to: configure a delay threshold before determining a delay monitoring optimization result according to target delay data and delay optimization rules; wherein the delay threshold is a preset threshold for determining the delay condition of the hard disk; when the target delay data is less than or equal to the delay threshold, determine that the command data is normal; when the target delay data is greater than the delay threshold, determine that the command data is abnormal, obtain an alarm message, and continue to execute the step of determining a delay monitoring optimization result according to the target delay data and the delay optimization rules; wherein the alarm message is used to inform the hard disk of the existence of a delay abnormality.
[0066] The device of this embodiment can be used to execute the method of any embodiment in the delay monitoring method side embodiment. Its specific implementation process and technical effects are similar to those in the delay monitoring method side embodiment. For details, please refer to the detailed introduction in the delay monitoring method side embodiment, which will not be repeated here.
[0067] Figure 3 is a schematic diagram of the structure of the delay monitoring device provided by the present invention, such as Figure 3As shown, the delay monitoring device may include: a processor 310, a communication interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communication interface 320 and the memory 330 communicate with each other through the communication bus 340. The processor 310 may call the logic instructions in the memory 330 to execute the delay monitoring method, which includes: obtaining command data of the hard disk; wherein the command data is data containing at least two concurrent commands; after delay triggering according to the command data of the hard disk, obtaining first delay data, and distinguishing and processing the command type corresponding to the command data according to the command data to obtain a partition processing result; after delay triggering according to the partition processing result, obtaining second delay data; determining the target delay data according to the first delay data and the second delay data; determining the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to a rule for optimizing the target delay data.
[0068] In addition, the logic instructions in the above-mentioned memory 330 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods of various embodiments of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.
[0069] Figure 4 FIG. 1 is one of the structural diagrams of the delay monitoring system provided by the present invention. Figure 4 As shown, the delay monitoring system 40 includes a host 41 and a delay monitoring device 42.
[0070] In this step, the delay monitoring device 42 includes multiple software devices. Figure 5 This is the second structural diagram of the delay monitoring system provided by the present invention. Figure 5 As shown, the software devices of the delay monitoring device mainly include a command acquisition module 421 , a command completion module 422 , a data processing module 423 and a delay monitoring module 424 .
[0071] Among them, the host is used to obtain the command data of the hard disk; the number of commands is the number of at least two concurrent commands; the command acquisition module is used to receive the command data of the hard disk obtained by the host, and send the command data of the hard disk to the delay monitoring module and the data processing module respectively; the delay monitoring module is used to store the command data of the hard disk, and perform delay triggering based on the command data of the hard disk to obtain the first delay data; the data processing module is used to distinguish and process the command type corresponding to the command data according to the command data after the delay triggering, and obtain the partition processing result; the delay monitoring module is also used to obtain the second delay data after the delay triggering according to the partition processing result; determine the target delay data according to the first delay data and the second delay data; determine the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data, and the delay monitoring optimization result is sent to the command completion module; the command completion module is used to store the delay monitoring optimization result, and feed the delay monitoring optimization result back to the host; the host is also used to determine the delay monitoring situation of the hard disk based on the delay monitoring optimization result.
[0072] In this step, command data is data actively generated by the host for sending to the hard disk side. Sending command data to the command acquisition module is a command issued by the host through a high-speed serial computer expansion bus standard (peripheral component interconnect express, PCI-Express) channel to send command data to the command acquisition module. The command acquisition module contains a command queue, which is used to cache command data. When the command queue is full of command data, all command data cached in the command queue are sent to the data processing module. At the same time, each command data obtained in the command queue of the command acquisition module will trigger the delay monitoring module.
[0073] Specifically, the command data of the hard disk is obtained through the host, and the command data is sent to the command acquisition module of the delay monitoring device. After the command acquisition module obtains the command data, the command data is sent to the delay monitoring module and the data processing module respectively; then the command data is stored based on the delay monitoring module, and the delay is triggered based on the command data to obtain the first delay data; after the delay is triggered, the data processing module distinguishes and processes the command type corresponding to the command data according to the command data to obtain the partition processing result; further, after the delay is triggered according to the partition processing result, the delay monitoring module obtains the second delay data, and determines the target delay data based on the first delay data and the second delay data; the delay monitoring optimization result is determined according to the target delay data and the delay optimization rule; finally, the delay monitoring optimization result is sent to the command completion module, so that the command completion module stores the delay monitoring optimization result, and feeds back the delay monitoring optimization result to the host, and the host can determine the delay monitoring situation of the hard disk based on the delay monitoring optimization result.
[0074] In a specific implementation, the delay monitoring system further includes: a dynamic random access memory.
[0075] The dynamic random access memory is used to send a trigger signal to the delay monitoring module, obtain the command data of the hard disk in the delay monitoring module based on the trigger signal, and store the command data of the hard disk.
[0076] In a specific implementation, the data processing module 423 includes a direct memory access unit 4231 , a near field communication unit 4232 , and a firmware data processing unit 4233 .
[0077] Among them, the firmware data processing unit is used to distinguish and process the command data of the hard disk and the command type corresponding to the command data of the hard disk, obtain the partition processing result, and send the partition processing result to the near field communication unit; the near field communication unit is used to receive the partition processing result, and trigger the delay monitoring module based on the partition processing result, obtain the command processing result, and send the command processing result to the firmware data processing unit; the firmware data processing unit is also used to start and configure the direct memory access unit based on the command processing result; the direct memory access unit is used to send the command processing result to the command completion module.
[0078] In this step, the data processing module is a software module, which can usually run on the cortex R8 core. The data processing module will further process the received command data. Differentiate and process according to the command type of the command data. If the command type is an I / O command, then nand flash (a memory used to store a large amount of data) needs to be operated. The data processing module will pass the command processing result after processing the command data to the algorithm module and send it to the command completion module.
[0079] Specifically, after the data processing module obtains the command data sent by the command acquisition module, the firmware data processing unit distinguishes and processes the command data of the hard disk and the command type corresponding to the command data of the hard disk, obtains a partition processing result, and sends the partition processing result to the near field communication unit. The near field communication unit receives the partition processing result, and triggers the delay monitoring module based on the partition processing result to obtain the command processing result, and sends the command processing result to the firmware data processing unit. The firmware data processing unit starts and configures the direct memory access unit based on the command processing result, and the direct memory access unit sends the command processing result to the command completion module.
[0080] Furthermore, when the near field communication unit receives the partition processing result, a timer of a delay monitoring module will be triggered. When the timer is triggered, the delay data generated by the timer is saved in the data storage unit in the delay monitoring module. When the near field communication unit obtains the command processing result, the command data result will be sent to the firmware data processing unit again. At the same time, when the near field communication unit obtains the command processing result, the delay monitoring module will be triggered once, and the timer of the delay recording unit in the delay monitoring module will generate delay data and record the delay data in the data storage unit. When the firmware data processing unit receives the command data result processed by the near field communication unit, it will start and configure the direct memory access unit, and send the command data result to the command completion module, and then send it to the host through the command completion module.
[0081] In this step, the configuration of the direct memory access unit requires first generating descriptor data, and then writing the descriptor into the configuration register of the direct memory access unit. After the configuration register of the direct memory access unit is written, the direct memory access unit will start and perform data transmission, and will also trigger the delay control module once. At this time, the delay data generated by the timer of the delay control module will be saved in the data storage unit of the delay monitoring module.
[0082] Specifically, after the direct memory access unit is completed, the command data result will be sent to the command completion module, and then sent to the host through the command completion module. When the command data result is sent to the host by the command completion module, the delay control module will also be triggered once. At this time, the delay data generated by the timer of the delay control module will be saved in the data storage unit of the delay monitoring module, thereby comprehensively obtaining the target delay data.
[0083] In a specific embodiment, Figure 6 This is the third structural diagram of the delay monitoring system provided by the present invention, such as Figure 6As shown, the delay monitoring module 424 includes a delay recording unit 4241, a data storage unit 4242, a threshold alarm unit 4243 and a firmware interaction unit 4244. The delay recording unit is respectively connected to the data storage unit and the threshold alarm unit, and the firmware interaction unit is respectively connected to the data storage unit and the data processing module.
[0084] Among them, the delay recording unit is used to determine the delay data according to the command type corresponding to the command data of the hard disk, and send the delay data to the data storage unit and the threshold alarm unit; the data storage unit is used to store the target delay data and send the target delay data to the firmware interaction unit; the threshold alarm unit is used to configure the delay threshold, generate alarm information according to the delay threshold and the target delay data, and send the alarm information to the firmware interaction unit; the firmware interaction unit is used to send the target delay data and the alarm information to the data processing module; the data processing module is also used to determine the delay optimization rule based on the target delay data and the alarm information, and feed the delay optimization rule back to the command completion module; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
[0085] In this step, the delay recording unit is used to detect and record the target delay data of the concurrent command data; the data storage unit is used to store the target delay data in the programmable controller; the threshold alarm unit is used to configure the delay threshold and generate an alarm message when the target delay data exceeds the delay threshold; the firmware interaction unit is used for the firmware to read the target delay data and optimize the target delay data.
[0086] The advantage of this setting is that the target delay data is combined with the delay threshold to perform delay analysis, and an alarm message is generated when the target delay data exceeds the delay threshold, so that the alarm message can be issued in advance for preventive maintenance. At the same time, the delay monitoring module processes the target delay data through a multi-channel parallel processing mechanism to ensure load balancing of each channel and avoid delay problems caused by overload of some channels.
[0087] In a specific embodiment, the delay recording unit includes a timer, a data processing subunit and a data queue, the timer and the data processing subunit are respectively connected to the data storage unit and the command acquisition module, the timer is connected to the data processing subunit, and the data queue is connected to the command acquisition module; wherein the timer is used to determine the delay data according to the data identifier of the hard disk command data, and determine whether the recording of the hard disk command data is terminated according to the delay data; the data processing subunit is used to obtain the delay data, perform data binding according to the delay data and the data identifier, obtain the binding data result, and send the binding data result to the data storage unit; the data queue is used to queue the hard disk command data.
[0088] In a specific embodiment, the data storage unit includes a programmable controller and a data buffer, the programmable controller is connected to the dynamic random access memory, and the data buffer is connected to the delay recording unit; wherein the programmable controller is used to control the dynamic random access memory; the data buffer is used to store the binding data results.
[0089] In this step, the delay data of the timer is recorded according to the data identifier corresponding to the command data. The data records of the same command data will be aggregated together. When a command data is completed, the data recorded in the command data also needs to be terminated. The command data will be stored in the data buffer. The data buffer is in the data storage unit and is used to temporarily store the target delay data to alleviate the storage pressure under high concurrency. The threshold alarm unit allows the configuration of the delay threshold and generates an alarm message when the delay exceeds the delay threshold. The firmware interaction unit is responsible for communicating with the firmware data processing unit of the data processing module to provide delay data and warning information.
[0090] Exemplarily, for the application scenario of the alarm information of the delay monitoring module, during the operation of the hard disk, the delay threshold can be configured for the delay monitoring module when it is powered on, and then the I / O also configures the delay threshold for the delay monitoring module when it is powered on. When the target delay data of the I / O exceeds the delay threshold, an alarm message will be generated, so that the firmware data processing unit can perceive that the current I / O command data has been abnormal through the alarm message, and the statistical alarm information can be obtained through the firmware interaction unit of the delay monitoring module. The delay monitoring module uses multi-segment recording for a command, which can reduce the scope of the problem to a greater extent. After the firmware interaction unit obtains the alarm information, it can summarize the rules through a certain degree of data analysis and quickly determine the key points of the problem. For example, if the I / O delay of direct memory access is too large, an optimization algorithm can be used to optimize the use of direct memory access resources. In addition, after the hard disk has been applied to the production scenario, the host can count the delay of the hard disk. If the delay is found to be too large, the hard disk team needs to quickly locate the root cause of the problem.
[0091] The advantage of this setting is that the latency monitoring module can configure the latency threshold. When the latency of a command data exceeds the latency threshold, a warning message will be generated and sent to the firmware data processing unit through the firmware interface. This real-time warning mechanism can help the system detect and handle abnormal situations in a timely manner, prevent the accumulation of excessive latency problems, and ensure the stable operation of the system.
[0092] In a specific embodiment, the firmware data processing unit can also further measure and analyze the latency of the hard disk by setting characteristic commands and cooperating with the latency monitoring module. If the latency continues to exceed the standard, the firmware data processing unit can feed back relevant information to the host through the log page based on the data collected by the latency monitoring module, so as to debug and improve the latency problem of the hard disk in the production environment. This diagnostic function helps to quickly locate and solve problems and improve the reliability of the system. The latency monitoring module allows users to configure the latency threshold according to actual needs, and the system can flexibly adapt to different application scenarios. For example, in application scenarios that require high performance, the latency threshold can be set lower to ensure that the system always maintains high performance; in application scenarios that do not require high latency, the latency threshold can be set higher to reduce unnecessary warning messages.
[0093] The present invention provides a delay monitoring system, the delay monitoring device system includes: a host and a delay monitoring device, the delay monitoring device includes a command acquisition module, a command completion module, a data processing module and a delay monitoring module, wherein the host is used to acquire command data of a hard disk; the number of commands is the number of at least two concurrent commands; the command acquisition module is used to receive the command data of the hard disk acquired by the host, and send the command data of the hard disk to the delay monitoring module and the data processing module respectively; the delay monitoring module is used to store the command data of the hard disk, and perform delay triggering based on the command data of the hard disk to obtain first delay data; the data processing module is used to, after the delay is triggered, perform delay triggering based on the command data of the hard disk to obtain first delay data; The data distinguishes and processes the command type corresponding to the command data to obtain the partition processing result; the delay monitoring module is also used to obtain the second delay data after the delay is triggered according to the partition processing result; the target delay data is determined according to the first delay data and the second delay data; the delay monitoring optimization result is determined according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data, and the delay monitoring optimization result is sent to the command completion module; the command completion module is used to store the delay monitoring optimization result, and feed the delay monitoring optimization result back to the host; the host is also used to determine the delay monitoring status of the hard disk based on the delay monitoring optimization result. On the basis of the above embodiments, the technical solution of the present invention, through the interaction between the host and the latency monitoring device, is used to solve the defect that the performance of the solid-state hard disk is evaluated by measuring the latency of a single I / O in the prior art, which cannot reflect the actual latency situation under concurrent I / O operations and cannot comprehensively evaluate the performance of the SSD. For multiple command data, at least two concurrent command data are aggregated and stored and analyzed and processed by the latency monitoring module and the data processing module to obtain the latency monitoring evaluation result, thereby realizing more comprehensive and accurate processing of the command data and comprehensively evaluating the performance of the hard disk.
[0094] On the other hand, the present invention also provides a computer program product, which includes a computer program. The computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the delay monitoring method provided by the above methods, which includes: obtaining command data of the hard disk; wherein the command data is data containing at least two concurrent commands; after delay triggering according to the command data of the hard disk, obtaining first delay data, and distinguishing and processing the command type corresponding to the command data according to the command data to obtain a partition processing result; after delay triggering according to the partition processing result, obtaining second delay data; determining target delay data according to the first delay data and the second delay data; determining the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
[0095] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the processor executes the delay monitoring method provided by the above-mentioned methods, the method comprising: obtaining command data of the hard disk; wherein the command data is data containing at least two concurrent commands; after delay triggering according to the command data of the hard disk, obtaining first delay data, and distinguishing and processing the command type corresponding to the command data according to the command data to obtain a partition processing result; after delay triggering according to the partition processing result, obtaining second delay data; determining target delay data according to the first delay data and the second delay data; determining delay monitoring optimization results according to the target delay data and delay optimization rules; wherein the delay optimization rules refer to rules for optimizing target delay data.
[0096] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.
[0097] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0098] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A delay monitoring method, characterized in that: include: Acquire command data of the hard disk; wherein the command data is data containing at least two concurrent commands; After delay triggering according to the command data of the hard disk, first delay data is obtained, and command types corresponding to the command data are differentiated and processed according to the command data to obtain a partition processing result; After delay triggering according to the partition processing result, obtaining second delay data; Determine target delay data according to the first delay data and the second delay data; Determine a delay monitoring optimization result according to the target delay data and a delay optimization rule; wherein the delay optimization rule refers to a rule for optimizing the target delay data.
2. The delay monitoring method according to claim 1, characterized in that: The step of obtaining the command data of the hard disk includes: Obtaining an initial cache command of the hard disk; When the number of commands of the initial cache commands is equal to a preset number, all the initial cache commands are determined as the command data; wherein the preset number is a preset number of cache commands; When the command quantity of the initial cache command is less than the preset quantity, the initial cache quantity continues to be acquired until the command quantity is equal to the preset quantity.
3. The delay monitoring method according to claim 1, characterized in that: The performing a partitioning process on the command type corresponding to the command data according to the command data to obtain a partitioning process result includes: Distinguishing and processing the command type corresponding to the command data according to the command data, and determining whether the command type is a computer interface command; When it is determined that the command type is the computer interface command, the partition processing result is obtained according to the command data and the partition processing algorithm.
4. The delay monitoring method according to claim 1, characterized in that: Before determining the delay monitoring optimization result according to the target delay data and the delay optimization rule, the method further includes: Configure a latency threshold; wherein the latency threshold is a preset threshold for determining the latency of the hard disk; When the target delay data is less than or equal to the delay threshold, determining that the command data is normal; When the target latency data is greater than the latency threshold, the command data is determined to be abnormal, an alarm message is obtained, and the step of determining the latency monitoring optimization result according to the target latency data and the latency optimization rule is continued; wherein the alarm message is used to inform the hard disk that there is a latency abnormality.
5. A delay monitoring device, characterized in that: include: A data acquisition module, used to acquire command data of the hard disk; wherein the command data is data containing at least two concurrent commands; A data trigger module, configured to obtain first delay data after delay triggering according to the command data of the hard disk, and to distinguish and process the command type corresponding to the command data according to the command data to obtain a partition processing result; A result triggering module, used for obtaining second delay data after delay triggering according to the partition processing result; A data determination module, configured to determine target delay data according to the first delay data and the second delay data; The result determination module is used to determine the delay monitoring optimization result according to the target delay data and the delay optimization rule; wherein the delay optimization rule refers to the rule for optimizing the target delay data.
6. A delay monitoring device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the delay monitoring method according to any one of claims 1 to 4 is implemented.
7. A delay monitoring system, characterized in that: It comprises a host and the delay monitoring device as claimed in claim 6.
8. The delay monitoring system according to claim 7, characterized in that: Also includes: Dynamic random access memory; wherein, The dynamic random access memory is used to send a trigger signal to the delay monitoring device, obtain the command data in the delay monitoring device based on the trigger signal, and store the command data of the hard disk.
9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the delay monitoring method according to any one of claims 1 to 4 is implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the delay monitoring method according to any one of claims 1 to 4 is implemented.
Citation Information
Patent Citations
Command sorting method, method for reducing read delay and solid state disk SSD controller
CN109901785A
Host techniques for stacked memory systems
CN115427925A
Time delay monitoring method and device, storage equipment and storage medium
CN118295878A
Data processing method and its device and information recording medium
JP1999237988A
IO full-lifecycle latency monitoring method and related apparatus
WO2023123956A1