Storage performance testing and analysis method and system
By analyzing the protocol message data between solid-state storage devices, calculating and drawing performance graphs, it solves the problem that existing technology cannot perform fine-grained analysis, achieves accurate location of performance problems of solid-state storage products, and improves test accuracy and efficiency. .
Patent Information
- Application Number
- CN202010254948.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-02
- Publication Date
- 2024-09-20
- Estimated Expiration
- 2040-04-02
AI Technical Summary
Existing solid-state storage performance testing software cannot perform fine-grained analysis and problem location on solid-state storage products, and cannot meet the increasingly high performance and stability requirements.
By obtaining the protocol message data between the HOST and the solid-state storage device, the storage performance data is analyzed, and the performance data is calculated based on the start time, end time, block size and number of blocks of the read/write instructions, and the performance is plotted Figure to locate the problem.
It realizes fine-grained performance analysis and problem location of solid-state storage products, can accurately locate the location of abnormal performance, and improves the accuracy and efficiency of performance testing.
Smart Images

Figure CN113496749B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of storage technology, and in particular to a storage performance testing and analysis method and system. Background Art
[0002] Solid-state storage is a technology that uses electronic storage media to store and read data. It breaks through the performance bottleneck of traditional mechanical hard drives and has extremely high bandwidth and IOPS (Input / Output Per Second) performance.
[0003] Solid-state storage products such as Standard Size SD (SD), micro SD (TF), embedded Multi Media Card (eMMC), and Nano Memory Card (NM) are widely used in various fields such as mobile phones, tablets, cameras, and vehicles. A common challenge they face is how to meet the increasingly high performance and stability requirements.
[0004] Common performance testing software for solid-state storage includes ATTO, IOMeter, CrystalDiskMark, etc. However, these software can only test the overall performance of solid-state storage products. When solid-state storage products have performance anomalies, the above testing tools cannot perform further performance analysis and problem location. At present, there is also a lack of corresponding testing methods and testing tools. Summary of the invention
[0005] Based on this, it is necessary to provide a storage performance testing and analysis method and system to address the problem of being unable to perform fine-grained analysis on solid-state storage products. This method can perform fine-grained performance analysis on solid-state storage products and accurately locate the problem location after performance problems occur in solid-state storage products.
[0006] A storage performance test and analysis method, characterized in that it includes:
[0007] Obtain the protocol message data transmitted between the HOST end and the solid-state storage device;
[0008] Storage performance data is obtained based on the protocol message data analysis.
[0009] In the above storage performance test and analysis method, the step of obtaining storage performance data according to the protocol message data analysis specifically includes:
[0010] Get the start time, end time, block size and number of blocks corresponding to the read / write instruction in the protocol message data;
[0011] The read / write performance data is obtained according to the start time, end time, block size and number of blocks corresponding to the read / write instruction.
[0012] In the above storage performance test and analysis method, the step of obtaining the read / write performance data according to the start time, end time, block size and number of blocks corresponding to the read / write instruction specifically includes:
[0013] The read / write performance data is obtained according to the following calculation formula:
[0014] Spend Time=End Time2-Start Time1;
[0015] Sector Count=Block Count×Block Size;
[0016] Performance=Sector Count / Spend Time;
[0017] In the formula, Spend Time represents the time consumed for transmitting the specified data in the read / write instruction, End Time2 represents the end time corresponding to the read / write instruction, Start Time1 represents the start time corresponding to the read / write instruction, Block count represents the number of blocks corresponding to the read / write instruction, Block size represents the block size set by the HOST end, Sector Count represents the number of bytes of transmission data corresponding to the read / write instruction, and Performance represents the read / write performance data.
[0018] The above storage performance test and analysis method further includes:
[0019] A performance graph is drawn according to the storage performance data.
[0020] The above storage performance test and analysis method further includes:
[0021] A performance graph is drawn in which the horizontal axis is the time corresponding to the transmission of each of the read / write instructions, and the vertical axis is the read / write performance data corresponding to each of the read / write instructions.
[0022] The above storage performance test and analysis method further includes:
[0023] A performance graph is drawn with the horizontal axis representing different numbers of bytes of the transmitted data and the vertical axis representing the read / write performance data of the read / write instructions corresponding to the different numbers of bytes of the transmitted data.
[0024] The above storage performance test analysis method, wherein:
[0025] The solid-state storage device includes any one of SD, TF, eMMC, and NM.
[0026] A storage performance test and analysis system, characterized in that it includes:
[0027] The acquisition module is used to obtain the protocol message data transmitted between the HOST end and the solid-state storage device;
[0028] The analysis and processing module is used to obtain storage performance data based on the analysis of the protocol message data.
[0029] The above storage performance test and analysis system, wherein:
[0030] The acquisition module includes a protocol analyzer or a packet capture tool.
[0031] The above storage performance test and analysis system further includes:
[0032] A drawing module is used to draw a performance graph according to the storage performance data.
[0033] The above-mentioned storage performance test and analysis method and system obtain storage performance data by collecting and analyzing protocol message data during the operation of solid-state storage products. Since the storage performance data is based on protocol message data, it can meet the fine-grained performance analysis requirements at the instruction level. By drawing a performance graph of the storage performance data, the purpose of accurately locating the problem location according to the performance graph when a performance problem occurs in a solid-state storage product is achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0034] Figure 1 A specific flow chart of the storage performance test and analysis method of the present invention;
[0035] Figure 2 A specific method flow chart of the step of obtaining storage performance data according to protocol message data analysis in the storage performance test and analysis method of the present invention;
[0036] Figure 3 An example diagram of protocol message data in an embodiment of the storage performance test and analysis method of the present invention;
[0037] Figure 4 A performance graph in which the horizontal axis represents the time corresponding to the transmission of each write instruction and the vertical axis represents the write performance data corresponding to each write instruction in an embodiment of the storage performance test and analysis method of the present invention;
[0038] Figure 5A performance graph in which the horizontal axis represents different numbers of transmitted data bytes and the vertical axis represents read / write performance data of read / write instructions corresponding to different numbers of transmitted data bytes in an embodiment of the storage performance test and analysis method of the present invention;
[0039] Figure 6 A schematic diagram of the connection structure between the HOST end and the solid-state storage device eMMC in an embodiment of the storage performance analysis system of the present invention;
[0040] Figure 7 It is a schematic diagram of the connection structure of the storage performance analysis system of the present invention. DETAILED DESCRIPTION
[0041] In order to better understand the purpose, technical solution and technical effect of the present invention, the present invention is further explained below in conjunction with the accompanying drawings and embodiments. At the same time, it is stated that the embodiments described below are only used to explain the present invention and are not used to limit the present invention.
[0042] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.
[0043] In the case of using "including", "having", and "comprising" described herein, another component or method may be added unless explicit limiting terms such as "only", "consisting of", etc. are used. Unless mentioned otherwise, a term in the singular form may include a plural form and shall not be understood as being one in number.
[0044] The communication between the HOST end and the component-level solid-state storage device is initiated by the HOST end with a command. After completing the task specified by the command, the storage device returns a response. The command includes but is not limited to a read command and a write command. The component-level solid-state storage device includes but is not limited to SD, TF, eMMC, and NM.
[0045] like Figure 1 As shown, the present invention provides a storage performance test and analysis method, which includes:
[0046] S1. Acquire the protocol message data transmitted between the HOST terminal 1 and the solid-state storage device 2; the acquisition of the protocol message data usually refers to the operation performed when the solid-state storage device 2 is running, and the acquisition time of the protocol message data can be selected as needed; the protocol message data is usually composed of records such as commands and responses, and each record has a corresponding timestamp and some related information.
[0047] S2. Obtain storage performance data based on protocol message data analysis.
[0048] The present invention obtains storage performance data by collecting and analyzing protocol message data during the operation of a solid-state storage product. Since the storage performance data is based on the protocol message data, it can meet the fine-grained performance analysis requirements at the instruction level.
[0049] In one example, after step S2, the following steps may also be included:
[0050] S3. Draw a performance graph based on the storage performance data. By drawing a performance graph based on the storage performance data, when a performance problem occurs in a solid-state storage product, the problem location can be accurately located based on the performance graph.
[0051] In one example, if Figure 2 As shown, the step of obtaining storage performance data according to the protocol message data analysis in step S2 specifically includes:
[0052] S21. Obtain the start time, end time, block size, and number of blocks corresponding to the read / write instruction in the protocol message data; the block size mentioned here is usually set by the HOST terminal 1, and is generally fixed to 512 Bytes; it is worth noting that the protocol message data usually contains a lot of information, and we obtain the relevant information of the read instruction and the write instruction that are directly related to the storage performance. Of course, in some examples, only the read instruction and its related information or only the write instruction and its related information can be obtained to evaluate and analyze only the read performance or the write performance respectively;
[0053] S22. Obtain read / write performance data according to the start time, end time, block size, and number of blocks corresponding to the read / write instruction.
[0054] In one example, the step of obtaining the read / write performance data according to the start time, end time, block size, and number of blocks corresponding to the read / write instruction in step S22 specifically includes:
[0055] The read / write performance data is obtained according to the following calculation formula:
[0056] Spend Time=End Time2-Start Time1;
[0057] Sector Count=Block Count×Block Size;
[0058] Performance=Sector Count / Spend Time;
[0059] In the formula, Spend Time indicates the time taken to transmit the specified data in the read / write instruction, End Time2 indicates the end time corresponding to the read / write instruction, Start Time1 indicates the start time corresponding to the read / write instruction, Block count indicates the number of blocks corresponding to the read / write instruction, Block size indicates the block size set by the HOST end, Sector Count indicates the number of bytes of transmitted data corresponding to the read / write instruction, that is, the number of bytes transmitted in a single network packet, and Performance indicates the read / write performance data. It can be seen that since the collected analysis is of each instruction in the protocol message data, the fine-grained performance analysis requirements at the instruction level can be met.
[0060] In an example, step S3 may include:
[0061] S3a, draw a performance graph with the horizontal axis representing the time corresponding to the transmission of each read / write instruction and the vertical axis representing the read / write performance data corresponding to each read / write instruction. The time corresponding to each read / write instruction here is obtained from the start time corresponding to each read / write instruction in the protocol data.
[0062] In another example, step S3 may include:
[0063] S3b, draw a performance graph in which the horizontal axis represents different numbers of bytes of the transmitted data, and the vertical axis represents the read / write performance data of the read / write instructions corresponding to the different numbers of bytes of the transmitted data.
[0064] like Figure 7 As shown, the present invention also proposes a storage performance test and analysis system, which includes:
[0065] The acquisition module 3 is used to obtain the protocol message data transmitted between the HOST terminal 1 and the solid-state storage device 2; the acquisition module 3 may include a protocol analyzer or other packet capture tools that support specified protocol analysis.
[0066] Analysis and processing module 4, used to obtain storage performance data according to protocol message data analysis;
[0067] The drawing module 5 is used to draw a performance graph according to the storage performance data.
[0068] Next, we will combine Figures 3 to 7 , taking the solid-state storage device 2 as eMMC21 as an example, the working principle of the present invention is further explained:
[0069] like Figure 6 As shown, there are usually four major signals transmitted between the HOST terminal 1 and the eMMC21, namely, CLK, CMD, DAT0-7, and Data Strobe. Among them, the CLK signal is used to output the clock signal from the Host terminal 1 to synchronize data transmission and drive the operation of the device. The CMD signal is mainly used for the Host terminal 1 to send instructions to the eMMC21 and for the eMMC21 to send the corresponding response to the Host terminal 1. The DAT0-7 signal is mainly used for data transmission between the Host terminal 1 and the eMMC21. The Data Strobe clock signal is sent from the eMMC21 to the Host, and has the same frequency as the CLK signal, and is used for synchronization of data reception by the Host terminal 1. The communication between the Host terminal 1 and the eMMC21 is initiated by the Host terminal with an instruction. After completing the task specified by the instruction, the eMMC21 returns a response.
[0070] The storage performance test and analysis method of this embodiment includes the following steps:
[0071] During the use of eMMC21, the protocol message data transmitted between the HOST terminal 1 and the eMMC21 is obtained through the protocol analyzer 3; the obtained protocol message data is stored in the LOG file. In this embodiment, the obtained LOG file (only part of the data is intercepted as an example) is as follows: Figure 3 As shown, in the protocol message data, the instructions for reading data are CMD17 (starting from the specified address, read a block of data (Block)), CMD18 (starting from the specified address, read multiple blocks of data (Multiple Block)); the commands for writing data are CMD24 (write a block of data (Block)), CMD25 (write multiple (MultipleBlock) data).
[0072] The start time, end time, block size and number of blocks corresponding to each write instruction (CMD24, CMD25) in the protocol message data are obtained. In this embodiment, the block size is set to 512Bytes by the HOST terminal 1; of course, in other examples, the start time, end time, block size and number of blocks corresponding to each read instruction (CMD17, CMD18) can also be obtained. In some other examples, the relevant data of the required specified read instruction or specified write instruction can also be obtained, which is not limited here;
[0073] The write performance data is obtained based on the start time, end time, block size and number of blocks corresponding to each write instruction. Specifically:
[0074] The write performance data is obtained based on the start time, end time, block size, and number of blocks corresponding to the write instruction:
[0075] Spend Time=End Time2-Start Time1;
[0076] Sector Count=Block Count×Block Size;
[0077] Performance=Sector Count / Spend Time;
[0078] At this time, Spend Time indicates the time consumed in transmitting the specified data in the write instruction, End Time2 indicates the end time corresponding to the write instruction, Start Time1 indicates the start time corresponding to the write instruction, Block count indicates the number of blocks corresponding to the write instruction, Block size indicates the block size set by the HOST end, Sector Count indicates the number of bytes of transmitted data corresponding to the write instruction, and Performance indicates write performance data.
[0079] According to the above formula, by analyzing and calculating all write instruction data in sequence, the write performance data of all write instructions can be obtained.
[0080] In order to locate the problem more conveniently, the above data can be displayed in combination with charts, specifically:
[0081] like Figure 4 As shown, a performance graph is drawn in which the horizontal axis is the time corresponding to the transmission of each write instruction and the vertical axis is the write performance data corresponding to each write instruction.
[0082] In theory, the more bytes of data transmitted (Sector Count), the higher the storage performance. Figure 5 As shown, a performance graph can also be drawn with the horizontal axis being different numbers of transmitted data bytes (Sector Count) and the vertical axis being the write performance data of the write instructions corresponding to each different number of transmitted data bytes, so as to check through the performance graph whether there is any abnormality in the write performance under different transmitted bytes.
[0083] When a performance anomaly is discovered, the above two figures can be combined to easily locate the corresponding time point and instruction, and conduct further data analysis.
[0084] Of course, in other embodiments, the above-mentioned relevant data of the read instructions (CMD17, CMD18) in the protocol message data can also be obtained at the same time, and the relevant performance graph can be drawn in combination with the obtained read performance data, and combined with the performance graph of the write instruction to perform abnormal data diagnosis.
[0085] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Non-volatile memory may include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0086] It should be understood that, although the steps in each flowchart are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear description in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in each flowchart may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0087] The technical features of the above-described embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0088] The above-mentioned embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
Claims
1. A storage performance test and analysis method, It is characterized in that include: Obtain the protocol message data transmitted between the HOST end and the solid-state storage device; Obtaining storage performance data according to the protocol message data analysis; The step of obtaining storage performance data according to the protocol message data analysis specifically includes: Get the start time, end time, block size and number of blocks corresponding to the read / write instruction in the protocol message data; Obtaining read / write performance data according to the start time, end time, block size, and number of blocks corresponding to the read / write instruction; The step of obtaining the read / write performance data according to the start time, end time, number of blocks and block size corresponding to the read / write instruction specifically includes: The read / write performance data is obtained according to the following calculation formula: Spend Time=End Time2-Start Time1; Sector Count=Block Count×Block Size; Performance=Sector Count / Spend Time; In the formula, Spend Time represents the time consumed for transmitting the specified data in the read / write instruction, End Time2 represents the end time corresponding to the read / write instruction, Start Time1 represents the start time corresponding to the read / write instruction, Blockcount represents the number of blocks corresponding to the read / write instruction, Block size represents the block size set by the HOST end, Sector Count represents the number of bytes of transmission data corresponding to the read / write instruction, and Performance represents the read / write performance data.
2. The storage performance test and analysis method according to claim 1, It is characterized in that Also includes: A performance graph is drawn based on the storage performance data.
3. The storage performance test and analysis method according to claim 2, It is characterized in that Also includes: A performance graph is drawn in which the horizontal axis is the time corresponding to the transmission of each of the read / write instructions, and the vertical axis is the read / write performance data corresponding to each of the read / write instructions.
4. The storage performance test and analysis method according to claim 3, It is characterized in that The time corresponding to the read / write instruction is obtained from the start time corresponding to each of the read / write instructions.
5. The storage performance test and analysis method according to claim 2, It is characterized in that Also includes: A performance graph is drawn with the horizontal axis representing different numbers of bytes of the transmitted data and the vertical axis representing the read / write performance data of the read / write instructions corresponding to the different numbers of bytes of the transmitted data.
6. The storage performance test and analysis method according to claim 1, It is characterized in that The block size includes 512Bytes.
7. The storage performance test and analysis method according to claim 1, Features: The solid-state storage device includes any one of SD, TF, eMMC, and NM.
8. A storage performance test and analysis system, It is characterized in that include: The acquisition module is used to obtain the protocol message data transmitted between the HOST end and the solid-state storage device; An analysis and processing module, used to obtain storage performance data according to the analysis of the protocol message data; The obtaining of storage performance data according to the analysis of the protocol message data comprises: obtaining the start time, end time, block size and number of blocks corresponding to the read / write instruction in the protocol message data; obtaining the read / write performance data according to the start time, end time, block size and number of blocks corresponding to the read / write instruction; The method of obtaining the read / write performance data according to the start time, end time, number of blocks and sector size corresponding to the read / write instruction includes: obtaining the read / write performance data according to the following calculation formula: Spend Time = EndTime2-Start Time1; Sector Count = Block Count×Block Size; Performance = SectorCount / Spend Time; wherein Spend Time represents the time consumed for transmitting the specified data in the read / write instruction, EndTime2 represents the end time corresponding to the read / write instruction, Start Time1 represents the start time corresponding to the read / write instruction, Block count represents the number of blocks corresponding to the read / write instruction, Block size represents the block size set by the HOST end, Sector Count represents the number of bytes of transmitted data corresponding to the read / write instruction, and Performance represents the read / write performance data.
9. The storage performance test and analysis system according to claim 8, Features: The acquisition module includes a protocol analyzer or a packet capture tool.
10. The storage performance testing and analysis system according to claim 8, It is characterized in that Also includes: A drawing module is used to draw a performance graph according to the storage performance data.
