Hard disk performance testing method, device, equipment and storage medium
Through parallel testing and scheduling rule optimization, the problem of long hard disk performance testing is solved, and fast and efficient hard disk performance testing is achieved.
Patent Information
- Application Number
- CN202210713589.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-06-22
- Publication Date
- 2024-11-19
- Estimated Expiration
- 2042-06-22
AI Technical Summary
The existing hard disk performance testing methods require a lot of time and are inefficient in work and cannot meet the needs of rapid testing.
Using parallel testing methods, multiple hard disks to be tested are tested in parallel through preset testing tasks, monitoring the test progress of each hard disk, and determining scheduling rules based on the type, progress and server resource status of sub-test tasks, and optimizing the test tasks of hard disks Scheduling to improve testing efficiency.
Parallel testing significantly shortens hard disk testing time, improves work efficiency, and meets the needs of rapid testing.
Smart Images

Figure CN115202944B_ABST
Abstract
Description
Background Art
[0002] As the current scale of enterprise data continues to grow, business systems have increasingly higher requirements for high-speed data processing capabilities. Hard disks can achieve high-speed data transmission, so servers equipped with hard disks can meet the needs of high-speed processing of large amounts of data.
[0003] Before a hard disk leaves the factory, it is necessary to perform a performance test on the hard disk. Generally, a serial test is performed on the hard disk. A test server is used to perform serial tests on multiple hard disks. The test takes a lot of time and has low work efficiency, which cannot meet people's needs for test speed.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0005] The present disclosure provides a hard disk performance testing method, device, equipment and storage medium, which at least to a certain extent overcome the problem that hard disk testing takes a lot of time, has low work efficiency and cannot meet people's needs for testing speed.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0007] According to one aspect of the present disclosure, a hard disk performance testing method is provided, the method comprising:
[0008] Performing parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel;
[0009] Monitoring the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test task;
[0010] When executing a sub-test task, determining a scheduling rule for multiple hard disks to be tested to execute the sub-test task according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server;
[0011] Execute the one sub-test task on the multiple hard disks to be tested according to the scheduling rule;
[0012] After all subtest tasks are completed, the performance test results are obtained.
[0013] In one embodiment of the present disclosure, the resources of the test server include a CPU core of the test server, a numa node of the test server, and a PCIe channel of the test server;
[0014] Before performing parallel testing on a plurality of hard disks to be tested according to a preset test task, the method further includes:
[0015] Divide the plurality of hard disks to be tested into N groups, wherein one group of hard disks to be tested corresponds to one numa node, and one numa node corresponds to multiple PCIe channels and multiple CPU cores;
[0016] A group of hard disks to be tested share a numa node and multiple CPU cores corresponding to the numa node;
[0017] The group of hard disks to be tested are mounted in parallel on the test server through the multiple PCIe channels corresponding to the one numa node;
[0018] Each of the hard disks to be tested in each group of the hard disks to be tested is bound to the numa node, the CPU core and the PCIe channel to execute a sub-test task of the hard disk to be tested.
[0019] In one embodiment of the present disclosure, when executing a sub-test task, determining a scheduling rule for multiple hard disks to be tested to execute the sub-test task according to the type of the sub-test task, the test progress of the sub-test task, and the resource occupancy of the test server includes:
[0020] Query the resource usage of the test server;
[0021] Determine whether the resources required by the current sub-test task are greater than the idle resources of the test server;
[0022] If it is greater than, then select some of the hard disks to be tested to execute the current sub-test task in parallel;
[0023] When some of the hard disks to be tested have completed executing the current sub-test task, some of the hard disks to be tested are unbound from the corresponding resources, and the unbound resources are bound to the hard disks to be tested that have not performed the current sub-test task until all of the hard disks to be tested have completed the current sub-test task.
[0024] In one embodiment of the present disclosure, the method further includes:
[0025] If the resources required by the current sub-test task are less than or equal to the idle resources of the test server, all the hard disks to be tested execute the current sub-test task in parallel.
[0026] In one embodiment of the present disclosure, the method further includes:
[0027] Querying the test progress of the hard disk to be tested in a group in executing the current sub-test task;
[0028] When all the hard disks to be tested in a group have completed the current sub-test task, the next sub-test task is executed until all sub-test tasks are completed.
[0029] In one embodiment of the present disclosure, after all sub-test tasks are completed and the performance test results are obtained, the method includes:
[0030] Comparing the performance test result of the hard disk to be tested with a preset test threshold, determining the performance test result of the hard disk to be tested according to the comparison result, and generating test log information;
[0031] A test report is generated according to the test log information and hard disk information, wherein the hard disk information includes the number, manufacturer name, hard disk model, and read / write speed of the hard disk to be tested.
[0032] In one embodiment of the present disclosure, the sub-test tasks include a data clearing task, a random read and write initialization task, a random read and write performance test task, a random read and write delay performance test task, a sequential read and write initialization task, and a sequential read and write performance test task.
[0033] In one embodiment of the present disclosure, before performing parallel testing on a plurality of hard disks to be tested according to a preset test task, the method further includes:
[0034] The test environment is deployed according to the image, and the hard disk to be tested executes the test task in the test environment.
[0035] In one embodiment of the present disclosure, the deploying the test environment according to the image includes:
[0036] Deploy an operating system on the test server for the hard disk to be tested to perform the test task;
[0037] Install the Docker engine on the operating system;
[0038] Installing a Docker image of an application on the test server, where the Docker image of the application is obtained through the Docker engine;
[0039] The Docker image of the application is used to start a Docker container for executing the test task, forming a test environment for an application cluster based on a Docker container.
[0040] In one embodiment of the present disclosure, the Docker image of the application includes a testing tool, monitoring software and a dependency package. The testing tool is used to execute the testing task on the hard disk to be tested, the monitoring software is used to monitor the testing progress of multiple hard disks to be tested and the occupancy information of the resource information, and the dependency package provides guarantee for the compilation and operation of the testing tool and the monitoring software.
[0041] In another embodiment of the present disclosure, a hard disk performance testing device is provided, the device comprising:
[0042] A performance test module, used for performing parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel;
[0043] A monitoring module, used to monitor the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test task;
[0044] A scheduling rule establishment module is used to determine the scheduling rule for multiple hard disks to be tested to execute a sub-test task according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server when executing the sub-test task;
[0045] The performance testing module is further configured to execute the one sub-test task on the multiple hard disks to be tested according to the scheduling rule;
[0046] The test result generation module is used to obtain the performance test results after all sub-test tasks are completed.
[0047] According to another aspect of the present disclosure, there is provided an electronic device, including:
[0048] Processor; and
[0049] A memory, configured to store executable instructions of the processor;
[0050] Wherein, the processor is configured to execute the above-mentioned private network service policy control method by executing the executable instructions.
[0051] According to another aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the above-mentioned private network service policy control method is implemented.
[0052] According to another aspect of the present disclosure, a computer program product is provided, the computer program product comprising a computer program or computer instructions, the computer program or the computer instructions being loaded and executed by a processor so that a computer implements any of the hard disk performance testing methods described above.
[0053] The embodiments of the present disclosure provide a hard disk performance test method, device, equipment and storage medium. The test server performs parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks; monitors the test progress of each hard disk to be tested, and the test progress is the progress of the sub-test task; when executing a sub-test task, determines the scheduling rules for multiple hard disks to be tested to execute a sub-test task according to the type of a sub-test task, the test progress of a sub-test task and the resource occupancy of the test server; executes a sub-test task on multiple hard disks to be tested according to the scheduling rules; and obtains performance test results after all sub-test tasks are completed. The scheduling rules are used to implement parallel testing of multiple hard disks to be tested, which shortens the test time of the hard disks and improves work efficiency, thereby meeting people's needs for test speed.
[0054] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0056] Figure 1 A schematic diagram showing a hard disk performance test system architecture in an embodiment of the present disclosure;
[0057] Figure 2 A flow chart of a hard disk performance testing method according to an embodiment of the present disclosure is shown;
[0058] Figure 3 A flowchart of scheduling rules in a hard disk performance testing method in an embodiment of the present disclosure is shown;
[0059] Figure 4 A flowchart showing deployment of a test environment according to an image in an embodiment of the present disclosure is shown;
[0060] Figure 5 A resource architecture diagram of a test server in an embodiment of the present disclosure is shown;
[0061] Figure 6A schematic diagram of a hard disk performance testing device according to an embodiment of the present disclosure is shown;
[0062] Figure 7 A structural block diagram of an electronic device according to an embodiment of the present disclosure is shown; DETAILED DESCRIPTION
[0063] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that the disclosure will be more comprehensive and complete and to fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0064] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0065] The specific implementation of the embodiment of the present disclosure is described in detail below with reference to the accompanying drawings.
[0066] Figure 1 A schematic diagram of an exemplary application system architecture to which the hard disk performance testing method in the embodiment of the present disclosure can be applied is shown.
[0067] like Figure 1 As shown, the system architecture includes a test server 101, multiple hard disks to be tested 102 and a connecting device 103. The test server 101 can be a desktop computer, a laptop computer or other types of devices with processing capabilities. The multiple hard disks to be tested 102 are mounted on the test server 101 in parallel through the connecting device 103. The connecting device 103 is used to connect the multiple hard disks to be tested 102 to the test server 101. The connecting device 103 can be a switch, an interface cable or other types of devices that can connect the hard disks to be tested 102 to the test server 101.
[0068] Those skilled in the art will know that Figure 1 The number of the test servers 101, the hard disks to be tested 102 and the connecting devices 103 is only for illustration, and any number of the test servers 101, the hard disks to be tested 102 and the connecting devices 103 may be provided according to actual needs. The embodiments of the present disclosure are not limited to this.
[0069] Before the hard disk 102 to be tested is subjected to a performance test, a containerized environment or a virtual machine for testing is deployed on the test server 101, which simplifies the deployment of the test platform and has high deployment efficiency. Under the above system architecture, a hard disk performance test is provided in the embodiment of the present disclosure, wherein the test server 101 performs parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks; the test server 101 monitors the test progress of each hard disk to be tested, and the test progress is the progress of the sub-test task; when executing a sub-test task, the test server 101 determines the scheduling rules for multiple hard disks to be tested to execute a sub-test task according to the type of a sub-test task, the test progress of a sub-test task, and the resource occupancy of the test server; the test server 101 also executes a sub-test task on multiple hard disks to be tested according to the scheduling rules; after all sub-test tasks are completed, the performance test results are obtained. This method can be applied in the scenario of hard disk testing. The tested hard disk can be a mechanical hard disk, SATA SSD (solid state drive), NVMe hard disk (non-volatile memory host controller interface specification hard disk), SSD U.2 hard disk (U.2 interface solid state drive) or NVMe SSDAIC card, etc.
[0070] NVMe hard drives have the advantages of low latency, low energy consumption, high performance, and scalability. NVMe hard drives are very popular among people. Before NVMe hard drives leave the factory, they need to be tested for performance. Since the performance of NVMe hard drives is more than 100 times that of traditional hard drives, the CPU (Central Processing Unit) resources and bandwidth resources are highly dedicated. In order to avoid mutual influence during testing, serial testing is generally used to measure the maximum performance. A test server is used to perform serial testing on multiple hard drives. Serial testing takes a lot of time and has low work efficiency, which cannot meet people's needs for test speed.
[0071] This application fully utilizes the CPU resources and bandwidth resources of the test server 101 through scheduling rules to achieve parallel testing of multiple NVMe hard drives, shorten the testing time of NVMe hard drives, and improve work efficiency, thereby meeting people's needs for testing speed.
[0072] In some embodiments, the hard disk performance testing method provided in the embodiments of the present disclosure can be Figure 1 The test server 101 is shown as being executed.
[0073] Figure 2 A flow chart of a hard disk performance testing method according to an embodiment of the present disclosure is shown as follows: Figure 2 As shown, the hard disk performance testing method provided in the embodiment of the present disclosure includes the following steps:
[0074] Step S202, performing parallel testing on the multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel.
[0075] Multiple hard disks to be tested are mounted on the test server in parallel, and the test server performs performance tests on the multiple hard disks to be tested at the same time. The test server is preset with test tasks for testing the hard disks to be tested. The test tasks are used to test the read and write speed, delay time and other performance of the hard disks to be tested. The test tasks are composed of multiple sub-test tasks, and the sub-test tasks can be clearing data, random read and write initialization, random read and write performance test, random read and write delay performance test, sequential read and write initialization or sequential read and write performance test.
[0076] Step S204, monitoring the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test tasks.
[0077] The test server may monitor the test progress of the sub-test tasks. The test progress may be a ratio, a difference, or other forms that can reflect the test progress.
[0078] Step S206, when executing a sub-test task, determining a scheduling rule for executing a sub-test task by multiple hard disks to be tested according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server.
[0079] The resources of the test server include CPU, CPU core, numa (non-uniform memory access) node and PCIe (Peripheral Component Interconnect Express) channel. When the hard disk to be tested is subjected to performance test, the resources of the test server are required to test the hard disk to be tested.
[0080] The scheduling rule is determined by the sub-test task, the test progress corresponding to the sub-test task and the resource usage of the test server, and is used to schedule the hard disk to be tested to execute the test task.
[0081] Step S208: executing a sub-test task on the multiple hard disks to be tested according to the scheduling rule.
[0082] In step S208, the scheduling rules are used to schedule the hard disks to be tested that have not performed sub-test tasks to be bound to idle resources to execute the sub-test tasks. When all the hard disks to be tested have completed the sub-test tasks, the scheduling rules are also used to schedule all the hard disks to be tested to perform the next sub-test task until all the sub-test tasks are completed.
[0083] Step S210, after all sub-test tasks are completed, the performance test results are obtained.
[0084] The performance test result can be the performance result of the hard disk performance test to be tested, or it can be a judgment result (qualified or unqualified). The judgment result is to compare the performance result obtained by the test with the preset performance result. If the performance result is the same as or better than the preset performance result, it is qualified, otherwise it is unqualified.
[0085] exist Figure 2 In the illustrated embodiment of the present application, the present application implements parallel testing of multiple hard disks to be tested through scheduling rules, thereby shortening the testing time of the hard disks to be tested, improving work efficiency, and thus meeting people's needs for testing speed.
[0086] In some embodiments, the resources of the test server include a CPU core of the test server, a numa node of the test server, and a PCIe channel of the test server;
[0087] Before performing parallel testing on the multiple hard disks to be tested according to the preset test tasks, the method further includes:
[0088] Divide multiple hard disks to be tested into N groups, where one group of hard disks to be tested corresponds to one numa node, and one numa node corresponds to multiple PCIe channels and multiple CPU cores;
[0089] A group of hard disks to be tested share a numa node and multiple CPU cores corresponding to the numa node;
[0090] A group of hard disks to be tested are mounted in parallel on the test server through multiple PCIe channels corresponding to a numa node;
[0091] Each hard disk to be tested in each group of hard disks to be tested is bound to a numa node, a CPU core, and a PCIe channel to execute a subtest task of the hard disk to be tested.
[0092] Exemplarily, the test server performs parallel testing on N groups of hard disks to be tested simultaneously. Each group of hard disks to be tested corresponds to a numa node, multiple PCIe channels and multiple CPU cores. The hard disks to be tested are mounted on the test server in parallel through a PCIE switch, and are connected to the test server by binding with the PCIe channels. Both the numa node and the CPU core are used to read and write the hard disks to be tested and execute test tasks.
[0093] Figure 3 A flowchart of scheduling rules in a hard disk performance testing method according to an embodiment of the present disclosure is shown. Figure 3 As shown, in some embodiments, when executing a sub-test task, a scheduling rule for executing a sub-test task by multiple hard disks to be tested is determined according to the type of the sub-test task, the test progress of the sub-test task, and the resource occupancy of the test server, including:
[0094] Step S301, querying the resource usage of the test server;
[0095] Step S302, determining whether the resources required by the current sub-test task are greater than the idle resources of the test server; if so, executing S303;
[0096] Step S303: if it is greater than, select some hard disks to be tested to execute the current sub-test task in parallel;
[0097] Step S304, querying the test progress of the hard disk to be tested in a group in executing the current sub-test task;
[0098] Step S305, determining whether the current sub-test task has been completed, if not, executing step S303; if completed, executing step S306;
[0099] Step S306, determining whether all sub-test tasks have been completed, if completed, the test is completed, if not completed, executing step S307;
[0100] Step S307, executing the next sub-test task.
[0101] When all the hard disks to be tested in a group have completed the current sub-test task, the next sub-test task is executed until all sub-test tasks are completed.
[0102] When some of the hard disks to be tested have completed the current subtest task, they are unbound from the corresponding resources, and the unbound resources are bound to the hard disks to be tested that have not performed the current subtest task until all the hard disks to be tested have completed the current subtest task.
[0103] Exemplarily, four hard disks to be tested are mounted in parallel on a numa node of the test server, and each numa node corresponds to eight PCIe channels and 16 CPU cores. When executing the sub-test task of the random read and write performance test, each hard disk to be tested needs to occupy four PCIe channels and eight CPU cores. Testing four hard disks to be tested simultaneously needs to occupy 16 PCIe channels and 32 CPU cores. 16 PCIe channels are greater than eight PCIe channels, and 32 CPU cores are greater than 16 CPU cores. The resources required for the current sub-test task are greater than the idle resources of the test server. Some hard disks to be tested are selected to execute the current sub-test task in parallel. Since the test server's resources of eight PCIe channels and 16 CPU cores can satisfy the simultaneous testing of two hard disks to be tested, the two hard disks to be tested are tested first. After the testing of the two hard disks to be tested is completed, the resources are unbound, and then the two hard disks to be tested that have not performed the current sub-test task are bound, thereby completing the current sub-test task.
[0104] like Figure 3 As shown, in some embodiments, when executing a sub-test task, determining a scheduling rule for executing a sub-test task by multiple hard disks to be tested according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server also includes:
[0105] Step S308, if the resources required by the current sub-test task are less than or equal to the idle resources of the test server, all the hard disks to be tested execute the current sub-test task in parallel;
[0106] Step S309, querying the test progress of the hard disk to be tested in a group in executing the current sub-test task;
[0107] Step S310, determining whether the current sub-test task has been completed, if it has been completed, executing step S306, if it has not been completed, executing step S308.
[0108] Exemplarily, four hard disks to be tested are mounted in parallel on a numa node of the test server, and each numa node corresponds to eight PCIe channels and 16 CPU cores. When executing the sub-test task of clearing data, since clearing data requires fewer resources of the test server and does not need to occupy the CPU core, numa node and PCIe channel exclusively, the resources required for the current sub-test task are less than the idle resources of the test server. The four hard disks to be tested perform the test of the current sub-test task in parallel. After the test of the current sub-test task is completed, step S306 is executed. How to execute step S306 has been described above and will not be repeated here.
[0109] In some embodiments, the sub-test tasks include a clear data task, a random read and write initialization task, a random read and write performance test task, a random read and write delay performance test task, a sequential read and write initialization task, and a sequential read and write performance test task that are executed sequentially.
[0110] Exemplarily, the hard disk to be tested sequentially performs data clearing, random read and write initialization, random read and write performance test, random read and write delay performance test, sequential read and write initialization and sequential read and write performance test. When the above sub-test tasks are executed sequentially, the test is completed.
[0111] In some embodiments, after all sub-test tasks are completed and performance test results are obtained, the method includes:
[0112] Compare the performance test result of the hard disk to be tested with the preset test threshold, determine the performance test result of the hard disk to be tested according to the comparison result, and generate test log information;
[0113] A test report is generated based on the test log information and hard disk information, where the hard disk information includes the number of hard disks to be tested, the manufacturer name, the hard disk model, and the read / write speed.
[0114] It should be noted that the test report records the basic information of the hard disk to be tested, such as the manufacturer name, hard disk model and read and write speeds, etc. The test report also records the performance of the hard disk to be tested and whether the hard disk to be tested is qualified. The performance of the hard disk to be tested includes the read and write speed, delay performance and capacity of the hard disk, etc.
[0115] In some embodiments, before performing parallel testing on multiple hard disks to be tested according to a preset test task, the method further includes:
[0116] The test environment is deployed according to the image, and the hard disk to be tested performs the test task in the test environment.
[0117] It should be noted that the test environment refers to the general term for the computer hardware, software, network equipment, and historical data required to complete the testing of the hardware to be tested, which can ensure the performance testing of the hardware to be tested.
[0118] Figure 4 A flowchart of deploying a test environment according to an image in an embodiment of the present disclosure is shown. Figure 4 As shown, deploying the test environment based on the image includes the following steps:
[0119] Step S402: deploying an operating system on the test server for the hard disk to be tested to perform the test task.
[0120] For the operating system, the tester realizes human-computer interaction through the operating system, which makes it convenient for the tester to start the test task and perform parallel testing on the hard disk to be tested.
[0121] Step S404: Install the Docker engine on the operating system.
[0122] Docker Engine is an open source application container engine that allows testers to package application tools and dependency packages into a portable container and then send it to any Linux or Windows machine. It can also achieve virtualization, thereby simplifying the debugging of the test platform.
[0123] Step S406: Install the Docker image of the application on the test server, where the Docker image of the application is obtained through the Docker engine.
[0124] In some embodiments, the Docker image of the application includes a testing tool, monitoring software and a dependency package. The testing tool is used to perform testing tasks on the hard disk to be tested. The monitoring software is used to monitor the testing progress and resource occupancy information of multiple hard disks to be tested. The dependency package provides guarantee for the compilation and operation of the testing tool and the monitoring software.
[0125] Step S408: Start a Docker container for executing the test task using the Docker image of the application program, thereby forming a test environment for the application program cluster based on the Docker container.
[0126] In the related art, before testing the hard disk to be tested, the test platform must be deployed first. There is a problem of deploying a heterogeneous test environment in the deployment of the test platform. For the heterogeneous test platform, it is necessary to install test tools, monitoring software, dependency packages, etc. These software have many versions and complex dependency packages on the heterogeneous test platform, which are prone to configuration errors. It needs to rely on experienced personnel to complete, which leads to a large workload for test result management. This application deploys the test environment according to the image. The Docker (application container engine) image includes test tools, monitoring software, and dependency packages, which simplifies the test environment deployment, improves deployment efficiency, and ensures the validity of the test data.
[0127] In some embodiments, a test environment is deployed according to a mirror on a test server, and 16 NVMe hard drives are tested in parallel. The 16 NVMe hard drives are mounted in parallel on the test server through a PCIe switch. The model of the test server is Kunpeng 920 (48 Cores, 2.6 GHz). The test server has two CPUs, each CPU has two numa nodes, each numa node has 8 PCIe channels, and 4 NVME disks are mounted on each numa node. A total of 16 NVMe hard drives can be mounted.
[0128] Figure 5 The resource architecture diagram of the test server in the embodiment of the present disclosure is shown as follows: Figure 5As shown, the test server has 2 CUPs (i.e., CUP0 and CUP1), and the test server has a total of 4 numa nodes (i.e., numa0, numa1, numa2, and numa3, among which numa0 and numa1 belong to CUP0, and numa2 and numa3 belong to CUP1); each CPU has 32 CPU cores, that is, the test server has a total of 64 CPU cores (core0-core63), among which core0-core15 belong to numa0, core16-core31 belong to numa1, core32-core47 belong to numa2, and core48-core63 belong to numa3; the test server has a total of 32 PCIe channels (PCIe0-PCIe31), and the PCIe channels belong to numa nodes, among which PCIe0-PCIe7 belong to numa0, PCIe8-PCIe15 belong to numa1, PCIe16-PCIe23 belong to numa2, and PCIe24-PCIe31 belong to numa3.
[0129] The 16 NVMe hard drives to be tested are divided into 4 groups, each group has 4 NVMe hard drives, 4 NVMe hard drives correspond to one numa node, and one numa node corresponds to 8 PCIe channels and 16 CPU cores. Because each numa node is mounted with 4 NVMe hard drives, the NVMe hard drives share the PCIe channels. Each NVMe hard drive occupies 4 PCIe channels at its maximum performance, so it is necessary to ensure that no more than 2 NVMe hard drives are tested for random read and write performance or sequential read and write performance at the same time.
[0130] The following takes one group of NVMe hard disks for parallel testing as an example for explanation. The other three numa nodes simultaneously perform NVMe hard disk parallel testing. Each numa node does not interfere with each other when testing the NVMe hard disk performance.
[0131] The NVMe hard drive performs the following sub-test tasks in sequence: clearing data, random read and write initialization, random read and write performance test, random read and write delay performance test, sequential read and write initialization, and sequential read and write performance test.
[0132] (1) Clear data
[0133] Clear the data in the NVMe hard disk to be tested. Clearing the data can keep the starting point of the NVMe hard disk to be tested consistent. The following uses the common open source tool nvme-cli command. The device variable represents the NVMe hard disk to be tested. The NVMe hard disk to be tested is formatted. The nvme format$device command can be used to format the NVMe hard disk to be tested. The resources of the test server can meet the resources required for clearing data on four NVMe hard disks to be tested at the same time. The data on the four NVMe hard disks to be tested are cleared at the same time.
[0134] (2) Random read and write initialization
[0135] The resources of the test server can meet the resources required for random read and write initialization of 4 NVMe hard disks to be tested at the same time. Random read and write initialization is performed on the 4 NVMe hard disks to be tested at the same time. The formatted NVMe hard disk to be tested is first written twice in sequence to fill the memory of the NVMe hard disk to be tested with data, and then 4K random write is used for 4 hours to make the NVMe hard disk to be tested enter a random steady state.
[0136] It should be noted that random read and write initialization does not need to monopolize the resources of the test server.
[0137] (3) Random read and write performance test
[0138] During the random read and write performance test, one NVMe hard disk to be tested needs to be bound to 8 CPU cores in one numa node and occupy 4 PCIe channels. One numa node corresponds to 8 PCIe channels and 16 CPU cores. Since the test of four NVMe hard disks to be tested requires 32 CPU cores, the number of CPU cores required is greater than the number of CPU cores corresponding to one numa node of the server to be tested. Therefore, it is impossible to perform random read and write performance tests on four NVMe hard disks to be tested at the same time. The 8 PCIe channels and 16 CPU cores corresponding to one numa node can meet the parallel testing of two NVMe hard disks to be tested. In this case, the two NVMe hard disks to be tested are tested in parallel first. After the two NVMe hard disks to be tested complete the random read and write performance test, the two NVMe hard disks to be tested that have not undergone the random read and write performance test are tested for random read and write performance.
[0139] The test tool required for random read and write performance testing is fio (command line tool). Use fio to test the IOPS (number of read and write operations per second) of the NVMe hard disk to be tested.
[0140] During the fio test, in order to improve performance, it is necessary to bind numa nodes (parameter numa_cpu_nodes) and CPU cores (binding core parameters taskset-c 0, 1, 2, 4-7). Generally, one task (numjobs=x) corresponds to one CPU core.
[0141] The test procedure is as follows:
[0142] #4k Random Read
[0143] Script example:
[0144] taskset-c$core fio...--numjobs=8--iodepth=64--numa_cpu_nodes=$numa--filename=$device--rw=randread--bs=4k--output=4K_randR.log
[0145] #4k Random Write
[0146] taskset-c$core fio...--numjobs=8--iodepth=64--numa_cpu_nodes=$numa--filename=$device--rw=randwrite--bs=4k--output=4K_randR.log
[0147] (4) Random read and write latency performance test
[0148] When performing random read and write latency performance tests, one NVMe hard drive to be tested needs to be bound to one CPU core and randomly occupy a PCIe channel. The resources of the test server can meet the resources required for the random read and write latency performance tests of four NVMe hard drives to be tested at the same time. The four NVMe hard drives to be tested can perform random read and write latency performance tests at the same time.
[0149] The following first performs a 4K random read latency test, and then a 4K random write latency test, each for half an hour. The results reflect the optimal read and write latency that the NVMe hard drive to be tested can achieve.
[0150] #4k Random Read latency
[0151] taskset-c$core fio...--numjobs=1--iodepth=1--numa_cpu_nodes=$numa--filename=$device--rw=randread--bs=4k--output=4K_randR_latency.log
[0152] #4k Random Write latency
[0153] taskset-c$core fio...--numjobs=1--iodepth=1--numa_cpu_nodes=$numa--filename=$device--rw=randwrite--bs=4k--output=4K_randR_latency.log
[0154] (5) Sequential read and write initialization
[0155] During the sequential read and write initialization test, one NVMe hard disk to be tested only needs to randomly occupy the CPU core and PCIe channel. The resources of the test server can meet the resources required for the simultaneous sequential read and write initialization of four NVMe hard disks to be tested. The four NVMe hard disks to be tested perform sequential read and write initialization at the same time.
[0156] Based on the previous random read and write latency performance test, the NVMe hard disk to be tested is written twice in sequence to make the NVMe hard disk to be tested enter the sequential steady state to prepare for the subsequent read and write bandwidth.
[0157] (6) Sequential read and write performance test
[0158] During the sequential read and write performance test, one NVMe hard disk to be tested needs to occupy 4 PCIe channels and randomly occupy CPU cores. One numa node corresponds to 8 PCIe channels and 16 CPU cores. Since the test of four NVMe hard disks to be tested requires 16 PCIe channels, the number of PCIe channels required is greater than the number of PCIe channels corresponding to one numa node of the server to be tested. It is impossible to simultaneously perform sequential read and write performance tests on four NVMe hard disks to be tested. The 8 PCIe channels and 16 CPU cores corresponding to one numa node can meet the parallel testing of two NVMe hard disks to be tested. In this case, the two NVMe hard disks to be tested are tested in parallel first. After the sequential read and write performance test of these two NVMe hard disks to be tested is completed, the sequential read and write performance test is performed on the two NVMe hard disks to be tested that have not undergone the sequential read and write performance test.
[0159] The following is a 1M sequential read bandwidth test, followed by a sequential write bandwidth test, each for one hour. The results reflect the ability of the NVMe hard drive to handle sequential IO access.
[0160] #1MB Seq Read
[0161] fio...--numjobs=1--iodepth=128--numa_cpu_nodes=$numa--filename=$device--rw=read--bs=1m--output=1MB_seqR.log
[0162] #1MB Seq Write
[0163] fio...--numjobs=1--iodepth=128--numa_cpu_nodes=$numa--filename=$device--rw=write--bs=1m--output=1MB_seqR.log
[0164] After the test server completes the above sub-test tasks, it generates performance test results, compares the performance test results of the NVMe hard disk to be tested with the preset test threshold, determines the performance test results of the NVMe hard disk to be tested based on the comparison results, and generates test log information.
[0165] Based on the same inventive concept, the present disclosure also provides a hard disk performance test device, as described in the following embodiments. Since the principle of solving the problem in the device embodiment is similar to that in the above method embodiment, the implementation of the device embodiment can refer to the implementation of the above method embodiment, and the repeated parts will not be repeated.
[0166] Figure 6 A schematic diagram of a hard disk performance testing device according to an embodiment of the present disclosure is shown. Figure 6 As shown, the device includes a performance testing module 61, a monitoring module 62, a scheduling rule establishment module 63 and a test result generation module 64, wherein:
[0167] The performance test module 61 is used to perform parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel;
[0168] A monitoring module 62, used to monitor the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test task;
[0169] The scheduling rule establishing module 63 is used to determine the scheduling rule for executing a sub-test task by multiple hard disks to be tested according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server when executing a sub-test task;
[0170] The performance test module 61 is further used to execute a sub-test task on the multiple hard disks to be tested according to the scheduling rules;
[0171] The test result generating module 64 is used to obtain the performance test result after all sub-test tasks are completed.
[0172] In some embodiments of the present disclosure, the resources of the test server include a CPU core of the test server, a numa node of the test server, and a PCIe channel of the test server;
[0173] The performance test module 61 is used to perform parallel testing on multiple hard disks to be tested according to a preset test task.
[0174] Divide multiple hard disks to be tested into N groups, where one group of hard disks to be tested corresponds to one numa node, and one numa node corresponds to multiple PCIe channels and multiple CPU cores;
[0175] A group of hard disks to be tested share a numa node and multiple CPU cores corresponding to the numa node;
[0176] A group of hard disks to be tested are mounted in parallel on the test server through multiple PCIe channels corresponding to a numa node;
[0177] The performance testing module 61 also binds each hard disk to be tested in each group of hard disks to be tested with a numa node, a CPU core and a PCIe channel to execute a sub-test task of the hard disk to be tested.
[0178] In some embodiments of the present disclosure, the scheduling rule establishment module 63 is used to query the resource occupancy of the test server;
[0179] Determine whether the resources required by the current sub-test task are greater than the idle resources of the test server;
[0180] If it is greater, some hard disks to be tested will be selected to execute the current sub-test task in parallel;
[0181] When some of the hard disks to be tested have completed the current subtest task, they are unbound from the corresponding resources, and the unbound resources are bound to the hard disks to be tested that have not performed the current subtest task until all the hard disks to be tested have completed the current subtest task.
[0182] In some embodiments of the present disclosure, the scheduling rule establishing module 63 is further configured to cause all hard disks to be tested to execute the current sub-test task in parallel if the resources required by the current sub-test task are less than or equal to the idle resources of the test server.
[0183] In some embodiments of the present disclosure, the scheduling rule establishing module 63 is further used to query the test progress of the hard disk to be tested in a group executing the current sub-test task;
[0184] When all the hard disks to be tested in a group have completed the current sub-test task, the next sub-test task is executed until all sub-test tasks are completed.
[0185] In some embodiments of the present disclosure, the test result generating module 64 is used to compare the performance test result of the hard disk to be tested with a preset test threshold after all sub-test tasks are completed and the performance test result is obtained, determine the performance test result of the hard disk to be tested according to the comparison result, and generate test log information;
[0186] A test report is generated based on the test log information and hard disk information, where the hard disk information includes the number of hard disks to be tested, the manufacturer name, the hard disk model, and the read / write speed.
[0187] In some embodiments of the present disclosure, the sub-test tasks include a clear data task, a random read and write initialization task, a random read and write performance test task, a random read and write delay performance test task, a sequential read and write initialization task, and a sequential read and write performance test task.
[0188] In some embodiments of the present disclosure, the performance testing module 61 is used to deploy a test environment according to a mirror image before performing parallel testing on multiple hard disks to be tested according to a preset test task, and the hard disks to be tested execute the test task in the test environment.
[0189] In some embodiments of the present disclosure, the performance testing module 61 is used to deploy an operating system for the hard disk to be tested to perform a test task on a test server;
[0190] Install Docker engine on your operating system;
[0191] Install the application's Docker image on the test server. The application's Docker image is obtained through the Docker engine.
[0192] The Docker image of the application is used to start the Docker container for executing the test task, forming a test environment for the application cluster based on the Docker container.
[0193] In some embodiments of the present disclosure, the Docker image of the application includes a testing tool, monitoring software and a dependency package. The testing tool is used to perform testing tasks on the hard disk to be tested. The monitoring software is used to monitor the testing progress and resource occupancy information of multiple hard disks to be tested. The dependency package provides guarantee for the compilation and operation of the testing tool and the monitoring software.
[0194] Those skilled in the art will appreciate that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to herein as "circuits", "modules" or "systems".
[0195] Refer to the following Figure 7 An electronic device 700 according to this embodiment of the present disclosure is described. Figure 7 The electronic device 700 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0196] like Figure 7 As shown, the electronic device 700 is in the form of a general computing device. The components of the electronic device 700 may include but are not limited to: at least one processing unit 710, at least one storage unit 720, and a bus 730 connecting different system components (including the storage unit 720 and the processing unit 710).
[0197] The storage unit stores a program code, and the program code can be executed by the processing unit 710, so that the processing unit 710 executes the steps described in the above "Exemplary Method" section of this specification according to various exemplary embodiments of the present disclosure. For example, the processing unit 710 can execute the following steps of the above method embodiment: perform parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and multiple hard disks to be tested are mounted on the test server in parallel; monitor the test progress of each hard disk to be tested, and the test progress is the progress of the sub-test task; when executing a sub-test task, determine the scheduling rules for multiple hard disks to be tested to execute a sub-test task according to the type of a sub-test task, the test progress of a sub-test task, and the resource occupancy of the test server; execute a sub-test task on multiple hard disks to be tested according to the scheduling rules; after all sub-test tasks are completed, obtain performance test results.
[0198] The storage unit 720 may include a readable medium in the form of a volatile storage unit, such as a random access memory unit (RAM) 721 and / or a cache memory unit 722 , and may further include a read-only memory unit (ROM) 723 .
[0199] The storage unit 720 may also include a program / utility 724 having a set (at least one) of program modules 725, such program modules 725 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0200] Bus 730 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0201] The electronic device 700 may also communicate with one or more external devices 740 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 700, and / or communicate with any device that enables the electronic device 700 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 750. Furthermore, the electronic device 700 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) via a network adapter 760. As shown, the network adapter 760 communicates with other modules of the electronic device 700 via a bus 730. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 700, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.
[0202] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0203] In an exemplary embodiment of the present disclosure, a computer-readable storage medium is also provided, which may be a readable signal medium or a readable storage medium. A program product capable of implementing the above method of the present disclosure is stored thereon. In some possible implementations, various aspects of the present disclosure may also be implemented in the form of a program product, which includes a program code, and when the program product is run on a terminal device, the program code is used to cause the terminal device to execute the steps according to various exemplary implementations of the present disclosure described in the above “Exemplary Method” section of this specification.
[0204] More specific examples of computer-readable storage media in the present disclosure may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0205] In the present disclosure, a computer readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0206] Alternatively, the program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0207] In an exemplary embodiment of the present disclosure, a computer program product is also provided. The computer program product includes a computer program or computer instructions. The computer program or computer instructions are loaded and executed by a processor to enable a computer to implement any of the above hard disk performance testing methods.
[0208] In a specific implementation, the program code for performing the operations of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0209] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0210] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.
[0211] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0212] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The description and examples are to be regarded as exemplary only, and the true scope of the present disclosure is indicated by the appended claims.
Claims
1. A hard disk performance testing method, characterized in that: The test environment for the hard disk performance test is a test environment for an application cluster based on a Docker container, and the method includes: Divide multiple hard disks to be tested into N groups, wherein one group of hard disks to be tested corresponds to one numa node, and the one numa node corresponds to multiple PCIe channels and multiple CPU cores; a group of hard disks to be tested shares one numa node and multiple CPU cores corresponding to the one numa node; the group of hard disks to be tested are mounted on the test server in parallel through the multiple PCIe channels corresponding to the one numa node; bind each of the hard disks to be tested in each group to the numa node, the CPU core and the PCIe channel; Performing parallel testing on the multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel; Monitoring the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test task; When executing a sub-test task, determining the scheduling rules for multiple hard disks to be tested to execute the sub-test task according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server, wherein the resources of the test server include the CPU core of the test server, the numa node of the test server and the PCIe channel of the test server; Execute the one sub-test task on the multiple hard disks to be tested according to the scheduling rule; After all sub-test tasks are completed, the performance test results are obtained; Among them, when executing a sub-test task, the scheduling rules for multiple hard disks to be tested to execute the sub-test task are determined according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server, including: querying the resource occupancy of the test server; judging whether the resources required for the current sub-test task are greater than the free resources of the test server; if greater, selecting some of the hard disks to be tested to execute the current sub-test task in parallel; when some of the hard disks to be tested have completed the execution of the current sub-test task, unbinding some of the hard disks to be tested from the corresponding resources, and binding the unbound resources to the hard disks to be tested that have not performed the current sub-test task, until all of the hard disks to be tested have completed the current sub-test task.
2. The hard disk performance testing method according to claim 1, characterized in that: The method further comprises: If the resources required by the current sub-test task are less than or equal to the idle resources of the test server, all the hard disks to be tested execute the current sub-test task in parallel.
3. The hard disk performance testing method according to claim 1 or 2, characterized in that: The method further comprises: Querying the test progress of the hard disk to be tested in a group in executing the current sub-test task; When all the hard disks to be tested in a group have completed the current sub-test task, the next sub-test task is executed until all sub-test tasks are completed.
4. The hard disk performance testing method according to claim 1, characterized in that: After all sub-test tasks are completed and performance test results are obtained, the method includes: Comparing the performance test result of the hard disk to be tested with a preset test threshold, determining the performance test result of the hard disk to be tested according to the comparison result, and generating test log information; A test report is generated according to the test log information and hard disk information, wherein the hard disk information includes the number, manufacturer name, hard disk model, and read / write speed of the hard disk to be tested.
5. The hard disk performance testing method according to claim 1, characterized in that: The sub-test tasks include a data clearing task, a random read and write initialization task, a random read and write performance test task, a random read and write delay performance test task, a sequential read and write initialization task, and a sequential read and write performance test task.
6. The hard disk performance testing method according to claim 1, characterized in that: Before performing parallel testing on a plurality of hard disks to be tested according to a preset test task, the method further includes: The test environment is deployed according to the image, and the hard disk to be tested executes the test task in the test environment.
7. The hard disk performance testing method according to claim 6, characterized in that: The test environment is deployed according to the image, including: Deploy an operating system on the test server for the hard disk to be tested to perform the test task; Install the Docker engine on the operating system; Installing a Docker image of an application on the test server, where the Docker image of the application is obtained through the Docker engine; The Docker image of the application is used to start a Docker container for executing the test task, forming a test environment for an application cluster based on a Docker container.
8. The hard disk performance testing method according to claim 7, characterized in that: The Docker image of the application includes a testing tool, monitoring software and a dependency package. The testing tool is used to execute the testing task on the hard disk to be tested. The monitoring software is used to monitor the testing progress of multiple hard disks to be tested and the occupancy information of the resource information. The dependency package provides guarantee for the compilation and operation of the testing tool and the monitoring software.
9. A hard disk performance testing device, characterized in that: The test environment for the hard disk performance test is a test environment for an application cluster based on a Docker container, including: A performance testing module is used to divide multiple hard disks to be tested into N groups, wherein a group of hard disks to be tested corresponds to a numa node, and the one numa node corresponds to multiple PCIe channels and multiple CPU cores; a group of hard disks to be tested share a numa node and multiple CPU cores corresponding to the one numa node; the group of hard disks to be tested are mounted on a test server in parallel through the multiple PCIe channels corresponding to the one numa node; each of the hard disks to be tested in each group of the hard disks to be tested is bound to the numa node, the CPU core and the PCIe channel; The performance test module is further used to perform parallel testing on multiple hard disks to be tested according to a preset test task, wherein the test task includes multiple sub-test tasks, and the multiple hard disks to be tested are mounted on the test server in parallel; A monitoring module, used to monitor the test progress of each hard disk to be tested, where the test progress is the progress of the sub-test task; A scheduling rule establishment module is used to determine the scheduling rules for multiple hard disks to be tested to execute a sub-test task according to the type of the sub-test task, the test progress of the sub-test task and the resource occupancy of the test server when executing the sub-test task, wherein the resources of the test server include the CPU core of the test server, the numa node of the test server and the PCIe channel of the test server; The performance testing module is further configured to execute the one sub-test task on the multiple hard disks to be tested according to the scheduling rule; The test result generation module is used to obtain the performance test results after all sub-test tasks are completed; Among them, the scheduling rule establishment module is also used to query the resource occupancy of the test server; determine whether the resources required for the current sub-test task are greater than the idle resources of the test server; if greater, select some of the hard disks to be tested to execute the current sub-test task in parallel; when some of the hard disks to be tested have completed the execution of the current sub-test task, unbind some of the hard disks to be tested from the corresponding resources, and bind the unbound resources to the hard disks to be tested that have not performed the current sub-test task until all of the hard disks to be tested have completed the current sub-test task; if the resources required for the current sub-test task are less than or equal to the idle resources of the test server, all of the hard disks to be tested execute the current sub-test task in parallel.
10. An electronic device, characterized in that: include: processor; as well as A memory, configured to store executable instructions of the processor; Wherein, the processor is configured to execute the hard disk performance testing method described in any one of claims 1-8 by executing the executable instructions.
11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the hard disk performance testing method described in any one of claims 1 to 8 is implemented.
