Test resource allocation method and apparatus, and computer program product
By obtaining the target performance parameter set of the storage device and rationally allocating the number of processor cores, the processor performance bottleneck problem caused by insufficient test resources is solved, the balance between test resources and system load is achieved, and costs and resource waste are reduced.
Patent Information
- Application Number
- CN202410490058.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-22
- Publication Date
- 2024-08-27
AI Technical Summary
In performance testing, insufficient testing resources lead to processor performance bottlenecks and affect the performance of storage devices. Parallel testing increases resource usage, further exacerbating the bottleneck problem.
Use the testing tool to obtain the target performance parameter set of the storage device under performance steady state, determine the number of processor cores, and reasonably allocate test resources according to the configuration information to ensure the balance between system load and resources.
It reduces the impact of processor performance bottlenecks on storage device performance, rationally allocates test resources, reduces resource waste, and reduces test costs.
Smart Images

Figure CN118550686A
Abstract
Description
Technical Field
[0001] The present application relates to the field of testing technology, and in particular to a method and device for allocating testing resources, and a computer program product. Background Art
[0002] Performance testing is used to monitor the operating status of storage devices, and a certain amount of test resources will be occupied during performance testing. With the development of storage devices, the requirements for test resources are getting higher and higher. If the test resources do not meet the requirements, it will cause performance bottlenecks in the processor, thus affecting the performance of the storage device. Therefore, how to reasonably allocate test resources is very important. Summary of the invention
[0003] The present application provides a method and device for allocating test resources, and a computer program product, so as to reasonably configure test resources, determine the optimal system load under limited test resources, and obtain the minimum configuration requirements of test resources under limited load quantity, which is conducive to achieving a balance between test resources and system load.
[0004] Specifically, the technical solution of this application is as follows:
[0005] In a first aspect, a method for allocating test resources is provided, which is applied to a storage system, wherein the storage system includes a plurality of storage devices, wherein the plurality of storage devices include a first storage device, and the method for allocating test resources includes:
[0006] Obtaining, by means of a test tool, a target performance parameter set of the first storage device in a steady state of performance;
[0007] Determining a first number of processor cores of the first storage device according to the target performance parameter set;
[0008] The test resource is allocated to the plurality of storage devices according to configuration information of the test resource and the first quantity; the configuration information includes the second quantity of processor cores in the test resource or the third quantity of the plurality of storage devices.
[0009] In one implementation, obtaining, by a test tool, a target performance parameter set of the first storage device in a steady state performance includes:
[0010] When the first storage device is in the performance steady state, configuring at least one test parameter of the test tool; and performing a performance test on the first storage device through the test tool to generate a first performance parameter set;
[0011] Repeating the configuration of the at least one test parameter a preset number of times until a plurality of the first performance parameter sets are generated;
[0012] An optimal first performance parameter set is selected from multiple first performance parameter sets as the target performance parameter set.
[0013] In the embodiment of the present application, when the first storage device is in a steady state of performance, the optimal performance of the first storage device in the steady state is accurately debugged through a testing tool.
[0014] In one implementation, the method further includes: when the system resource utilization rate corresponding to the best first performance parameter set among the plurality of first performance parameter sets is outside a preset range, removing the best first performance parameter set from the plurality of first performance parameter sets; and reselecting the best performance parameter set from the remaining performance parameter sets as the target performance parameter set. The embodiment of the present application further selects a performance parameter set that takes into account both system resources and storage device performance in consideration of system resource utilization, which is conducive to alleviating processor performance bottlenecks.
[0015] In one implementation, the at least one test parameter includes queue depth and / or number of threads;
[0016] The first performance parameter set includes a first throughput, a second throughput, a first read / write request volume, and a second read / write request volume.
[0017] In one implementation, determining the first number of processor cores of the first storage device according to the target performance parameter set includes:
[0018] Allocating the processor cores of the test resource to the first storage device according to a preset number; and performing the performance test on the first storage device to obtain a second performance parameter set;
[0019] When the second performance parameter set is the same as the target performance parameter set, the preset number is the first number;
[0020] When the second performance parameter set is different from the target performance parameter set, the preset number is adjusted, and the processor cores of the test resources are allocated to the first storage device according to the adjusted preset number; and the performance test is performed on the first storage device, and the second performance parameter set is reacquired until the second performance parameter set is the same as the target performance parameter set.
[0021] In one implementation, when the configuration information is the second quantity, allocating the test resources to the multiple storage devices based on the configuration information of the test resources and the first quantity includes: determining the fifth quantity of storage devices in the storage system based on the first quantity and the second quantity; and allocating the test resources based on the fifth quantity.
[0022] In one implementation, when the configuration information is the third quantity, allocating the test resources to the multiple storage devices based on the configuration information of the test resources and the first quantity includes: determining the sixth number of processor cores in the test resources based on the third number and the first number; and allocating the test resources based on the sixth number.
[0023] In one implementation, the method further includes: performing a steady-state test on the first storage device by configuring a steady-state test interface of the test tool, so that the first storage device is in the performance steady state.
[0024] In a second aspect, a test resource allocation device is provided, comprising a processor for calling instructions stored in a memory, wherein when the instructions are called by the processor, the processor executes any one of the allocation methods provided in the first aspect.
[0025] According to a third aspect, a computer program product is provided, comprising instructions, wherein when the instructions are executed by a processor, any allocation method provided in the first aspect is executed.
[0026] Compared with the prior art, the present invention has at least one of the following beneficial effects:
[0027] The present application uses a testing tool to accurately debug a target performance parameter set of a first storage device in a steady state, and determines the number of processor cores (a first number) required for a single storage device in a steady state through the parameter set. Based on the first number, the optimal system load can be determined under limited test resources, and the minimum configuration requirements of the test resources can be obtained under limited load quantities. This is conducive to achieving a balance between test resources and system load. On the one hand, it can reduce the impact of processor performance bottlenecks on the test performance of storage devices. On the other hand, it can reasonably configure test resources and reduce unnecessary waste of resources, thereby reducing testing costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] The following is a brief introduction to the drawings used in describing the embodiments of the present application:
[0029] Figure 1 A flowchart of a method for allocating test resources provided in an embodiment of the present application;
[0030] Figure 2 A flowchart of another method for allocating test resources provided in an embodiment of the present application;
[0031] Figure 3 A schematic diagram of the structure of a test resource allocation device provided in an embodiment of the present application;
[0032] Figure 4 A schematic diagram of the structure of another test resource allocation device provided in an embodiment of the present application;
[0033] Figure 5 A schematic diagram of the structure of another test resource allocation device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0034] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the specific implementation methods of the present application will be described below with reference to the accompanying drawings. The accompanying drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other accompanying drawings and other implementation methods can be obtained based on these accompanying drawings without creative work. Adjustments and improvements made without departing from the concept of the present application are all within the scope of protection of the present application.
[0035] In order to simplify the drawings, each figure only schematically shows the parts related to the corresponding embodiments, and they do not represent the actual structure of the product. In addition, in order to simplify the drawings and facilitate understanding, in some figures, only parts with the same structure or function are schematically shown, and there may be more or fewer parts with the same structure or function in reality.
[0036] In this application, unless otherwise clearly specified and limited, ordinal numbers, such as "first", "second", etc., are only used to distinguish and describe associated objects, and cannot be understood as indicating or implying the relative importance or order between associated objects; in addition, they do not represent the number of associated objects. "Multiple" includes two or more, and other quantifiers are similar. " / " is used to describe the relationship between associated objects, which indicates the "or" relationship between associated objects. "And / or" is used to describe the relationship between associated objects, which includes any combination relationship between associated objects, such as "a and / or b" includes: "alone a", "alone b", or "a and b". "One or more" or "at least one" in multiple objects refers to any object or any combination of multiple objects, such as "one or more of a1, a2, a3" or "at least one of a1, a2, a3" includes: "alone a1", "alone a2", "alone a3", "a1 and a2", "a1 and a3", "a2 and a3", or "a1, a2 and a3".
[0037] Performance testing refers to the process of testing various performance indicators of storage devices by setting different test conditions, also known as read / write (I / O) performance testing. Through performance testing, various I / O performance parameters of storage devices can be obtained, such as throughput, the number of read / write requests per unit time (IOPS), latency, etc., and the operating status of storage devices can be monitored based on these performance parameters. When performing performance testing, certain test resources (processor resources) will be occupied. With the development of storage devices, the requirements for test resources are getting higher and higher. If the test resources do not meet the requirements, processor performance bottlenecks are likely to occur, resulting in excessive processor resource utilization. In this case, in addition to the storage device occupying test resources, there are also many drivers and software that need to use test resources. If all resources are occupied by the storage device, the operating system (OS) will crash. At this time, the system sets an interrupt mechanism to prevent the storage device from occupying too many resources and ensure that the operating system can operate normally. Under the interrupt mechanism, a large number of interrupt tasks will be generated and need to be executed by the processor. At this time, the performance test of the storage device will be interrupted, resulting in unstable read and write performance of the storage device. The true performance of the storage device cannot be tested, making it impossible to achieve the optimal performance of the storage device (which can also be understood as the storage device being speed-limited).
[0038] In addition, to improve test efficiency, in one implementation, a parallel testing solution is adopted. For example, multiple storage devices are simultaneously subjected to performance testing. At this time, these parallel tested storage devices constitute a storage system. In the case of such parallel testing, more processor resources will be occupied, making the problem of processor performance bottleneck more serious, and further causing performance limitations of the storage devices.
[0039] In view of the above problems, the embodiment of the present application provides a method for allocating test resources, which can reasonably configure the test resources and balance the test resources and the test load to reduce the impact of the processor performance bottleneck on the performance of the storage device. It should be noted that the storage system in the embodiment of the present application includes at least one storage device. The storage device can be, for example, a solid state drive (SSD), a traditional hard disk (HDD), a hybrid hard disk (HHD), etc., and the present application does not limit the type of storage device. When the storage system includes multiple storage devices, these storage devices can be of the same or different types. In addition, the embodiment of the present application does not limit the interface of the storage device and the standard corresponding to the interface. For example, the interface can adopt a high-speed serial computer expansion bus standard (peripheral component interconnect express, PCIe) interface, a serial hardware driver interface (serial advanced technology attachment, SATA), etc., and the interface standard is such as a non-volatile memory host controller interface standard (non-volatile memory express, NVME), an advanced host controller standard (advanced host controller interface, AHCI), etc.
[0040] The following is a description with reference to the accompanying drawings. Figure 1 , which is a flow chart of a method for allocating test resources provided in an embodiment of the present application. Figure 1 As shown, the allocation method comprises at least the following steps:
[0041] S110 obtains a target performance parameter set of the first storage device in a steady state of performance through a testing tool.
[0042] S120: Determine a first number of processor cores of a first storage device according to the target performance parameter set.
[0043] S130 allocates the test resources to the plurality of storage devices according to the configuration information and the first quantity of the test resources; the configuration information includes the second quantity of the plurality of storage devices or the third quantity of the processor cores in the test resources.
[0044] Taking a storage system including multiple storage devices as an example, when these storage devices meet certain conditions, such as these storage devices have the same model or belong to the same batch, their performance parameters after performance testing can also be considered the same, so any one of the storage devices can be used as the first storage device. For a storage device, its performance status includes the factory state (fresh out of the box, FOB), the transition stage (transition), and the performance steady state (steadystate). In the factory state, the storage device does not write data, and the performance of the storage device can reach its peak performance in this stage. In the transition stage, as data is continuously written, the writable space of the storage device becomes smaller. When it is reduced to a certain threshold, the storage device will be triggered to release free space. In this stage, the performance of the storage device will decrease and fluctuate. When the size of the released free space tends to be balanced with the amount of data written, the performance of the storage device will gradually stabilize and remain in this state for a long time. This state is the performance steady state (hereinafter referred to as steady state). In one implementation, the storage device can enter the performance steady state through performance testing, for example, including the following steps:
[0045] Step 1: Purge. Purge must be performed before each performance test to eliminate the impact of pre-reading and writing or other pre-tests before the test, so as to ensure that the storage device is in the same state before each performance test. Purge can also be understood as returning the storage device to the FOB state.
[0046] Step 2: Preconditioning, which is to gradually enter a stable performance state by performing multiple read and write operations on the storage device. For example, it can be divided into two steps:
[0047] (1) Workload independent preconditioning (WIPC): that is, no test load is used during reading and writing. In one implementation, a logical block size (BS) of 128KB can be used to fill (i.e., write data) the storage device twice in a sequential write manner. In other implementations, BS can also be set to other values.
[0048] (2) Workload dependent preconditioning (WDPC): that is, using test loads (test tasks) when reading and writing. During the WDPC process, multiple performance tests are repeated, such as repeated throughput tests, IOPS tests, and latency tests. Set a repetition threshold, for example, set it to 25 rounds, and plan to reach a steady state within 25 rounds. Assume that the steady state is reached in the nth round (n≥1): 1 to n rounds are the stable convergence interval; n-4 to n rounds are the measurement interval. If the steady state is not reached after 25 rounds, continue WDPC until the steady state is reached and record the number n at this time, or directly take n=25.
[0049] The above performance test process of making the storage device enter a steady state can be called a steady state test. Further, the steady state test can be implemented through a test tool. The test tool includes different test interfaces. By configuring parameters of these interfaces, different performance tests can be performed on the storage device. Test tools such as flexible I / O test tools (flexible I / O tester, FIO), FIO has a specific steady state test interface (steady state interface), which can be called by the python language to implement the above steady state test process and accurately control the storage device to enter a steady state. The python language is an open source language with good scalability and portability. The implementation process of the steady state test process is made more efficient and simple by the python language, and can be applied to different operating system platforms and has a wider range of applications. Further, it can support the introduction of multi-language scripts, such as Java language, PHP language, etc., and the present application does not limit the language framework used to call the test tool interface. In addition, in one implementation, other I / O test tools can also be used for steady state testing, such as iometer, orion, etc.
[0050] The aforementioned factory state (FOB) and conversion state are collectively referred to as non-steady state. In the non-steady state, the storage device has performance fluctuations, and the performance test mainly assesses the daily performance of the storage device, so it is necessary to obtain the performance parameters of the storage device in the steady state. In the steady state of performance, the performance value of the storage device (that is, the value of the performance parameter) will be stable within a range, and the performance value of the storage device in the steady state is also called the steady-state value. Furthermore, there is an optimal value (that is, the steady-state optimal value) within the range. When the performance value of the storage device is the steady-state optimal value, it indicates that the performance of the storage device in the steady state is optimal. The steady-state value or steady-state optimal value of at least one parameter can constitute the target performance parameter set.
[0051] The process of obtaining the target performance parameter set can also be achieved through a test tool. Similarly, by configuring the parameters of the test interface of the test tool, one or more performance tests can be performed on the storage device, such as IOPS test, throughput test, latency test, saturation write test, etc. It should be noted that the test tool used to obtain the target performance parameter set can be the same as or different from the test tool used in the steady-state test. The following is an explanation of the process of obtaining the target performance parameter set. Please refer to Figure 2 , which is a flow chart of obtaining a target performance parameter set provided by an embodiment of the present application. Figure 2 As shown, the above S110 further includes the following steps:
[0052] S111: When the first storage device is in a stable performance state, configure at least one test parameter of a test tool.
[0053] S112 performs a performance test on the first storage device using a test tool to generate a first performance parameter set.
[0054] S113 repeatedly configures at least one test parameter according to a preset number of times until a plurality of first performance parameter sets are generated.
[0055] S114 selects an optimal first performance parameter set from the multiple first performance parameter sets as a target performance parameter set.
[0056] Specifically, when performing a performance test, one or more test interfaces of the test tool may be configured, that is, one or more test parameters of the test tool may be configured. When the first storage device is in a steady state, at least one test parameter of the test tool is configured, and then a performance test is performed through the test tool to obtain a first performance parameter set. Test parameters refer to parameters that may affect the performance of the storage device, such as queue depth (iodepth), number of threads (numjobs), etc.
[0057] Take the test tool as FIO and the first storage device as SSD as an example. FIO has the iodepth interface and the numjobs interface, through which the corresponding queue depth value and thread number value are configured respectively. The iodepth parameter indicates the maximum number of I / O requests that the system can suspend before each I / O operation is completed. The size of iodepth has an important impact on I / O performance. A larger iodepth value means that the system can process more I / O requests at the same time, which helps to improve IOPS. However, as iodepth increases, the latency of the system may also increase because it needs to wait for more I / O requests to complete. Therefore, by configuring the iodepth value, it is helpful to balance IOPS and latency. The numjobs parameter is used to specify the number of jobs (or threads) executed concurrently. In other words, it defines the number of tasks that send I / O requests to the SSD at the same time. For example, if numjobs=4 is set, FIO will start 4 concurrent threads (or processes) to perform I / O operations. It can be used to simulate the I / O behavior in a multi-user or multi-threaded environment and obtain the performance of the SSD under such concurrency. Configuring numjobs is helpful to optimize system configuration and allocate resources reasonably. In one implementation, the iodepth interface or the numjobs interface may be configured separately; or, on the basis of configuring the iodepth interface and the numjobs interface, other interfaces may be configured to further improve the accuracy of resource configuration.
[0058] After configuring at least one test parameter of the test tool (such as FIO), the corresponding performance parameters can be obtained by setting the test conditions. For example, the logical block size is set to 1024KiB, and sequential writing is performed for ten minutes to obtain the first throughput; the logical block size is set to 1024KiB, and sequential reading is performed for ten minutes to obtain the second throughput; the logical block size is set to 4KiB, and random writing is performed for ten minutes to obtain the first IOPS; the logical block size is set to 4KiB, and random reading is performed for ten minutes to obtain the second IOPS.
[0059] At this time, the first performance parameter set includes the above first throughput, second throughput, first IOPS, and second IOPS. A performance test can obtain a first performance parameter set. In the above step S113, at least one test parameter is repeatedly configured according to a preset number of times, so as to perform multiple performance tests and generate multiple first performance parameter sets. For example, iodepth is configured to 120, 258, and 256, and numjobs is correspondingly configured to 8, 256, and 500, so as to obtain different parameter combinations. Performance tests are performed under different parameter combinations to obtain multiple first performance parameter sets. The above preset number of times can be set according to actual test requirements. In one implementation, the optimal value of the test parameter can be determined by repeated testing. Taking the test parameters as the first parameter and the second parameter as an example, it is assumed that the first parameter is iodepth and the second parameter is numjobs. When configuring the test parameters, the iodepth value can be set unchanged, and the numjobs value can be changed to perform performance testing. After performing the preset number of performance tests, multiple first performance parameter sets will be obtained. Because iodepth is a fixed value, by comparing multiple first performance parameter sets, the best first performance parameter set can be selected. The numjobs value corresponding to this parameter set is the numjobs value that can make the storage device performance reach the best. Similarly, numjobs can be set unchanged while the iodepth value can be changed to obtain the iodepth value that makes the storage device performance reach the best. In this way, based on the optimal values of the above test parameters, the test parameters are configured to improve the accuracy of resource allocation and also improve efficiency. In addition, in an embodiment of the present application, the process of configuring the above test parameters can be automated through language frameworks such as Python language and JAVA language, thereby improving the intelligence of test resource allocation, improving operating efficiency and effectively saving labor costs compared to traditional manual configuration methods.
[0060] In the above step S114, the best first performance parameter set is selected from multiple first performance parameter sets as the target performance parameter set, each performance parameter set corresponds to a performance data point of the storage device, and the performance data point corresponding to the target performance parameter set is the best performance data point of the storage device. Further, repeated performance testing may occupy too many test resources. Therefore, in one implementation, the system resource utilization (processor resource utilization and memory resource utilization) of the test system is synchronously monitored during the performance test, that is, a corresponding system load is also obtained while obtaining the first performance parameter set. When the system load corresponding to the selected best first performance parameter set is within the preset range, it can be considered that the best first performance parameter set meets the requirements; when the system load corresponding to the selected best first performance parameter set is outside the preset range, the best first performance parameter set is eliminated, and the best performance parameter set is reselected from the remaining multiple first performance parameter sets. The preset range, for example, the processor resource utilization and the memory resource utilization are both within 90%, and the preset range can be set according to actual test experience, and this application does not limit this. The embodiment of the present application takes into account the system resource utilization and further selects a performance parameter set that takes into account both system resources and storage device performance, which is helpful in alleviating the processor performance bottleneck.
[0061] The target performance parameter set obtained by repeated performance testing is composed of the steady-state optimal value of at least one performance parameter. The case where the steady-state value constitutes the target performance parameter set is the same as S111 and S112 above, except that repeated testing is not required, which is not described here.
[0062] In the embodiment of the present application, the system load of the storage system refers to the storage device, and the number of system loads is the number of storage devices. Test resources refer to processor resources, such as processor cores. When performing performance testing on storage devices, certain processor resources will be occupied. If the number of storage devices is large, it is more likely to cause processor performance bottlenecks, thereby affecting the read and write performance of the storage devices. Therefore, in order to alleviate the processor performance bottleneck, it is necessary to reasonably allocate processor resources.
[0063] Specifically, after obtaining the target performance parameter set, the number of processor cores of the first storage device, that is, the number of processor cores of a single storage device in the storage system, is determined through the above step S113. In one implementation, the number of processor cores of a single storage device (that is, the first number) can be implemented in the following manner:
[0064] Allocate the processor cores of the test resource to the first storage device according to the preset number; and perform a performance test on the first storage device to obtain a second performance parameter set. When the second performance parameter set is the same as the target performance parameter set, the preset number is the first number; when the second performance parameter set is different from the target performance parameter set, adjust the preset number, allocate the processor cores of the test resource to the first storage device according to the adjusted preset number; and perform a performance test on the first storage device to re-acquire the second performance parameter set until the second performance parameter set is the same as the target performance parameter set.
[0065] Specifically, assuming that the total number of processor cores of the test resource is 8, the preset number is set to 8, and all processor cores in the test resource are allocated to the first storage device. Then, a performance test is performed on the first storage device to obtain a second performance parameter set. The second performance parameter set is compared with the target performance parameter set. If the two are the same, the number 8 is the first number; if the two are different, the number of processor cores allocated to the first storage device is reduced, for example, from 8 to 7, and the performance test of the first storage device is continued to obtain a new second performance parameter set, which is compared with the target performance parameter again, and so on, until the second performance parameter set is the same as the target performance parameter set. Among them, the preset number and the adjusted preset number are less than or equal to the total number of processor cores of the test resource, and adjusting the first preset number is, for example, increasing or decreasing the number.
[0066] In the embodiment of the present application, the target performance parameter set of the first storage device in steady state is used as a reference, and the minimum number of processor cores required for a single storage device in the storage system in steady state is determined by dynamically allocating the number of processor cores to the first storage device. Furthermore, if the target performance parameter set is composed of steady-state optimal values, then the minimum number of processor cores at this time is the minimum number of processor cores required for a single storage device to achieve steady-state optimal performance.
[0067] Based on the minimum number of processor cores n (first number) required for a single storage device, test resources may be allocated. For example, the following two situations may be included:
[0068] (1) When the test resources are limited, the optimal system load quantity (fifth quantity) m1 can be calculated based on the first quantity n and the total number of given processor cores N1 (second quantity). When N1 is a multiple of n, m1=N1 / n, for example, N=8, n=2, then x=4, and 2 processor cores are allocated to the 4 storage devices respectively; when N1 is not a multiple of n, m1=the integer part of N1 / n, for example, when N1=8, n=3, then m1=2, and 3 processor cores are allocated to the 2 storage devices respectively.
[0069] (2) When the system load quantity is determined, the minimum number of processor cores required by the test system (sixth number, i.e., minimum configuration requirement) N2=m2*n can be calculated based on the first number n and the number of storage devices m2 (third number) in the storage system. For example, if n=2 and m2=6, then N2=12, and each storage device can be allocated to 2 processor cores.
[0070] Among them, n, m1, m2, N1, and N2 are all positive integers. In one implementation, the processor cores are allocated to the corresponding storage devices by binding cores. The binding core method, for example, creates different numbers of threads, and defines the range of required processor cores by configuring the "cpus_allowed" parameter. Assuming that the number of CPU cores required to determine the optimal performance of a single SSD is 3, setting "cpus_allowed = 1,2,3" means that the created IO thread is allowed to access the processor cores "core1", "core2", and "core3". Another parameter "cpus_allowed_policy = split" is used to formulate a thread core usage policy to ensure that each thread uses a core independently. Different storage devices are bound to different processor cores, that is, each storage device uses a different CPU core to prevent the storage device from grabbing CPU resources, thereby reducing resource competition and reducing processor performance bottlenecks.
[0071] In the embodiment of the present application, based on the minimum number of processor cores n (first number) required for a single storage device in a steady state, the optimal system load can be automatically determined under limited test resources, and the minimum configuration requirements of the test resources can be automatically obtained under limited load quantity, which is conducive to achieving a balance between test resources and system load and can reduce the consumption of manual resources. On the one hand, it can reduce the impact of processor performance bottlenecks on the test performance of storage devices, and on the other hand, it can reasonably configure test resources, reduce unnecessary resource waste, and thus reduce test costs. The above allocation method is particularly suitable for enterprise-level storage devices. For example, enterprise-level SSDs have high performance requirements in a steady state. Through the allocation method in the embodiment of the present application, higher SSD performance can be achieved with lower resource costs.
[0072] Based on the same technical concept, the embodiment of the present application also provides a test resource allocation device, including a unit or means for executing the steps of any of the above test resource allocation methods. Figure 3The test resource allocation device 300 includes a steady-state performance tuning unit 310 and a test resource optimization unit 320. The steady-state performance tuning module 310 is used to obtain a target performance parameter set of a first storage device in a steady-state performance state through a test tool; and is also used to determine a first number of processor cores of the first storage device according to the target performance parameters. The test resource optimization unit 320 is used to allocate test resources to multiple storage devices according to configuration information and the first number of test resources; the configuration information includes a second number of multiple storage devices or a third number of processor cores in the test resources.
[0073] Further, when the configuration information is the second number of processor cores in the processor resources, the test resource optimization unit 320 is used to determine the third number of storage devices in the storage system according to the first number and the second number, and is also used to allocate test resources according to the third number. In one implementation, when the configuration information is the fourth number of storage devices in the storage system, the test resource optimization unit 320 is used to determine the fifth number of processor cores in the test resources according to the fourth number and the first number, and is also used to allocate test resources according to the fifth number.
[0074] In one implementation, Figure 4 As shown, the allocation device 300 further includes a steady-state pre-import unit 330, which is used to perform a steady-state test on the first storage device by configuring a steady-state test interface of a test tool to put the first storage device in a performance steady state.
[0075] It should be understood that the division of the above units is only a division of logical functions. In actual implementation, they can be fully or partially integrated into one physical entity, or they can be physically separated. In addition, the above units can be implemented in the form of a processor calling software; for example, the system includes a processor, the processor is connected to a memory, and instructions are stored in the memory. The processor calls the instructions stored in the memory to implement any of the above methods or realize the functions of each unit, wherein the processor is, for example, a general-purpose processor, such as a central processing unit (CPU), and the memory is a memory in the device or a memory outside the device. Alternatively, the above units can be implemented in the form of hardware circuits, and the functions of some or all units can be realized by designing the hardware circuits. The hardware circuit can be understood as one or more processors; for example, in one implementation, the hardware circuit is an application specific integrated circuit (ASIC), and the functions of some or all units above are realized by designing the logical relationship of the components in the circuit; for example, in another implementation, the hardware circuit can be implemented by a programmable logic device (PLD), which can include a large number of logic gate circuits, and the logical relationship between the logic gate circuits is configured by a configuration file, so as to realize the functions of some or all units above. All units of the above system may be implemented entirely in the form of a processor calling a program, or entirely in the form of a hardware circuit, or partially in the form of a processor calling a program and the rest in the form of a hardware circuit.
[0076] For example, see Figure 5 , which is a schematic diagram of the structure of a test resource allocation device provided in an embodiment of the present application. Figure 5 As shown, the allocation device 500 includes a processor 510, which is used to call instructions stored in a memory 520. When the instructions are called by the processor 510, the processor 510 executes any allocation method in the above embodiments.
[0077] In addition, an embodiment of the present application further provides a computer-readable storage medium, including instructions stored thereon, and when the instructions are called by a processor, any of the allocation methods in the above embodiments is executed. An embodiment of the present application further provides a computer program (or computer program product), including instructions, and when the instructions are called by a processor, any of the allocation methods in the above embodiments is executed.
[0078] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments. In addition, the above embodiments can be freely combined as needed.
Claims
1. A method for allocating test resources, characterized in that: Applied to a storage system, the storage system includes a plurality of storage devices, the plurality of storage devices include a first storage device, the allocation method includes: Obtaining, by means of a test tool, a target performance parameter set of the first storage device in a steady state of performance; Determining a first number of processor cores of the first storage device according to the target performance parameter set; The test resource is allocated to the plurality of storage devices according to configuration information of the test resource and the first quantity; the configuration information includes the second quantity of processor cores in the test resource or the third quantity of the plurality of storage devices.
2. The distribution method according to claim 1, characterized in that: The step of obtaining the target performance parameter set of the first storage device in a steady state performance by using a test tool includes: When the first storage device is in the performance steady state, configuring at least one test parameter of the test tool; and performing a performance test on the first storage device through the test tool to generate a first performance parameter set; Repeating the configuration of the at least one test parameter a preset number of times until a plurality of the first performance parameter sets are generated; An optimal first performance parameter set is selected from multiple first performance parameter sets as the target performance parameter set.
3. The distribution method according to claim 2, characterized in that: Also includes: When the system resource utilization rate corresponding to the best first performance parameter set among the multiple first performance parameter sets is outside a preset range, removing the best first performance parameter set from the multiple first performance parameter sets; And reselect the optimal performance parameter set from the remaining performance parameter sets as the target performance parameter set.
4. The distribution method according to claim 2, characterized in that: The at least one test parameter includes queue depth and / or number of threads; The first performance parameter set includes a first throughput, a second throughput, a first read / write request volume, and a second read / write request volume.
5. The distribution method according to claim 2, characterized in that: The determining, according to the target performance parameter set, the first number of processor cores of the first storage device includes: Allocating the processor cores of the test resource to the first storage device according to a preset number; and performing the performance test on the first storage device to obtain a second performance parameter set; When the second performance parameter set is the same as the target performance parameter set, the preset number is the first number; When the second performance parameter set is different from the target performance parameter set, the preset number is adjusted, and the processor cores of the test resources are allocated to the first storage device according to the adjusted preset number; and the performance test is performed on the first storage device, and the second performance parameter set is reacquired until the second performance parameter set is the same as the target performance parameter set.
6. The method according to any one of claims 1 to 5, characterized in that: When the configuration information is the second number, The allocating the test resources to the plurality of storage devices according to the configuration information of the test resources and the first quantity includes: Determining a fifth number of storage devices in the storage system according to the first number and the second number; The test resources are allocated according to the fifth number.
7. The method according to any one of claims 1 to 5, characterized in that: When the configuration information is the third number, The allocating the test resources to the plurality of storage devices according to the configuration information of the test resources and the first quantity includes: determining a sixth number of processor cores in the test resource according to the third number and the first number; The test resources are allocated according to the sixth quantity.
8. The distribution method according to claim 1, characterized in that: Also includes: By configuring the steady-state test interface of the test tool, a steady-state test is performed on the first storage device, so that the first storage device is in the performance steady state.
9. A device for allocating test resources, characterized in that: The method comprises a processor, which is used to call instructions stored in a memory, and when the instructions are called by the processor, the processor executes the allocation method according to any one of claims 1 to 8.
10. A computer program product, characterized in that The method comprises instructions, wherein when the instructions are executed by a processor, the allocation method according to any one of claims 1 to 8 is executed.
Citation Information
Cited By
Methods and apparatus to reduce an action space for workload execution
EP4745783A1
