A dynamic management method and device for virtual machine placement

Through the method of dynamically managing virtual machines, the LSTM model is used to predict the value of virtual machine placement parameters and update the weight, which solves the problem of failure to dynamically adjust the virtual machine placement results, and realizes the optimization of virtual machine placement results and the improvement of resource utilization.

CN114138412BActive Publication Date: 2025-04-18STATE GRID SHANGHAI MUNICIPAL ELECTRIC POWER CO +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111437653.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-30
Publication Date
2025-04-18
Estimated Expiration
2041-11-30

AI Technical Summary

Technical Problem

The existing technology fails to dynamically adjust after virtual machines are placed, resulting in poor performance such as physical resource utilization and unsatisfactory results in virtual machines placed.

Method used

By obtaining the historical data of the physical resource utilization rate and minimum response time of the virtual machine population, calculate the fitness function value, obtain the list of virtual machines to be migrated, and use the RNN recurrent neural network in the LSTM model to predict the value of the placement parameters, update the weight, and adjust the list of virtual machines to be migrated to optimize the placement of virtual machines.

Benefits of technology

The optimization of virtual machine placement results is achieved, and the utilization of physical resource and virtual machine performance is improved, so that each virtual machine placement is determined based on the weight of real-time placement parameters, gradually approaching the ideal value.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114138412B_ABST
    Figure CN114138412B_ABST
Patent Text Reader

Abstract

The present invention relates to a dynamic management method and device after virtual machine placement, the method comprising: obtaining historical data of virtual machine physical resource utilization and minimum response time of each individual virtual machine population, and calculating the fitness function value, obtaining a virtual machine migration list according to the fitness function value of the virtual machine population, placing virtual machines according to the virtual machine migration list, and obtaining the actual values ​​of all placement parameters; setting the ideal values ​​of all placement parameters, using the RNN recurrent neural network in the LSTM model to obtain the predicted value of the placement parameter when the virtual machine is placed next time, and obtaining the weight of the placement parameter according to the predicted value and actual value of the placement parameter, obtaining the placement parameter with the largest weight among all placement parameters, and giving priority to placing the virtual machine in the virtual machine migration list with a larger value of the placement parameter. Compared with the prior art, the present invention has the advantages of more accurate placement results and the like.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of virtual machines, and in particular to a method and device for dynamic management of virtual machines after placement. Background Art

[0002] At present, the increasing scale of cloud computing has made it unable to process the exponentially growing data in time; the most fundamental solution is to achieve the optimal solution of virtual machine deployment strategy; currently, constraint programming and genetic algorithms are commonly used to solve the above problems. However, after obtaining the list of virtual machines to be migrated and placing them through genetic algorithms, since the network model relied on by the placement method is not mature, if the virtual machines are always placed according to the first virtual machine placement method obtained without dynamic adjustment, it will lead to poor performance such as physical resource utilization, making the virtual machine placement result unsatisfactory. Summary of the invention

[0003] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and to provide a dynamic management method and device for virtual machines after placement.

[0004] The purpose of the present invention can be achieved by the following technical solutions:

[0005] A method for dynamic management of virtual machines after placement, comprising the following steps:

[0006] S1. Obtain the historical data of the physical resource utilization rate and the minimum response time of each individual virtual machine in the virtual machine population, and calculate the fitness function value, obtain the virtual machine migration list according to the fitness function value of the virtual machine population, place the virtual machine according to the virtual machine migration list, and obtain the actual values ​​of all placement parameters;

[0007] S2. Set the ideal values ​​of all placement parameters, use the RNN recurrent neural network in the LSTM model to obtain the predicted values ​​of the placement parameters for the next virtual machine placement, and obtain the weights of the placement parameters based on the predicted values ​​and actual values ​​of the placement parameters;

[0008] S3. Obtain the placement parameter with the largest weight among all placement parameters, and preferentially place the virtual machines with the largest placement parameter value in the list of virtual machines to be migrated.

[0009] Furthermore, the placement parameters include resource utilization of the physical machine, proportion of virtual machine working time and number of virtual machine migrations.

[0010] Furthermore, the weight calculation expression of the placement parameter is as follows:

[0011] e o (t) = e h (t) = d(t) - y(t)

[0012] W(t + 1) = W(t) + εs(t)e o (t) T

[0013] V(t + 1) = V(t) + εx(t)e h (t) T

[0014] U(t + 1) = U(t) + εs(t - 1)e h (t) T

[0015] Wherein, W represents the weight of the resource utilization rate of the physical machine, V represents the weight of the virtual machine working time ratio, U represents the weight of the virtual machine migration times, ε represents the model learning rate, T represents the time unit, s(t) represents the output of the hidden layer of the current dynamic management RNN recurrent neural network, x(t) represents the output of the input layer of the RNN recurrent neural network, and t represents the number of dynamic management times; e o (t) represents the error of the input layer, and e h (t) represents the error of the hidden layer, and the two are the same numerically; d(t) represents the predicted values of the three parameters, and y(t) represents the actual values of the three parameters.

[0016] Further, the calculation expression for obtaining the fitness function value of the virtual machine population is:

[0017]

[0018] Wherein, p represents the historical data of the physical resource utilization rate of each virtual machine, t represents the minimum response time of each virtual machine, and β1 and β2 are the weights of p and t respectively, and the set values are both 0.5.

[0019] Further, the method for obtaining the virtual machine to-be-migrated list in step S1 includes:

[0020] Select k (k < N) individuals from the N virtual machine individuals in the virtual machine population, and according to the fitness function values of each selected individual, select the individual with the lowest fitness function value to enter the virtual machine to-be-migrated list;

[0021] Repeat the above steps until there are N virtual machine individuals in the virtual machine to-be-migrated list.

[0022] A dynamic management device after virtual machine placement, including a memory and a processor; the memory is used to store a computer program; the processor is used to implement the following method when executing the computer program:

[0023] S1. Obtain the historical data of the physical resource utilization rate and the minimum response time of each individual virtual machine in the virtual machine population, and calculate the fitness function value, obtain the virtual machine migration list according to the fitness function value of the virtual machine population, place the virtual machine according to the virtual machine migration list, and obtain the actual values ​​of all placement parameters;

[0024] S2. Set the ideal values ​​of all placement parameters, use the RNN recurrent neural network in the LSTM model to obtain the predicted values ​​of the placement parameters for the next virtual machine placement, and obtain the weights of the placement parameters based on the predicted values ​​and actual values ​​of the placement parameters;

[0025] S3. Obtain the placement parameter with the largest weight among all placement parameters, and preferentially place the virtual machines with the largest placement parameter value in the list of virtual machines to be migrated.

[0026] Furthermore, the placement parameters include resource utilization of the physical machine, proportion of virtual machine working time and number of virtual machine migrations.

[0027] Furthermore, the weight calculation expression of the placement parameter is as follows:

[0028] e o (t) = e h (t) = d(t) - y(t)

[0029] W(t+1)=W(t)+εs(t)e o (t) T

[0030] V(t+1)=V(t)+εx(t)e h (t) T

[0031] U(t+1)=U(t)+εs(t-1)e h (t) T

[0032] In the formula, W represents the weight of the resource utilization rate of the physical machine, V represents the weight of the proportion of virtual machine working time, U represents the weight of the number of virtual machine migrations, ε represents the model learning rate, T represents the time unit, s(t) represents the output of the hidden layer of the RNN recurrent neural network in this dynamic management, x(t) represents the output of the input layer of the RNN recurrent neural network, and t represents the number of dynamic management; e o (t) represents the error of the input layer, e h (t) represents the error of the hidden layer, and the two are numerically the same; d(t) represents the predicted values ​​of the three parameters, and y(t) represents the actual values ​​of the three parameters.

[0033] Furthermore, the calculation expression for obtaining the fitness function value of the virtual machine population is:

[0034]

[0035] Wherein, p represents the historical data of the physical resource utilization rate of each virtual machine, t represents the minimum response time of each virtual machine, and β1 and β2 are the weights of p and t respectively, and the set values are both 0.5.

[0036] Furthermore, the method for obtaining the virtual machine to-be-migrated list in step S1 includes:

[0037] Select k (k < N) individuals from the N virtual machine individuals in the virtual machine population. According to the fitness function values of each selected individual, select the individual with the lowest fitness function value to enter the virtual machine to-be-migrated list until there are N virtual machine individuals in the virtual machine to-be-migrated list.

[0038] Compared with the prior art, the present invention has the following advantages:

[0039] 1. The present invention uses a dynamic management method after virtual machine placement. The placement parameters of the virtual machine are predicted through the LSTM network, and combined with the actual values of the placement parameters, the weights of the placement parameters are updated, thereby adjusting the virtual machine to-be-migrated list, so that each placement of the virtual machine is determined according to the weights of the specific real-time placement parameters. After each placement, the values of the placement parameters of the virtual machine will gradually approach the set ideal values, optimizing the placement results of the virtual machine.

[0040] 2. The present invention uses the input layer, hidden layer and output layer of the RNN recurrent neural network to calculate the weights of different placement parameters, making the correlation between each dynamic management stronger. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 It is a schematic diagram of the method of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0042] The present invention will be described in detail below with reference to the drawings and specific embodiments. This embodiment is implemented on the premise of the technical solution of the present invention, and gives the detailed implementation manners and specific operation processes, but the protection scope of the present invention is not limited to the following embodiments.

[0043] This embodiment proposes a dynamic management method after virtual machine placement, and the process is as Figure 1 shown, specifically including the following steps:

[0044] Step S1: Obtain the historical data of the physical resource utilization rate of each individual in the virtual machine population and the minimum response time, and calculate the fitness function value. The calculation method is as follows:

[0045]

[0046] In the formula, p represents the historical data of the physical resource utilization rate of each virtual machine, t represents the minimum response time of each virtual machine, and β1 and β2 are the weights of p and t respectively, and the set values are both 0.5.

[0047] Obtain the virtual machine migration list according to the fitness function value of the virtual machine population. Assume that the size of the virtual machine population is N. Select k (k < N) individuals from the N virtual machine individuals in the virtual machine population. According to the fitness function value of each selected individual, select the individual with the smallest fitness function value to enter the virtual machine migration list until there are N virtual machine individuals in the virtual machine migration list.

[0048] Place the virtual machines according to the virtual machine migration list, and obtain the actual values of the resource utilization rate, virtual machine working time ratio, and virtual machine migration times of all physical machines.

[0049] Among them, the resource utilization rate of the physical machine can be described as follows. After the i-th virtual machine is placed on the j-th physical host, the resource utilization rate of the physical machine can be calculated through the following calculation expression:

[0050]

[0051] In the formula, y ij represents the decision variable, represents the demand capacity of the virtual machine for the processor, represents the demand capacity of the virtual machine for memory, represents the demand capacity of the virtual machine for network bandwidth, represents the size of the processor of the physical machine, represents the available memory size of the physical machine, represents the size of the network bandwidth owned by the physical machine.

[0052] Step S2: Combine the long short-term prediction LSTM model to adjust the above placement parameters. First, set the ideal values of the resource utilization rate, virtual machine working time ratio, and virtual machine migration times of all physical machines as the optimization objectives of the model. Input the actual values into the three neurons of the RNN recurrent neural network in the LSTM model to obtain the predicted values of the placement parameters for the next virtual machine placement, and use the BPTT time backpropagation method to obtain the weights of the placement parameters according to the predicted values and actual values of the placement parameters. The specific calculation process is as follows:

[0053] e o (t) = e h (t) = d(t) - y(t)

[0054] W(t + 1) = W(t) + εs(t)eo (t) T

[0055] V(t+1)=V(t)+εx(t)e h (t) T

[0056] U(t+1)=U(t)+εs(t-1)e h (t) T

[0057] In the formula, W represents the weight of the resource utilization rate of the physical machine, V represents the weight of the proportion of virtual machine working time, U represents the weight of the number of virtual machine migrations, ε represents the model learning rate, T represents the time unit, s(t) represents the output of the hidden layer of the RNN recurrent neural network in this dynamic management, x(t) represents the output of the input layer of the RNN recurrent neural network, and t represents the number of dynamic management; e o (t) represents the error of the input layer, e h (t) represents the error of the hidden layer, and the two are numerically the same; d(t) represents the predicted values ​​of the three parameters, and y(t) represents the actual values ​​of the three parameters.

[0058] Step S3: According to the different weights of the resource utilization rate of the physical machine, the proportion of the virtual machine working time and the number of virtual machine migrations, select the placement parameter with the largest weight, sort the virtual machines in the virtual machine migration list according to the size of the placement parameter, adjust the virtual machine migration list, and place the virtual machine.

[0059] Repeat steps S1 to S3, where the historical data of physical resource utilization used to calculate the fitness function value again is the historical data obtained in the previous calculation. This makes the actual values ​​of each physical machine resource utilization, virtual machine working time ratio and virtual machine migration times closer to the ideal values, that is, the most effective virtual machine placement strategy is achieved.

[0060] This embodiment also proposes a dynamic management device for a virtual machine after placement, including a memory and a processor; the memory is used to store a computer program; the processor is used to implement a dynamic management method for a virtual machine after placement mentioned in the above embodiment when executing the computer program.

[0061] This embodiment further proposes a computer-readable storage medium, on which a computer program is stored. When the program is executed by the processor, a dynamic management method after a virtual machine is placed as mentioned in the embodiment of the present invention can be implemented, and any combination of one or more computer-readable media can be used. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, - but not limited to - an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media (a non-exhaustive list) include: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this document, a computer-readable storage medium can be any tangible medium containing or storing a program, which can be used by an instruction execution system, device or device or used in combination with it.

[0062] The preferred specific embodiments of the present invention are described in detail above. It should be understood that a person skilled in the art can make many modifications and changes based on the concept of the present invention without creative work. Therefore, any technical solution that can be obtained by a person skilled in the art through logical analysis, reasoning or limited experiments based on the concept of the present invention on the basis of the prior art should be within the scope of protection determined by the claims.

Claims

1. A method for dynamic management of virtual machines after placement, characterized in that: It includes the following steps: S1. Obtain the historical data of the virtual machine physical resource utilization rate and the minimum response time of each individual in the virtual machine population, calculate the fitness function value, obtain the virtual machine migration list to be migrated according to the fitness function value of the virtual machine population, place the virtual machines according to the virtual machine migration list to be migrated, and obtain the actual values of all placement parameters; S2. Set the ideal values of all placement parameters, use the RNN recurrent neural network in the LSTM model to obtain the predicted values of the placement parameters for the next virtual machine placement, and obtain the weights of the placement parameters according to the predicted values and the actual values of the placement parameters; S3. Obtain the placement parameter with the largest weight among all placement parameters, and preferentially place the virtual machines with larger values of this placement parameter in the virtual machine migration list to be migrated; The placement parameters include the resource utilization rate of the physical machine, the virtual machine working time ratio, and the virtual machine migration times; The calculation expression for the weight of the placement parameter is as follows: e o (t)=e h (t)=d(t)-y(t) W(t+1)=W(t)+εs(t)e o (t) T V(t+1)=V(t)+εx(t)e h (t) T U(t+1)=U(t)+εs(t-1)e h (t) T Where W represents the weight of the resource utilization of the physical machine, V represents the weight of the proportion of virtual machine working time, U represents the weight of the number of virtual machine migrations, ε represents the model learning rate, s(t) represents the output of the hidden layer of the RNN recurrent neural network in this dynamic management, x(t) represents the output of the input layer of the RNN recurrent neural network, and t represents the number of dynamic management times; e o (t) represents the error of the input layer, e h (t) represents the error of the hidden layer, and the two are numerically the same; d(t) represents the predicted values ​​of the three parameters, and y(t) represents the actual values ​​of the three parameters; The calculation expression for obtaining the fitness function value of the virtual machine population is: In the formula, p represents the historical data of the virtual machine physical resource utilization rate of each virtual machine, T′ represents the time unit, t represents the minimum response time of each virtual machine, and β1 and β2 are the weights of p and t respectively, and the set values are both 0.

5.

2. A method for dynamic management of virtual machines after placement according to claim 1, characterized in that: The method for obtaining the virtual machine migration list to be migrated in step S1 includes: Select k (k < N) individuals from the N virtual machine individuals in the virtual machine population, and according to the fitness function value of each selected individual, select the individual with the lowest fitness function value to enter the virtual machine migration list to be migrated; Repeat the above steps until there are N virtual machine individuals in the virtual machine migration list to be migrated.

3. A dynamic management device for virtual machines after placement, characterized in that: It includes a memory and a processor; the memory is used to store a computer program; the processor is used to implement the following method when executing the computer program: S1. Obtain the historical data of the virtual machine physical resource utilization rate and the minimum response time of each individual in the virtual machine population, calculate the fitness function value, obtain the virtual machine migration list to be migrated according to the fitness function value of the virtual machine population, place the virtual machines according to the virtual machine migration list to be migrated, and obtain the actual values of all placement parameters; S2. Set the ideal values of all placement parameters, use the RNN recurrent neural network in the LSTM model to obtain the predicted values of the placement parameters for the next virtual machine placement, and obtain the weights of the placement parameters according to the predicted values and the actual values of the placement parameters; S3. Obtain the placement parameter with the largest weight among all placement parameters, and preferentially place the virtual machines with larger values of this placement parameter in the virtual machine migration list to be migrated; The placement parameters include the resource utilization rate of the physical machine, the virtual machine working time ratio, and the virtual machine migration times; The calculation expression for the weight of the placement parameter is as follows: e o (t)=e h (t)=d(t)-y(t) W(t+1)=W(t)+εs(t)e o (t) T V(t+1)=V(t)+εx(t)e h (t) T U(t+1)=U(t)+εs(t-1)e h (t) T Where W represents the weight of the resource utilization of the physical machine, V represents the weight of the proportion of virtual machine working time, U represents the weight of the number of virtual machine migrations, ε represents the model learning rate, s(t) represents the output of the hidden layer of the RNN recurrent neural network in this dynamic management, x(t) represents the output of the input layer of the RNN recurrent neural network, and t represents the number of dynamic management times; e o (t) represents the error of the input layer, e h (t) represents the error of the hidden layer, and the two are numerically the same; d(t) represents the predicted values ​​of the three parameters, and y(t) represents the actual values ​​of the three parameters; The calculation expression for obtaining the fitness function value of the virtual machine population is: In the formula, p represents the historical data of the virtual machine physical resource utilization rate of each virtual machine, T′ represents the time unit, t represents the minimum response time of each virtual machine, and β1 and β2 are the weights of p and t respectively, and the set values are both 0.

5.

4. The dynamic management device after virtual machine placement according to claim 3, characterized in that: The method for obtaining the virtual machine migration list to be migrated in step S1 includes: Select k (k < N) individuals from the N virtual machine individuals in the virtual machine population. According to the fitness function values of each selected individual, select the individual with the lowest fitness function value to enter the virtual machine migration pending list until there are N virtual machine individuals in the virtual machine migration pending list.

Citation Information

Patent Citations

  • Particle swarm algorithm-based virtual-machine deployment method under cloud environment

    CN108469983A

  • Virtual machine thermal migration method, device and equipment

    CN110928636A