A method and device for testing disk I / O limit performance in a cloud host

The adaptive differential evolution algorithm is used to search for the best parameter combination in the cloud host population, which solves the problem of time-consuming and labor-intensive cloud host disk I/O performance testing and low reliability of results, and achieves fast and accurate performance testing and tuning. .

CN116450429BActive Publication Date: 2024-09-27CHINA TELECOM CLOUD TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310263712.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-10
Publication Date
2024-09-27
Estimated Expiration
2043-03-10

AI Technical Summary

Technical Problem

In the existing technology, cloud host disk I/O performance testing is time-consuming and labor-intensive, and the test results have low credibility and reliability, making it difficult to quickly and accurately obtain the ultimate performance of the disk or file system.

Method used

An adaptive differential evolution algorithm is used to search for the best numjobs and iodepth parameter combination, and the Fio tool is used to perform search operations in the cloud host population to determine the disk I/O limit storage performance.

Benefits of technology

It realizes fast and accurate cloud host disk I/O extreme performance testing, improves test efficiency and result reliability, and supports disk I/O extreme performance tuning, file system I/O extreme performance testing and storage virtualization tuning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116450429B
    Figure CN116450429B
Patent Text Reader

Abstract

The present invention discloses a method and device for testing the disk I / O limit performance in a cloud host, which relates to the field of cloud host performance testing, including: S1 control node creates a target cloud host population; S2 computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination; S3 control node deletes the target cloud host population. The method effectively solves the time-consuming and labor-intensive problems caused by manual parameter adjustment and the problems of low credibility and poor reliability of test results caused by manual parameter adjustment, thereby realizing rapid and accurate testing of the disk I / O limit storage performance in the cloud host, which is helpful for disk I / O limit performance tuning, file system I / O limit performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc. The test device has the advantages of good portability and ease of use.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of cloud host performance testing, and in particular to a method and device for testing disk I / O limit performance in a cloud host. Background Art

[0002] As a revolution in the field of computer networks, cloud computing is profoundly changing the way society works and the business model. Data in the information age is growing exponentially, and it is particularly important to persist important data, which puts higher requirements on storage in cloud computing scenarios. Virtualization is the foundation of cloud computing development. CPUs can be virtualized, memory can be virtualized, and storage also has corresponding virtualization technology - storage virtualization. Storage virtualization enables storage devices to be converted into logical data storage. Data storage is a logical container similar to a file system, which hides the characteristics of each storage device and forms a unified model to provide disks for cloud hosts. Storage virtualization technology helps the system manage storage resources and improve resource utilization and flexibility. Computing, storage, network, and security are four important components of cloud computing. In order to measure storage performance in cloud computing, the usual practice is to use mainstream testing tools such as Fio and iometer to perform read and write tests on disks or file systems. IOPS and Band Width (BW) are two important indicators for measuring disk performance. IOPS refers to the number of I / O requests that the system can handle per unit time. I / O requests are usually read or write data operation requests. BW refers to the amount of data that can be successfully transmitted per unit time. For applications with frequent random reads and writes, such as OLTP (Online Transaction Processing), IOPS is the key measurement indicator. For applications with a large number of sequential reads and writes, such as VOD (Video On Demand), BW is more important.

[0003] Fio is an open source I / O stress testing tool, mainly used to test the I / O performance of disks or file systems. It can support 13 different I / O engines, including sync, mmap, libaio, etc., and is easy to use in Linux systems. However, in actual project applications, we found that Fio's two parameters numjobs and iodepth have a great impact on the performance indicators IOPS and BW, and different parameter combinations will result in different IOPS and BW. In many applications, more attention is paid to the average IOPS and maximum value (extreme performance) of the disk or file system I / O and BW to measure the extreme performance of the disk or file system, which requires finding the best numjobs and iodepth parameter combination. As can be seen from the above, it is not easy to obtain the best parameter combination. On the one hand, if it is done manually, it needs to be repeated hundreds or thousands of times, which will consume a lot of time and energy; on the other hand, the best parameter combination is different in different scenarios, and the accumulated experience may not be applicable. The measured IOPS and BW are likely to be local maximum values, rather than global maximum IOPS and BW, resulting in low credibility and poor reliability of the test results. Summary of the invention

[0004] The embodiments of the present application provide a method and device for testing the disk I / O limit performance in a cloud host, thereby solving the problems of time-consuming and labor-intensive, low credibility of test results, and poor reliability in the prior art, and achieving rapid and accurate testing of the disk I / O limit performance in a cloud host, which is helpful for disk I / O limit performance tuning in a cloud host, file system I / O limit performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc.

[0005] To achieve the above objectives, the present invention is implemented through the following technical solutions: A method for testing disk I / O limit performance in a cloud host, comprising:

[0006] The method is carried out according to the following steps:

[0007] S1: The control node creates the target cloud host population;

[0008] S2: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0009] S3: The control node deletes the target cloud host population.

[0010] Furthermore, the target cloud host population is N pThe individuals of the target cloud hosts are the gene combinations of the target cloud hosts, the genes of the target cloud hosts are the numjobs and iodepth parameters of the target cloud hosts, the cloud hosts of the target cloud host population are in the same network segment, the size and type of the disks mounted by the cloud hosts are consistent, and they are connected to each other through ssh;

[0011] The control node is node 0, which is responsible for controlling the remaining nodes, including the creation and deletion of the target cloud host;

[0012] The computing node is responsible for the operation of the target cloud host.

[0013] Furthermore, the specific execution steps of S2 are as follows:

[0014] S31: Execute the Fio command on the target cloud host No. 0, and observe the time it takes for IOPS and BW to stabilize in real time to determine the parameters runtime and ramp_time, which will be used in subsequent disk I / O storage performance tests;

[0015] S32: performing a search operation in the target cloud host population according to a Differential Evolution Algorithm (DE), returning an optimal parameter combination, and outputting maximum IOPS and BW, where the IOPS and BW are important indicators for measuring disk I / O storage performance.

[0016] Furthermore, the Fio is an open source I / O stress testing tool, which is mainly used to test the I / O storage performance of a disk or file system;

[0017] IOPS refers to the number of I / O requests that a system can process per unit time, and is a key indicator of performance for applications with frequent random reads and writes.

[0018] The BW refers to the amount of data that can be successfully transmitted per unit time, and is a performance concern for a large number of sequential read and write applications.

[0019] Furthermore, the specific execution steps of S32 are as follows:

[0020] S51: Initialization operation, determine the boundary formula, execute the test script on the control node, and obtain N through the initialization formula p individuals, and then 1~N p Individuals are embedded into the Fio command to obtain N p command, N p The commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to the control node to get Ω(x i(0));

[0021] S52: mutation operation, generating the g-th generation mutant population through the mutation formula on the control node. If the gene of the mutant individual does not meet the boundary requirements, the gene is regenerated through the initialization formula;

[0022] S53: Crossover operation, generate the population after the g-th generation crossover through the crossover formula on the control node, and get N p mutant individuals, N p The mutant individuals are embedded into the Fio command to obtain N p Test commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to cloud host 0 and get Ω(u i (g));

[0023] S54: selection operation, selecting individuals in the g+1 generation population through the selection formula on the control node, and judging whether to terminate the search according to the judgment formula. If the search is terminated, execute S55, otherwise return to S52, and re-execute S52 to S54 for the g+1 generation in sequence;

[0024] S55: Return the best parameter combination and output the maximum IOPS and BW;

[0025] S56: For the four modes of read, write, randread, and randwrite, the above steps S51-S55 are executed in sequence to obtain the disk I / O extreme storage performance in the cloud host according to the output maximum IOPS and BW.

[0026] Furthermore, the boundary formula in S51 is:

[0027] Definition N p The target cloud host, the genes of the target cloud host are the numjobs and iodepth parameters of the target cloud host, numjobs and iodepth are replaced by x, denoted as x i,j (g), g is the number of generations of the population;

[0028] The individual of the target cloud host is the gene combination of the target cloud host, denoted by x i (g) = (x i,1 (g),x i,2 (g))=(iodepth i (g),numjobs i (g));

[0029] The target cloud host population is N p The individuals of the target cloud host are recorded as

[0030] Define the upper and lower limits of iodepth and numjobs as x respectively L and x U , that is, x L =(iodepth L ,numjobs L ), x U =(iodepth U ,numjobs U ), then any individual in any generation satisfies the boundary formula, which is:

[0031] x L ≤x i (g)≤x U (1)

[0032] For the initial population, g = 0, the individuals in the population are is randomly generated, and the initialization formula is:

[0033]

[0034] In the formula, j=1,2, rand(0,1) represents a random number uniformly distributed in the interval (0,1), and [f] represents rounding f to an integer.

[0035] Further, the variation formula in S52 includes a stretching formula and a scaling formula;

[0036] The individual mutation is achieved through the differential strategy. The vector difference is scaled and changed through the scaling formula, and then the vector is synthesized with the individual to be mutated to obtain the mutant individual. The scaling formula is:

[0037]

[0038] Wherein, i≠r1≠r2≠r3, F is a scaling factor, and an adaptive scaling factor is selected according to a scaling formula, wherein the scaling formula is:

[0039]

[0040] In the formula, G m is the maximum evolutionary generation, and F0 is the initial value of the scaling factor. Adaptive scaling factors are used to maintain individual diversity in the early stage, and to retain excellent information when the mutation rate is close to F0 in the later stage to avoid the destruction of the optimal solution, thereby increasing the global search capability of the algorithm.

[0041] Further, the crossover formula in S53 includes a gene formula and a probability formula;

[0042] The crossover operation is performed on the g-th generation population X(g) and the mutant population V(g) generated by the mutation operation according to the gene formula to obtain the crossover population U(g). i,j (g) determine the following:

[0043]

[0044] Where CR is the crossover probability, j rand is a random integer between 1 and 2. CR determines the degree to which the mutant individuals enter the crossover population. The mean of CR is kept at 0.75 through the probability formula to maintain population diversity:

[0045] CR=0.5·(1+rand(0,1))

[0046] Furthermore, the selection formula and the judgment formula in S54 are:

[0047] Assume that the parameter combination x i The performance indicator (IOPS or BW) measured in Fio is Ω(x i ), then the g+1th generation individuals are determined according to the selection formula:

[0048]

[0049] Assume that the maximum evolutionary generation is G m , the best performance index tested by the g-th generation population is Ω m (g) Stop searching when the judgment formula is met:

[0050] g>G m or|Ω m (g+1)-Ω m (g)|≤ε

[0051] Where ε is the stability threshold.

[0052] The present invention also provides a disk I / O limit performance testing device in a cloud host, comprising:

[0053] Creation module: Controls the node to create the target cloud host population;

[0054] Testing module: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0055] Deletion module: The control node deletes the target cloud host population.

[0056] One or more technical solutions provided in the embodiments of the present application have at least the following technical effects or advantages:

[0057] 1. Since an adaptive differential evolution algorithm is used to search for the best parameter combination, the time-consuming and labor-intensive problem caused by manual parameter adjustment is effectively solved, thereby realizing the rapid testing of the disk I / O extreme storage performance in the cloud host and improving the testing efficiency.

[0058] 2. Since the differential evolution algorithm is used to search for the best parameter combination under four different modes, the problem of low credibility and poor reliability of test results caused by manual parameter adjustment is effectively solved, thereby achieving accurate testing of the disk I / O extreme storage performance in the cloud host and improving the reliability of the results.

[0059] 3. Due to the use of differential evolution algorithm to search for the best parameter combination under four different modes, it is possible to quickly and accurately test the disk I / O extreme storage performance in the cloud host, which is helpful for disk I / O extreme performance tuning, file system I / O extreme performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc. The provided test device has the advantages of good portability and ease of use. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] Figure 1 This is an overall flow chart of a method for testing disk I / O limit performance in a cloud host according to the present invention;

[0061] Figure 2 This is a relationship diagram between IOPS, iodepth, and numjobs described in the present invention;

[0062] Figure 3 This is a relationship diagram of BW, iodepth, and numjobs described in the present invention;

[0063] Figure 4 A swimlane diagram of a disk I / O limit performance testing device in a cloud host in Embodiment 2 of the present application;

[0064] Figure 5 This is a framework diagram of a disk I / O limit performance testing device in a cloud host in Example 2 of the present application. DETAILED DESCRIPTION

[0065] The present invention provides a method and device for testing the disk I / O limit performance in a cloud host, which adopts an adaptive differential evolution algorithm to search for an optimal parameter combination, thereby solving the time-consuming and labor-intensive problem caused by manual parameter adjustment in the prior art, solving the problem of low credibility and poor reliability of test results caused by manual parameter adjustment, and realizing fast and accurate testing of the disk I / O limit performance in the cloud host, which is helpful for disk I / O limit performance tuning in the cloud host, file system I / O limit performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc.

[0066] In order to better understand the above technical solution, the above technical solution will be described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0067] Embodiment 1

[0068] This embodiment discloses a method and device for testing disk I / O limit performance in a cloud host. Figure 1 ,include:

[0069] S1: The control node creates the target cloud host population, provided that the computing nodes are in an unloaded state;

[0070] S2: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0071] S3: The control node deletes the target cloud host population.

[0072] In this implementation scheme, through: S1, the control node creates a target cloud host population; S2, the computing node starts the target cloud host population, performs a search operation to obtain the best parameter combination, and measures the disk I / O extreme storage performance based on the best parameter combination; S3, the control node deletes the target cloud host population, thereby achieving rapid testing of the disk I / O extreme storage performance in the cloud host and improving testing efficiency.

[0073] Specifically, the target cloud host population is N p The individuals of the target cloud hosts are the gene combinations of the target cloud hosts, the genes of the target cloud hosts are the numjobs and iodepth parameters of the target cloud hosts, the cloud hosts of the target cloud host population are in the same network segment, the size and type of the disks mounted by the cloud hosts are consistent, and they are connected to each other through ssh;

[0074] The control node is node 0, which is responsible for controlling the remaining nodes, including the creation and deletion of the target cloud host;

[0075] The computing node is responsible for the operation of the target cloud host.

[0076] Specifically, the specific execution steps of S2 are as follows:

[0077] S31: Execute the Fio command on the target cloud host No. 0, and observe the time it takes for IOPS and BW to stabilize in real time to determine the parameters runtime and ramp_time, which will be used in subsequent disk I / O storage performance tests;

[0078] S32: performing a search operation in the target cloud host population according to the differential evolution algorithm, returning the best parameter combination, and outputting the maximum IOPS and bandwidth, where the IOPS and BW are important indicators for measuring disk I / O storage performance.

[0079] In this implementation, a differential evolution algorithm is used to search for the best parameter combination. The differential evolution algorithm has the characteristics of simple structure, easy implementation, fast convergence, and strong robustness. It is the fastest proven evolutionary algorithm and effectively solves the problem of low credibility and poor reliability of test results caused by manual parameter adjustment, thereby achieving accurate testing of the disk I / O extreme storage performance in the cloud host and improving the reliability of the results.

[0080] Specifically, Fio is an open source I / O stress testing tool that is mainly used to test the I / O storage performance of disks or file systems;

[0081] IOPS refers to the number of I / O requests that a system can process per unit time, and is a key indicator of performance for applications with frequent random reads and writes.

[0082] The BW refers to the amount of data that can be successfully transmitted per unit time, and is a performance concern for a large number of sequential read and write applications.

[0083] In this implementation scheme, the two parameters of Fio, numjobs and iodepth, have a great impact on the performance indicators IOPS and BW. Different parameter combinations will result in different IOPS and BW, such as Figure 2 and 3 The experimental results are shown in the case of bs=4k in the cloud host. Figure 2 and 3 The IOPS and BW under different numjobs and iodepth combinations are shown respectively. The iodepth value is all even numbers between 2 and 128 (only some are shown in the figure), and the numjobs value is 1 to 96 (96 is the maximum number of available logical CPUs). There are 6144 combinations in total. Among these combinations, the maximum IOPS is greater than 180,000, while the minimum IOPS is less than 60,000. The maximum BW can reach 800 MiB / s, and the minimum BW is less than 450 MiB / s. It can be seen that different numjobs and iodepth combinations lead to significant differences in the final IOPS and BW. The best parameter combination can achieve the maximum IOPS and BW.

[0084] Specifically, the specific execution steps of S32 are as follows:

[0085] S51: Initialization operation, determine the boundary formula, execute the test script on the control node, and obtain N through the initialization formula p individuals, and then 1~N pIndividuals are embedded into the Fio command to obtain N p command, N p The commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to the control node to get Ω(x i (0));

[0086] S52: mutation operation, generating the g-th generation mutant population through the mutation formula on the control node. If the gene of the mutant individual does not meet the boundary requirements, the gene is regenerated through the initialization formula;

[0087] S53: Crossover operation, generate the population after the g-th generation crossover through the crossover formula on the control node, and get N p mutant individuals, N p The mutant individuals are embedded into the Fio command to obtain N p Test commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to cloud host 0 and get Ω(u i (g));

[0088] S54: selection operation, selecting individuals in the g+1 generation population through the selection formula on the control node, and judging whether to terminate the search according to the judgment formula. If the search is terminated, execute S55, otherwise return to S52, and re-execute S52 to S54 for the g+1 generation in sequence;

[0089] S55: Returns the best parameter combination and outputs the maximum IOPS and bandwidth;

[0090] S56: For the four modes of read, write, randread, and randwrite, the above steps S51-S55 are executed in sequence to obtain the disk I / O extreme storage performance in the cloud host according to the output maximum IOPS and bandwidth.

[0091] In this implementation, a differential evolution algorithm is used to search for the best parameter combination under four different modes, which enables fast and accurate testing of the disk I / O extreme storage performance in the cloud host, which is helpful for disk I / O extreme performance tuning in the cloud host, file system I / O extreme performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc.

[0092] Specifically, the boundary formula in S51 is:

[0093] Definition N pThe target cloud host, the genes of the target cloud host are the numjobs and iodepth parameters of the target cloud host, numjobs and iodepth are replaced by x, denoted as x i,j (g), g is the number of generations of the population;

[0094] The individual of the target cloud host is the gene combination of the target cloud host, denoted by x i (g) = (x i,1 (g),x i,2 (g))=(iodepth i (g),numjobs i (g));

[0095] The target cloud host population is N p The individuals of the target cloud host are recorded as

[0096] Define the upper and lower limits of iodepth and numjobs as x respectively L and x U , that is, x L =(iodepth L ,numjobs L ), x U =(iodepth U ,numjobs U ), then any individual in any generation satisfies the boundary formula, which is:

[0097] x L ≤x i (g)≤x U (1)

[0098] For the initial population, g = 0, the individuals in the population are in [x L ,x U ] is randomly generated, and the initialization formula is:

[0099]

[0100] In the formula, j=1,2, rand(0,1) represents a random number uniformly distributed in the interval (0,1), and [f] represents rounding f to an integer.

[0101] Specifically, the variation formula in S52 includes a stretching formula and a scaling formula;

[0102] The individual mutation is achieved through the differential strategy. The vector difference is scaled and changed through the scaling formula, and then the vector is synthesized with the individual to be mutated to obtain the mutant individual. The scaling formula is:

[0103]

[0104] Wherein, i≠r1≠r2≠r3, F is a scaling factor, and an adaptive scaling factor is selected according to a scaling formula, wherein the scaling formula is:

[0105]

[0106] In the formula, G m is the maximum evolutionary generation, and F0 is the initial value of the scaling factor. Adaptive scaling factors are used to maintain individual diversity in the early stage, and to retain excellent information when the mutation rate is close to F0 in the later stage to avoid the destruction of the optimal solution, thereby increasing the global search capability of the algorithm.

[0107] Specifically, the crossover formula in S53 includes a genetic formula and a probability formula;

[0108] The crossover operation is performed on the g-th generation population X(g) and the mutant population V(g) generated by the mutation operation according to the gene formula to obtain the crossover population U(g). i,j (g) determine the following:

[0109]

[0110] Where CR is the crossover probability, j rand is a random integer between 1 and 2. CR determines the degree to which the mutant individuals enter the crossover population. The mean of CR is kept at 0.75 through the probability formula to maintain population diversity:

[0111] CR = 0.5·(1+rand(0,1)).

[0112] Specifically, the selection formula and the judgment formula in S54 are:

[0113] Define parameter combination x i The performance indicator (IOPS or BW) measured in Fio is Ω(x i ), then the g+1th generation individuals are determined according to the selection formula:

[0114]

[0115] Define the maximum evolutionary generation as G m , the best performance index tested by the g-th generation population is Ω m (g) Stop searching when the judgment formula is met:

[0116] g>G m or|Ω m (g+1)-Ω m (g)|≤ε

[0117] Where ε is the stability threshold.

[0118] A disk I / O limit performance testing device in a cloud host, comprising:

[0119] Creation module: Controls the node to create the target cloud host population;

[0120] Testing module: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0121] Deletion module: The control node deletes the target cloud host population.

[0122] In this embodiment, a test device for obtaining disk I / O limit IOPS and BW in a cloud host is provided, which has the advantages of good portability and ease of use.

[0123] Embodiment 2

[0124] In order to help better understand the technical solution of the present invention, Figure 4 and Figure 5 Taking an exclusive cloud host (2 CPU cores and 4 GB memory, 2C4G) as an example, the technical solution of the present invention is further explained. Figure 4 For the device swimlane diagram, Figure 5 This is a diagram of the device framework.

[0125] Specifically, it includes:

[0126] S1: The control node creates the target cloud host population, provided that the computing nodes are in an unloaded state;

[0127] S2: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0128] S3: The control node deletes the target cloud host population.

[0129] In this implementation, the total number of groups N p Generally, 5D to 10D is selected, where D is the number of genes in the chromosome. In this patent, the genes are iodepth and numjobs, and D is 2. In order to enrich the diversity of the population, N p =20;

[0130] As mentioned above, creating 21 2C4G cloud hosts requires a total of 42C84G resources. Select computing nodes with available resources that meet the requirements and check whether the computing nodes are idle. If there are other application processes that occupy a large number of resources, kill them first to eliminate interference with storage performance testing.

[0131] Create a vpc of appropriate size on the control node, create a subnet of appropriate size in the vpc, and create 21 ports; create 21 target cloud hosts on the control node through the 21 ports, so that the network between the 21 target cloud hosts can be guaranteed, and mount disks of the same size and type to the 21 target cloud hosts. Number the 21 target cloud hosts, with cloud host No. 0 as the client and the other 20 cloud hosts as the server.

[0132] Specifically, the specific execution steps of S2 are as follows:

[0133] S31: Execute the Fio command on the target cloud host No. 0, and observe the time it takes for IOPS and BW to stabilize in real time to determine the parameters runtime and ramp_time, which will be used in subsequent disk I / O storage performance tests;

[0134] S32: performing a search operation in the target cloud host population according to the differential evolution algorithm, returning the best parameter combination, and outputting the maximum IOPS and bandwidth, where the IOPS and bandwidth are important indicators for measuring disk I / O storage performance.

[0135] In this implementation scheme, before executing the Fio command on the target cloud host No. 0, the parameters need to be written to the configuration file, and the parameters include:

[0136] The lower limit of iodepth is 2, and the upper limit is greater than or equal to the queue_depth value viewed through the lsscsi -l command. The lower limit of numjobs is 1, and the upper limit is the number of logical CPUs viewed through the lscpu command.

[0137] The crossover probability CR has a great influence on the convergence speed of the algorithm. The CR value of each generation is determined by the probability formula;

[0138] The scaling factor F determines the magnification ratio of the differential vector, and is generally set to (0.4, 1]. Usually, a good effect can be achieved when F0 is 0.5.

[0139] Maximum evolutionary generation G m The stability threshold ε determines the termination condition of the search; the maximum evolutionary number is generally in the range of [100,200]. In fact, the DE algorithm converges quickly, so the value is 100; when measuring IOPS, the stability threshold ε is 100, and when measuring BW, the value is 10.

[0140] Specifically, the specific execution steps of S32 are as follows:

[0141] S51: Execute the script T containing the DE algorithm in the cloud host No. 0, initialize 20 individuals through the initialization formula, that is, obtain 20 parameter combinations, embed the 1-20 parameter combinations into the Fio command to obtain 20 commands, and transmit them to the cloud hosts No. 1-20 through ssh for execution, and wait for the return results in the cloud host No. 0; after the execution of the Fio command in the cloud hosts No. 1-20 is completed, the 20 results are ssh-ed back to the cloud host No. 0 in turn to obtain Ω(x i (0)), i = 1, 2, ..., 20;

[0142] S52: Generate the g-th generation mutant population in cloud host No. 0 through the mutation formula. If the gene of the mutant individual does not meet the requirements, the gene needs to be regenerated through the initialization formula;

[0143] S53: In cloud host No. 0, a population after crossover of the gth generation is generated by the crossover formula, and 20 mutant individuals (parameter combinations) are obtained. Similarly, the 20 parameter combinations are embedded in the Fio command to obtain 20 test commands, which are respectively transmitted to cloud hosts No. 1 to No. 20 through ssh for execution; after the execution of the Fio command in cloud hosts No. 1 to No. 20 is completed, the 20 results are ssh-ed back to cloud host No. 0 to obtain Ωu i (g)), i = 1, 2, ..., 20;

[0144] S54: In cloud host No. 0, select an individual in the g+1 generation population by using the selection formula, and determine whether to terminate the search according to the judgment formula; if the condition is met, jump to S55, otherwise return to S52, and re-execute S52 to S54 for the g+1 generation;

[0145] S55: Returns the best parameter combination and outputs the maximum IOPS and bandwidth;

[0146] S56: For the four modes of read, write, randread, and randwrite, the above steps S51-S55 are executed in sequence to obtain the disk I / O extreme storage performance in the cloud host according to the output maximum IOPS and bandwidth.

[0147] A disk I / O limit performance test device in a cloud host, such as Figure 5 ,include:

[0148] Creation module: Controls the node to create the target cloud host population;

[0149] Testing module: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain an optimal parameter combination, and the disk I / O limit storage performance is measured according to the optimal parameter combination;

[0150] Deletion module: The control node deletes the target cloud host population, uninstalls the disk, deletes the virtual machine, deletes the port, deletes the subnet, deletes the vpc, and restores the state before the test.

[0151] In this embodiment, Figure 4 For the device swimlane diagram, Figure 5 This is a framework diagram of the entire device. Figure 4 In the example, the virtual machine is the target cloud host. Figure 5 In the figure, the dotted line A indicates that the control node creates and deletes cloud hosts on the computing node; the solid line B indicates that cloud host 0 sends the fio command to cloud hosts 1 to 20 through ssh; the solid line C indicates that the current IOPS or BW is returned through ssh after the test is completed in cloud hosts 1 to 20.

[0152] As a revolution in the field of computer networks, cloud computing is profoundly changing the way society works and the business model. Computing, storage, network, and security are four important components of cloud computing. In order to measure the storage performance in cloud computing, the usual practice is to use mainstream testing tools such as Fio and iometer to perform read and write tests on disks or file systems. Fio is an open source I / O stress testing tool that is mainly used to test the I / O performance of disks or file systems. It is simple and easy to use. However, in actual project applications, we found that the two parameters of Fio, numjobs and iodepth, have a great impact on the performance indicators IOPS and BW. Different parameter combinations will result in different IOPS and BW. It is not easy to obtain the best parameter combination. On the one hand, if you rely on manual parameter adjustment, you need to repeat hundreds or thousands of times, which will consume a lot of time and energy; on the other hand, the best parameter combination is different in different scenarios, and the accumulated experience may not be applicable. The measured IOPS and BW are likely to be local maximum values, rather than global maximum IOPS and BW, resulting in low credibility and poor reliability of the test results. In view of the deficiencies in the prior art, the present invention provides a method and device for testing the disk I / O limit performance in a cloud host, which adopts an adaptive differential evolution algorithm to search for the best parameter combination under four different modes, effectively solving the time-consuming and labor-intensive problems caused by manual parameter adjustment and the low credibility and poor reliability of the test results caused by manual parameter adjustment, thereby realizing rapid and accurate testing of the disk I / O limit storage performance in the cloud host, improving the test efficiency, and improving the reliability of the results, which is helpful for disk I / O limit performance tuning, file system I / O limit performance testing and performance tuning, performance loss analysis, storage virtualization tuning, etc. in the cloud host.

[0153] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0154] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0155] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0156] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

Claims

1. A method for testing disk I / O limit performance in a cloud host, characterized in that: The method is carried out according to the following steps: S1: Control node creates the target cloud host population; S2: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain the best parameter combination, and the disk I / O limit storage performance is measured according to the best parameter combination; wherein the specific execution steps of S2 are as follows: S31: Execute the Fio command on the target cloud host No. 0, and observe the time for IOPS and BW to stabilize in real time to determine the parameters runtime and ramp_time, which are used in subsequent disk I / O storage performance tests; S32: Perform a search operation in the target cloud host population according to the differential evolution algorithm, return the best parameter combination, and output the maximum IOPS and bandwidth, wherein the IOPS and bandwidth are important indicators for measuring disk I / O storage performance; S3: The control node deletes the target cloud host population.

2. A method for testing disk I / O limit performance in a cloud host according to claim 1, characterized in that: The target cloud host population is N p The individuals of the target cloud hosts are the gene combinations of the target cloud hosts, the genes of the target cloud hosts are the numjobs and iodepth parameters of the target cloud hosts, the cloud hosts of the target cloud host population are in the same network segment, the size and type of the disks mounted by the cloud hosts are consistent, and they are connected to each other through ssh; The control node is node 0, which is responsible for controlling the remaining nodes, including the creation and deletion of the target cloud host; The computing node is responsible for the operation of the target cloud host.

3. A method for testing disk I / O limit performance in a cloud host according to claim 1, characterized in that: Fio is an open source I / O stress testing tool, mainly used to test the I / O storage performance of a disk or file system; IOPS refers to the number of I / O requests that a system can process per unit time, and is a key indicator of performance for applications with frequent random reads and writes. The bandwidth refers to the amount of data that can be successfully transmitted per unit time, and is a performance concern for a large number of sequential read and write applications.

4. A method for testing disk I / O limit performance in a cloud host according to claim 1, characterized in that: The specific execution steps of S32 are as follows: S51: Initialization operation, determine the boundary formula, execute the test script on the control node, and obtain N through the initialization formula p individuals, and then 1~N p Individuals are embedded into the Fio command to obtain N p command, N p The commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to the control node to get Ω(x i (0)); where the parameter combination x is defined i The performance indicator IOPS or BW measured in Fio is Ω(x i ) S52: mutation operation, generating the g-th generation mutant population through the mutation formula on the control node. If the gene of the mutant individual does not meet the boundary requirements, the gene is regenerated through the initialization formula; S53: Crossover operation, generate the population after the g-th generation crossover through the crossover formula on the control node, and get N p mutant individuals, N p The mutant individuals are embedded into the Fio command to obtain N p Test commands are sent to 1~N via ssh p After the execution is completed, N p The result is ssh back to cloud host 0 and get Ω(u i (g)); S54: selection operation, selecting individuals in the g+1 generation population through the selection formula on the control node, and judging whether to terminate the search according to the judgment formula. If the search is terminated, execute S55, otherwise return to S52, and re-execute S52 to S54 for the g+1 generation in sequence; S55: Returns the best parameter combination and outputs the maximum IOPS and bandwidth; S56: For the four modes of read, write, randread, and randwrite, the above steps S51-S55 are executed in sequence to obtain the disk I / O extreme storage performance in the cloud host according to the output maximum IOPS and bandwidth.

5. A method for testing disk I / O limit performance in a cloud host as claimed in claim 4, characterized in that: The boundary formula in S51 is: Definition N p The target cloud host, the genes of the target cloud host are the numjobs and iodepth parameters of the target cloud host, numjobs and iodepth are replaced by x, denoted as x i,j (g), g is the number of generations of the population; The individual of the target cloud host is the gene combination of the target cloud host, denoted by x i (g) = (x i,1 (g),x i,2 (g))=(iodepth i (g),numjobs i (g)); The target cloud host population is N p The individual of the target cloud host is recorded as X(g)=(x1(g),x2(g),...,x Np (g)); Define the upper and lower limits of iodepth and numjobs as x respectively L and x U , that is, x L =(iodepth L ,numjobs L ), x U =(iodepth U ,numjobs U ), then any individual in any generation satisfies the boundary formula, which is: x L ≤x i (g)≤x U (1) For the initial population, g = 0, the individuals in the population are is randomly generated, and the initialization formula is: In the formula, j=1,2, rand(0,1) represents a random number uniformly distributed in the interval (0,1), and [f] represents rounding f to an integer.

6. A method for testing disk I / O limit performance in a cloud host as claimed in claim 4, characterized in that: The variation formula in S52 includes a stretching formula and a scaling formula; The individual mutation is achieved through the differential strategy. The vector difference is scaled and changed through the scaling formula, and then the vector is synthesized with the individual to be mutated to obtain the mutant individual. The scaling formula is: Wherein, i≠r1≠r2≠r3, F is a scaling factor, and an adaptive scaling factor is selected according to a scaling formula, wherein the scaling formula is: In the formula, G m is the maximum evolutionary generation, F0 is the initial value of the scaling factor, and an adaptive scaling factor is used to maintain individual diversity in the early stage. When the mutation rate is close to F0 in the later stage, good information is retained to avoid the destruction of the optimal solution, thereby increasing the global search capability of the algorithm.

7. A method for testing disk I / O limit performance in a cloud host as claimed in claim 4, characterized in that: The crossover formula in S53 includes a gene formula and a probability formula; The crossover operation is performed on the g-th generation population X(g) and the mutant population V(g) generated by the mutation operation according to the gene formula to obtain the crossover population U(g). i,j (g) determine the following: Where CR is the crossover probability, j rand is a random integer between 1 and 2. CR determines the degree to which the mutant individuals enter the crossover population. The mean of CR is maintained at 0.75 through the probability formula to maintain population diversity: CR = 0.5·(1+rand(0,1)).

8. A method for testing disk I / O limit performance in a cloud host as claimed in claim 4, characterized in that: The selection formula and judgment formula in S54 are: Define parameter combination x i The performance indicator IOPS or BW measured in Fio is Ω(x i ), then the g+1th generation individuals are determined according to the selection formula: Define the maximum evolutionary generation as G m , the best performance index tested by the g-th generation population is Ω m (g) Stop searching when the judgment formula is met: g>G m or|Ω m (g+1)-Ω m (g)≤ε Where ε is the stability threshold.

9. A disk I / O limit performance testing device in a cloud host, characterized in that: The device comprises: Creation module: Controls the node to create the target cloud host population; Test module: The computing node starts the target cloud host population and performs a search operation, wherein the search operation is used to obtain the best parameter combination, and the disk I / O extreme storage performance is measured according to the best parameter combination; wherein the test module is specifically used for S31: executing the Fio command on the target cloud host No. 0, observing the time for IOPS and BW to stabilize in real time to determine the parameters runtime and ramp_time, and using them in subsequent disk I / O storage performance tests; S32: performing a search operation according to the differential evolution algorithm in the target cloud host population, returning the best parameter combination, and outputting the maximum IOPS and bandwidth, wherein the IOPS and bandwidth are important indicators for measuring disk I / O storage performance; Deletion module: The control node deletes the target cloud host population.