CN104866375B - A kind of method and device for migrating virtual machine - Google Patents

A kind of method and device for migrating virtual machine Download PDF

Info

Publication number
CN104866375B
CN104866375B CN201510267151.8A CN201510267151A CN104866375B CN 104866375 B CN104866375 B CN 104866375B CN 201510267151 A CN201510267151 A CN 201510267151A CN 104866375 B CN104866375 B CN 104866375B
Authority
CN
China
Prior art keywords
virtual machine
resource utilization
physical server
migrated
physical
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201510267151.8A
Other languages
Chinese (zh)
Other versions
CN104866375A (en
Inventor
殷波
王志军
冯伟斌
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN201510267151.8A priority Critical patent/CN104866375B/en
Publication of CN104866375A publication Critical patent/CN104866375A/en
Application granted granted Critical
Publication of CN104866375B publication Critical patent/CN104866375B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The embodiment of the invention discloses a kind of method and device for migrating virtual machine, it is related to field of communication technology, in the case of can be in resource set, solving the problems, such as the virtual machine of task produced by same application is performed in cloud computation data center, to carry out data transmission shared resource after migration high.The method of the embodiment of the present invention includes:When the resource utilization of the physical server of acquisition is more than the resource utilization upper limit, all virtual machines are divided at least one virtual machine set;According to the resource utilization of each virtual machine at least one virtual machine set, the virtual machine to be migrated on physical server is determined, until the sum of resource utilization of all virtual machines on physical server in addition to virtual machine to be migrated is less than or equal to the resource utilization upper limit;According to the migration bandwidth of acquisition, other the single physical servers of the virtual machine (vm) migration of same virtual machine set extremely in addition to physical server will be belonged in virtual machine to be migrated.The present invention is suitable for cloud computation data center.

Description

A kind of method and device for migrating virtual machine
Technical field
The present invention relates to field of communication technology, more particularly to a kind of method and device for migrating virtual machine.
Background technology
With the popularization of the development of the communication technology, especially virtualization technology, cloud computation data center is usually using virtual Machine performs task.In practical applications, in order to save the energy consumption of cloud computation data center, the side of virtual machine (vm) migration can be passed through Method realized in the resource set of cloud computation data center, that is, virtual machine concentrated and is migrated to holding on a small number of physical servers The task of row cloud computation data center, while the physical server for having moved sky virtual machine is closed.
In practical applications, need to carry out data biography between multiple virtual machines of task produced by performing same application It is defeated.Also, the transmission range between virtual machine is more remote, shared resource is more during data transfer.For reality In existing resource set, in the transition process of virtual machine, it is understood that there may be the virtual machine of task produced by multiple same applications of execution Multiple and different physical servers is migrated to, and the transmission range between this multiple and different physical server is farther out.Therefore, adopt With above-mentioned moving method, although can realize in resource set, the energy consumption of cloud computation data center is reduced, it is same to be the increase in execution The virtual machine of task produced by one application carries out data transmission shared resource after migration.
The content of the invention
The embodiment of the present invention provide it is a kind of migrate virtual machine method and device, can be in resource set in the case of, solution The virtual machine of task produced by same application is certainly performed in cloud computation data center carries out data transmission shared after migration Resource it is high the problem of.
To reach above-mentioned purpose, the embodiment of the present invention adopts the following technical scheme that:
In a first aspect, the embodiment of the present invention provides a kind of method for migrating virtual machine, the described method includes:
Obtain the resource utilization of physical server;
When the resource utilization of the physical server is more than the resource utilization upper limit of the physical server, by institute State all virtual machines on physical server and be divided at least one virtual machine set, wherein, it is all in single virtual machine set Virtual machine performs task caused by same application;
According to the resource utilization of each virtual machine at least one virtual machine set, the physical server is determined On virtual machine to be migrated, until on the physical server all virtual machines in addition to the virtual machine to be migrated resource The sum of utilization rate is less than or equal to the resource utilization upper limit of the physical server;
The migration bandwidth of each virtual machine in the virtual machine to be migrated is obtained, wherein, migration bandwidth represents that virtual machine exists The bandwidth taken in transition process;
According to the migration bandwidth, the virtual machine (vm) migration of same virtual machine set will be belonged to extremely in the virtual machine to be migrated Other single physical servers in addition to the physical server, the resource utilization of other physical servers are less than institute State the resource utilization upper limit of physical server.
Second aspect, the embodiment of the present invention provide a kind of device for migrating virtual machine, and described device includes:
Monitoring resource condition module, for obtaining the resource utilization of physical server;
Analysis module, for being more than the utilization of resources of the physical server when the resource utilization of the physical server During the rate upper limit, all virtual machines on the physical server are divided at least one virtual machine set, wherein, single virtual machine All virtual machines in set perform task caused by same application;
The analysis module, is additionally operable to the utilization of resources according to each virtual machine at least one virtual machine set Rate, determines the virtual machine to be migrated on the physical server, until removing the virtual machine to be migrated on the physical server The sum of resource utilization of all virtual machines in addition is less than or equal to the resource utilization upper limit of the physical server;
The monitoring resource condition module, is additionally operable to obtain the migration band of each virtual machine in the virtual machine to be migrated Width, wherein, migration bandwidth represents the bandwidth that virtual machine takes in transition process;
The analysis module, is additionally operable to according to the migration bandwidth, will belong to same virtual in the virtual machine to be migrated Other the single physical servers of the virtual machine (vm) migration of machine set extremely in addition to the physical server, other described physical services The resource utilization of device is less than the resource utilization upper limit of the physical server.
A kind of method and device for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server More than physical server the resource utilization upper limit when, all virtual machines on physical server are divided at least one virtual machine Set, and virtual machine to be migrated is determined according to the resource utilization of each virtual machine, until the resource utilization of physical server Less than or equal to the resource utilization upper limit of physical server.The migration bandwidth of each virtual machine is obtained afterwards, and according to migration Bandwidth migrates each virtual machine set to be migrated to other same physical servers.Wherein, it is every in other physical servers The resource utilization of a physical server is less than the resource utilization upper limit of physical server.Be compared in the prior art in order to Realize in resource set, by the virtual machine (vm) migration of task produced by multiple same applications of execution to multiple and different physical services Device, the embodiment of the present invention can according to virtual machine perform task whether belong to same application caused by task, to determine At least one virtual machine set to be migrated, and by the virtual machine (vm) migration to be migrated in each virtual machine set to other same things Server is managed, ensure that after the transition process that is finished, the institute of task produced by making the same application of execution as far as possible There is virtual machine to be run on same physical server.Also, the virtual machine of task does not exist produced by same application is performed When on same physical server, the transmission range between these virtual machines is reduced as far as possible, is reduced because being transmitted after migration It is distant and take the probability that vast resources carries out data transmission.Therefore, in the case of in resource set, cloud computing number is solved It is high to carry out data transmission shared resource after migration according to the virtual machine of task produced by same application is performed in center Problem.
Brief description of the drawings
To describe the technical solutions in the embodiments of the present invention more clearly, below will be to needed in the embodiment Attached drawing is briefly described, it should be apparent that, drawings in the following description are only some embodiments of the present invention, for ability For the those of ordinary skill of domain, without creative efforts, it can also be obtained according to these attached drawings other attached Figure.
Fig. 1 is a kind of concrete application scene schematic diagram provided in an embodiment of the present invention;
Fig. 2 is a kind of method flow diagram for migrating virtual machine provided in an embodiment of the present invention;
Fig. 3 is another method flow diagram for migrating virtual machine provided in an embodiment of the present invention;
Fig. 4 is another method flow diagram for migrating virtual machine provided in an embodiment of the present invention;
Fig. 5 is another method flow diagram for migrating virtual machine provided in an embodiment of the present invention;
Fig. 6 is another method flow diagram for migrating virtual machine provided in an embodiment of the present invention;
Fig. 7 is a kind of apparatus structure schematic diagram for migrating virtual machine provided in an embodiment of the present invention.
Embodiment
Below in conjunction with the attached drawing in the embodiment of the present invention, the technical solution in the embodiment of the present invention is carried out clear, complete Site preparation describes, it is clear that described embodiment is only part of the embodiment of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, those of ordinary skill in the art are obtained all other without making creative work Embodiment, belongs to the scope of protection of the invention.
The embodiment of the present invention can be used for a kind of cloud computation data center, as shown in Figure 1, cloud computation data center can wrap Include Distribution Layer and resource layer.Wherein, analysis module and monitoring resource condition module can be included in Distribution Layer;Can be with resource layer Including one or more physical server, such as physical server 1, physical server 2 and physical server n, wherein, it is each A physical server corresponds to one or more virtual machine.Analysis module can report each according to monitoring resource condition module The resource utilization of physical server, the resource utilization upper limit of physical server, the resource utilization lower limit of physical server With the resource utilization of each virtual machine on physical server, to determine the void to be migrated on physical server in all virtual machines Plan machine and by virtual machine (vm) migration to be migrated to other physical servers.
The embodiment of the present invention provides a kind of method for migrating virtual machine, and this method flow is realized by analysis module.Such as Fig. 2 It is shown, the described method includes:
101st, the resource utilization of physical server is obtained.
Analysis module can obtain each physical server of resource layer from the information that monitoring resource condition module reports Resource utilization.In embodiments of the present invention, monitoring resource condition module can periodically report the money of each physical server Source utilization rate, can be that virtual machine to be migrated distribution is suitable so as to ensure analysis module after virtual machine to be migrated is determined Physical server.It is former after virtual machine to be migrated can thus be made from original physical server migration to other physical servers The resource utilization of physical server and the resource utilization of other physical servers are all in a metastable section model In enclosing.
102nd, when the resource utilization of the physical server is more than the resource utilization upper limit of the physical server, All virtual machines on the physical server are divided at least one virtual machine set.
Wherein, all virtual machines in single virtual machine set perform task caused by same application.
During at least one virtual machine set is divided, analysis module can be according to the task of each virtual machine execution Attribute, all virtual machines to be migrated are divided into one or more virtual machine set to be migrated, that is, by same application Virtual robot arm to be migrated where all tasks produced is into a virtual machine set to be migrated.
103rd, according to the resource utilization of each virtual machine at least one virtual machine set, the physics clothes are determined The virtual machine to be migrated being engaged on device, up to all virtual machines on the physical server in addition to the virtual machine to be migrated The sum of resource utilization is less than or equal to the resource utilization upper limit of the physical server.
Analysis module can be according to the resource of each virtual machine on the physical server acquired in monitoring resource condition module Utilization rate, during virtual machine to be migrated is determined, determines that each virtual machine to be migrated is required for calculating and migrates this After a virtual machine, the resource utilization of physical server, and by judging the utilization of resources and the physical services of physical server The magnitude relationship of the resource utilization upper limit of device, to determine the need for stopping the process for determining virtual machine to be migrated.Due to thing The size for managing the resource utilization of server is equal to the sum of resource utilization of all virtual machines on physical server, therefore, After determining a virtual machine to be migrated on physical server, it can be not determined to wait to move on physical server by obtaining The sum of resource utilization of virtual machine is moved, to determine the resource utilization of the physical server after this virtual machine is migrated. It should be noted that analysis module can be according to the resource utilization order from big to small of virtual machine, or from small to large suitable Sequence, or virtual machine to be migrated is determined according to certain rule, until all in addition to virtual machine to be migrated on physical server The sum of resource utilization of virtual machine is less than or equal to the resource utilization upper limit of physical server.
In embodiments of the present invention, in order to ensure after transition process is finished, same virtual machine set is belonged to Virtual machine between transmission range, analysis module can preferentially from a virtual machine set determine virtual machine to be migrated.When In this virtual machine set all virtual machines be all confirmed as virtual machine to be migrated and then from other virtual machine set really Fixed virtual machine to be migrated, specific embodiment can be mentioned below.
104th, the migration bandwidth of each virtual machine in the virtual machine to be migrated is obtained.
Wherein, migrate bandwidth and represent the bandwidth that virtual machine takes in transition process.
In embodiments of the present invention, the specification of virtual machine can be different, and the virtual machine of different size is in virtual machine Shared migration resource also differs in transition process.Wherein, what the larger virtual machine of specification took in transition process moves Shipper pole is wide larger;The migration bandwidth that the less virtual machine of specification takes in transition process is smaller.It should be noted that determine void The mode of the migration bandwidth of plan machine, is not especially limited in embodiments of the present invention.Analysis module can be by obtaining virtual machine The data volume that produces is performed in task process to determine the migration bandwidth of virtual machine, or directly acquires virtual machine and is migrated in history During the migration bandwidth of the average value of migration bandwidth that takes as virtual machine, can also be by obtaining other use of virtual machine The migration bandwidth of virtual machine is determined in the relevant parameter for representing virtual machine (vm) migration bandwidth.
105th, according to the migration bandwidth, the virtual machine that same virtual machine set is belonged in the virtual machine to be migrated is moved Move to other single physical servers in addition to the physical server.
Wherein, the resource utilization of other physical servers is less than in the resource utilization of the physical server Limit.
In embodiments of the present invention, analysis module will belong to all virtual machines to be migrated of same virtual machine set as one A entirety migrates, that is, in transition process, analysis module will belong to all to be migrated virtual of same virtual machine set Machine is migrated to same physical server, to ensure that the same application of execution after migration produces the virtual machine of task in transmission number Less resource is taken during.It should be noted that the virtual machine to be migrated for belonging to different virtual machine set may also be same When be migrated to same physical server, however, to ensure that migration after, migrate to physical server performance, generally All virtual machine (vm) migrations to be migrated for belonging to same virtual machine set are only belonged into different virtual machine to same physical server All virtual machines to be migrated of set, migrate to different physical servers according to affiliated virtual machine set.It should be noted that The method for all virtual machines to be migrated for belonging to same virtual machine set for migration is not made specifically in embodiments of the present invention yet Limit, can use bin packing algorithm or other can carry out the algorithm of reasonable distribution, by virtual machine (vm) migration to be migrated to other things Manage server.
A kind of method for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server is more than thing When managing the resource utilization upper limit of server, all virtual machines on physical server are divided at least one virtual machine set, And virtual machine to be migrated is determined according to the resource utilization of each virtual machine, until physical server resource utilization be less than or Equal to the resource utilization upper limit of physical server.The migration bandwidth of each virtual machine is obtained afterwards, and will according to migration bandwidth Each virtual machine set to be migrated is migrated to other same physical servers.Wherein, each physics in other physical servers The resource utilization of server is less than the resource utilization upper limit of physical server.It is compared to and is provided in the prior art in order to realize Source is concentrated, by the virtual machine (vm) migration of task produced by multiple same applications of execution to multiple and different physical servers, this hair Bright embodiment can according to virtual machine perform task whether belong to same application caused by task, it is at least one to determine Virtual machine set to be migrated, and by the virtual machine (vm) migration to be migrated in each virtual machine set to other same physical services Device, ensure that after the transition process that is finished, task produced by making the same application of execution as far as possible it is all virtual Machine is run on same physical server.Also, the virtual machine of task is not same produced by same application is performed When on physical server, reduce the transmission range between these virtual machines as far as possible, reduce because after migration transmission range compared with Far take the probability that vast resources carries out data transmission.Therefore, in the case of in resource set, cloud computation data center is solved The virtual machine of task carries out data transmission the problem of shared resource is high after migration produced by the middle same application of execution.
In order to avoid run a small amount of virtual machine on there are physical server and caused by the wasting of resources, in the present invention In another implementation of embodiment, the physical server of the resource utilization upper limit, Ke Yitong are less than for resource utilization Cross all virtual machine (vm) migrations on physical server to other physical servers.Therefore, in implementation as shown in Figure 2 On the basis of, implementation as shown in Figure 3 is also implemented as, that is, physical server is obtained in the step 101 that is finished Resource utilization after, can also carry out step 106 to step 110:
106th, according to the resource utilization of the physical server and the resource utilization upper limit of the physical server, sentence Whether the resource utilization of the disconnected physical server is more than the resource utilization upper limit of the physical server.
Wherein, when the resource utilization of the physical server is less than or equal to the resource utilization of the physical server During the upper limit, step 107 is performed to step 109;When the resource utilization of the physical server takes more than or equal to the physics During the resource utilization upper limit of business device, step 110 is performed.
In embodiments of the present invention, when the resource utilization of physical server is less than or equal to the resource profit of physical server , can be by performing step 107 during with the rate upper limit, the resource utilization lower limit by analysis module according to physical server, to sentence Whether disconnected physical server is the physical server for running a small amount of virtual machine.In cloud computation data center, each physics clothes The operation of business device can all take certain resource, and when the resource utilization of physical server is relatively low, this physics can be caused to take Although the business device wasting of resources, that is, physical server occupy certain resource, but only use its small portion resource.At this time, may be used With by migrating all virtual machines on physical server to move empty physical server, and physical server is closed, so as to subtract The quantity for the physical server being currently running in few cloud computation data center, and then reduce all physics in cloud computation data center The sum of resource shared by server, reduces the wasting of resources.
107th, according to the resource utilization of the physical server and the resource utilization lower limit of the physical server, sentence Whether the resource utilization of the disconnected physical server is less than the resource utilization lower limit of the physical server.
Wherein, when the resource utilization of the physical server is less than the resource utilization lower limit of the physical server, Perform step 108;When the resource utilization of the physical server is greater than or equal to the resource utilization of the physical server Lower limit, and less than or equal to the physical server the resource utilization upper limit when, perform step 109.
108th, all virtual machines on the physical server are determined as the virtual machine to be migrated, and will be described to be migrated Virtual machine is divided at least one virtual machine set.
Analysis module can be using all virtual machines on the physical server as virtual machine to be migrated, and will be to be migrated virtual Machine is divided at least one virtual machine set to be migrated, is taken in order to migrate all virtual machine set to be migrated to other physics It is engaged in after device, closes the physical server for moving sky virtual machine, is taken with the physics being currently running by reducing cloud computation data center The quantity of device of being engaged in saves resource.
109th, determine that the virtual machine to be migrated is not present on the physical server.
In order to ensure that the resource utilization of physical server is in a metastable section, when the money of physical server Source utilization rate is not more than the resource utilization upper limit of physical server, and not less than the resource utilization lower limit of physical server When, the virtual machine on physical server can not be migrated, then virtual machine to be migrated just also be not present on physical server.
110th, all virtual machines on the physical server are divided at least one virtual machine set.
After the step 110 that is finished, step 103 is performed.
It should be noted that after be finished step 108 or step 103, step 104 and step 105 can be performed.
A kind of method for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server is less than thing When managing the resource utilization lower limit of server, all virtual machines on physical server are divided at least one to be migrated virtual Machine set, and migrate to other physical servers.Wherein, in other physical servers each physical server resource utilization Less than the resource utilization upper limit of physical server.It is compared in the prior art in order to realize in resource set, by multiple execution The virtual machine (vm) migration of task produced by same application to multiple and different physical servers, the embodiment of the present invention can be in physics When the resource utilization of server is less than the resource utilization lower limit of physical server, in order to reduce the wasting of resources, and by physics All virtual machines on server are according to ready-portioned virtual machine set, using each virtual machine set as a bulk migration extremely Other physical servers, afterwards can close the physical server for moving sky virtual machine, so as to avoid being transported on physical server Go the situation of a small amount of virtual machine, in resource set in the case of, reduce the wasting of resources, and solve cloud computation data center The virtual machine of task carries out data transmission the problem of shared resource is high after migration produced by the middle same application of execution.
In order to ensure after virtual machine (vm) migration, belong to the transmission range between the virtual machine of same virtual machine set, It is exactly that will belong to the virtual machine of same virtual machine set as far as possible on same physical server, in another of the present embodiment In implementation, virtual machine to be migrated can be preferentially determined from a virtual machine set, when institute in this virtual machine set There is virtual machine to be all confirmed as virtual machine to be migrated and then virtual machine to be migrated is determined from other virtual machine set.Therefore, , step 103, can be with specific implementation step 1031 as shown in Figure 5 to step on the basis of implementation as shown in Figure 2 Rapid 1036:
1031st, the first virtual machine set at least one virtual machine set is determined.
Wherein, the sum of resource utilization of all virtual machines in the first virtual machine set, more than or equal to it is described extremely The resource of all virtual machines in other virtual machine set in a few virtual machine set in addition to the first virtual machine set The sum of utilization rate.
It should be noted that in embodiments of the present invention, for the virtual machine set that ensures to include virtual machine to be migrated Minimum number, that is, ensure after the transition process that is finished, only influence the implementation procedure of less application on a virtual machine In be used for information exchange resource, analysis module can be virtual as first using the virtual machine set of the sum of resource utilization maximum Machine set, to determine virtual machine to be migrated.
1032nd, judge by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers it Afterwards, whether the resource utilization of the physical server is less than or equal to the resource utilization upper limit of the physical server.Its In, after by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the physics When the resource utilization of server is less than or equal to the resource utilization upper limit of the physical server, then step 1033 is performed; Otherwise step 1034 is performed to step 1036;
1033rd, the virtual machine to be migrated in the first virtual machine set is determined, until removing institute on the physical server There is the resource that the sum of resource utilization of all virtual machines beyond virtual machine to be migrated is less than or equal to the physical server The utilization rate upper limit.
It should be noted that when the virtual machine negligible amounts for needing to migrate, analysis module can be from same virtual machine collection Virtual machine to be migrated is determined in conjunction, so that ensure each virtual machine in other virtual machine set in task process is performed, into Row information transmission range required when interacting is most short, so that save these virtual machines is used for information exchange in task process is performed Resource.
1034th, taken according to by all virtual machine (vm) migrations in described first to N virtual machine set to other described physics It to be engaged in after device, the resource utilization of the physical server is less than or equal to the resource utilization upper limit of the physical server, To determine the minimum positive integer N of the quantity less than or equal at least one virtual machine set.
1035th, all virtual machines in described first to N-1 virtual machine set are determined as virtual machine to be migrated.
1036th, the virtual machine to be migrated in the N virtual machine set is determined, until except described on the physical server The sum of resource utilization of all virtual machines beyond all virtual machines to be migrated is less than or equal to the money of the physical server The source utilization rate upper limit.
It should be noted that when the virtual machine quantity for needing to migrate is more, analysis module can be from multiple virtual machine collection Virtual machine to be migrated is determined in conjunction.Also, in order to save in all virtual machine set each virtual machine as far as possible in execution task The transfer resource of Shi Suoxu, after a virtual machine set is determined, by all virtual machines in this virtual machine set All it is determined as virtual machine to be migrated and then determines another virtual machine set, so as to ensures the multiple void of migration as few as possible Virtual machine in plan machine set.
A kind of method for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server is more than thing When managing the resource utilization upper limit of server, all virtual machines on physical server are divided at least one virtual machine set, And virtual machine to be migrated is determined according to the resource utilization of each virtual machine, until physical server resource utilization be less than or Equal to the resource utilization upper limit of physical server.The migration bandwidth of each virtual machine is obtained afterwards, and will according to migration bandwidth Each virtual machine set to be migrated is migrated to other same physical servers.Wherein, each physics in other physical servers The resource utilization of server is less than the resource utilization upper limit of physical server.It is compared to and is provided in the prior art in order to realize Source is concentrated, by the virtual machine (vm) migration of task produced by multiple same applications of execution to multiple and different physical servers, this hair Bright embodiment can according to virtual machine perform task whether belong to same application caused by task, it is at least one to determine Virtual machine set to be migrated, and by the virtual machine (vm) migration to be migrated in each virtual machine set to other same physical services Device, ensure that after the transition process that is finished, task produced by making the same application of execution as far as possible it is all virtual Machine is run on same physical server.Meanwhile during virtual machine to be migrated is determined, when a virtual machine is determined After virtual machine to be migrated in set, preferentially other in this definite virtual machine set can be used as virtual machine to be migrated Virtual machine, until by all virtual machines in this virtual machine set be all determined as virtual machine to be migrated and then from its Virtual machine to be migrated is determined in his virtual machine set.Also, the virtual machine of task is not same produced by same application is performed When on one physical server, the transmission range between these virtual machines is reduced as far as possible, is reduced because of transmission distance after migration From the probability for taking vast resources farther out and carrying out data transmission.Therefore, in the case of in resource set, cloud computing data are solved The virtual machine of task produced by same application is performed in center carries out data transmission that shared resource is high to ask after migration Topic.
After ensureing the virtual machine (vm) migration to be migrated in each virtual machine set to other physical servers, other physics The resource utilization of each physical server in server is less than the resource utilization upper limit, in another realization of the present embodiment In mode, it is necessary to judge that the virtual machine to be migrated in same virtual machine set is belonged to moves before virtual machine to be migrated is migrated Move to after other single physical servers, whether the resource utilization of other single physical servers can be less than or equal to thing Manage the resource utilization upper limit of server.Therefore, on the basis of implementation as shown in Figure 2, step 105 basis is being performed The migration bandwidth, the virtual machine (vm) migration that same virtual machine set is belonged in the virtual machine to be migrated is taken to except the physics Other single physical servers beyond business device, the resource utilization of other physical servers are less than the physical server The resource utilization upper limit before, can also carry out step 111 and step 112, specific implementation is as shown in Figure 5:
111st, the resource utilization of other single physical servers is obtained.
When performing the transition process of step 105, analysis module makees the virtual machine to be migrated in each virtual machine set For a bulk migration to other physical servers.Therefore, when the virtual machine (vm) migration to be migrated in a virtual machine set to list After other a physical servers, other single physical servers may be because of the virtual machine to be migrated in this virtual machine set It is more, and cause the resource utilization of other single physical servers to be more than the resource utilization upper limit.At this time, it is necessary to pass through step Rapid 111 to obtain the resource utilization of other single physical servers, and is judged by step 112 by single virtual machine set In virtual machine (vm) migration to be migrated to other described single physical servers after, the utilization of resources of other single physical servers Whether rate is more than the resource utilization upper limit of physical server.It should be noted that analysis module is according to monitoring resource condition mould The resource utilization for other single physical servers that block reports and the resource utilization upper limit of physical server judged, Embodiment can be mentioned below.
It should be noted that the resource utilization of each virtual machine to be migrated is performing step in single virtual machine set 103, according to the resource utilization of each virtual machine at least one virtual machine set, determine on the physical server Virtual machine to be migrated, until the utilization of resources of all virtual machines on the physical server in addition to the virtual machine to be migrated When the sum of rate is less than or equal to the resource utilization upper limit of the physical server, obtain.Step 104 and step 111 exist It is not especially limited on the execution sequence of the embodiment of the present invention, step 104 and step 111 can be held according to certain sequencing OK, can also perform at the same time.
112nd, judge all virtual machine (vm) migrations to be migrated in the single virtual machine set to other described single physics After server, whether the resource utilization of other single physical servers is more than the utilization of resources of the physical server The rate upper limit.Wherein, when the resource utilization of other single physical servers is more than the utilization of resources of the physical server During the rate upper limit, step 113 and step 114 are performed;When the resource utilization of other single physical servers is less than or equal to During the resource utilization upper limit of the physical server, step 105 is performed according to the migration bandwidth, will be described to be migrated virtual Belong to other the single physical servers of the virtual machine (vm) migration of same virtual machine set extremely in addition to the physical server in machine.
113rd, according to the utilization of resources of each virtual machine to be migrated in the migration bandwidth and the single virtual machine set Rate, determines the target virtual machine in all virtual machines to be migrated in the single virtual machine set.
It should be noted that the definite method of target virtual machine is not especially limited in embodiments of the present invention, Ke Yigen Determined according to different application scenarios.Such as:Need, by migrating virtual machine, to make the performance fast lifting of physical server, then The highest virtual machine of resource utilization can be selected as target virtual machine;Alternatively, in order to ensure the stability of physical server, The virtual machine using the possible rapid growth of resource utilization is needed as target virtual machine.
114th, according to the migration bandwidth order from big to small of the target virtual machine, the target virtual machine is moved successively The target physical server nearest apart from other described single physical servers is moved to, and will be removed in the single virtual machine set Other virtual machine (vm) migrations to be migrated beyond the target virtual machine are to other described single physical servers.
Wherein, the resource utilization of the target physical server is less than in the resource utilization of the physical server Limit.
Analysis module can be by each target virtual machine in single virtual machine set according to the size ascending order for migrating bandwidth Or descending arrangement, such as:Size of the analysis module by each target virtual machine in single virtual machine set according to migration bandwidth Descending arranges, and obtains the bandwidth drop down list of virtual machine, afterwards by first virtual machine in the bandwidth drop down list of virtual machine, Exactly the virtual machine (vm) migration of occupancy migration bandwidth maximum recently and can carry first virtually extremely apart from present physical server The target physical server of machine, i.e., after first virtual machine (vm) migration, resource utilization be less than the resource utilization upper limit away from The target physical server nearest from present physical server;Afterwards by next virtual machine in the bandwidth drop down list of virtual machine According to, migrate to apart from present physical server recently and the target physical server of next virtual machine can be carried, that is, work as After next virtual machine (vm) migration, resource utilization is less than the mesh nearest apart from present physical server of the resource utilization upper limit Physical server is marked, until the resource utilization of present physical server is less than the resource utilization upper limit, terminates moving for virtual machine Move past journey.
In embodiments of the present invention, in order to save the migration resource taken in transition process, analysis module can be determined first Target virtual machine in bandwidth drop down list, makes the resource of other physical servers after all target virtual machines are migrated Utilization rate is less than the resource utilization upper limit.Wherein, target virtual machine is last virtual machine in bandwidth drop down list, or most Several continuous virtual machines afterwards.Afterwards, target virtual machine is migrated in the manner described above, that is, by target virtual machine The migration highest target virtual machine of bandwidth is migrated as first virtual machine, afterwards by other in addition to the first virtual machine Target virtual machine is migrated successively, until the migration of all target virtual machines finishes.It should be noted that the mode migrated It is not especially limited, can be set according to different application scenarios in embodiments of the present invention.
It should be noted that each physical server can correspond to a virtual machine list, virtual machine list is used to record The relevant parameter of all virtual machines run on present physical server.After the transition process that is finished, analysis module can The corresponding virtual machine list of physical server to be modified, will migrate to each virtual machine of other physical servers Relevant parameter delete, and add migrated to the relevant parameter of each virtual machine of present physical server.
A kind of method for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server is more than thing When managing the resource utilization upper limit of server, all virtual machines on physical server are divided at least one virtual machine set, And virtual machine to be migrated is determined according to the resource utilization of each virtual machine, until physical server resource utilization be less than or Equal to the resource utilization upper limit of physical server.The migration bandwidth of each virtual machine is obtained afterwards, and is sentenced according to migration bandwidth Break after the virtual machine (vm) migration to be migrated in single virtual machine set to other single physical servers, other single physics take Whether the resource utilization of business device is more than the resource utilization upper limit of physical server.If so, then according to migration bandwidth and single The resource utilization of each virtual machine to be migrated in virtual machine set, determines each void to be migrated in single virtual machine set The migration position of plan machine, and migrate successively.It is compared in the prior art in order to realize in resource set, multiple execution are same It can work as other single things using virtual machine (vm) migration to multiple and different physical servers, the embodiment of the present invention of produced task When the resource utilization of reason server is more than the resource utilization upper limit of physical server, it will wait to move in each virtual machine set Virtual machine (vm) migration is moved at least two nearer physical servers of relative distance, ensure that after the transition process that is finished, Transmission range between all virtual machines of task produced by performing same application, reduces because transmission range is farther out after migration And take the probability that vast resources carries out data transmission.Therefore, in the case of in resource set, solve in cloud computation data center The virtual machine of task produced by performing same application carries out data transmission the problem of shared resource is high after migration.
After ensureing to migrate virtual machine to be migrated, the resource utilization of physical server can meet current application field Requirement of the scape for the resource utilization of physical server, can basis in another implementation of the embodiment of the present invention Different application scenarios pre-set the resource utilization upper limit of physical server and the resource utilization lower limit of physical server. Therefore, on the basis of implementation as shown in Figure 3, implementation as shown in Figure 6 is also implemented as, that is, in step Rapid 106 according to the resource utilization of the physical server and the resource utilization upper limit of the physical server, described in judgement Whether the resource utilization of physical server is more than before the resource utilization upper limit of the physical server, and the method is also wrapped Include step 115:
115th, set under the resource utilization upper limit of the physical server and the resource utilization of the physical server Limit.
It should be noted that the precedence relationship on execution sequence is not present due to step 101 and step 115, step 101 and step 115 can be performed according to certain sequencing, or perform at the same time, in embodiments of the present invention, not to step 101 and the execution sequence of step 115 be defined.The resource utilization upper limit of each physical server and each physical server Resource utilization lower limit can be different.The resource utilization upper limit and resource utilization lower limit can take according to each physics respectively The performance of device of being engaged in is preset.Wherein, the resource utilization upper limit for physical server and the resource of physical server profit With the specific setting means of rate lower limit, it is not especially limited in embodiments of the present invention, can is that staff should according to difference Preset with scene, or analysis module obtains empirical value according to historical data, and it is periodically pre- for each physical server First set, can also be other setting means.
A kind of method for migrating virtual machine provided in an embodiment of the present invention, presets the resource utilization of physical server The resource utilization lower limit of the upper limit and physical server, takes according to the resource utilization of the physical server of acquisition and physics afterwards The resource utilization upper limit of business device, and the magnitude relationship of the resource utilization lower limit of physical server, to determine to need to migrate Virtual machine to be migrated, and migrate to other physical servers.Wherein, in other physical servers each physical server money Source utilization rate is less than the resource utilization upper limit of physical server.It is compared in the prior art to realize in resource set, is Realize in resource set, by it is multiple perform same applications produced by task virtual machine (vm) migration to multiple and different physical services Device, the embodiment of the present invention can judge the resource utilization upper limit of the resource utilization of physical server and physical server, And before the magnitude relationship of the resource utilization lower limit of physical server, physical services are preset according to different application scene The resource utilization upper limit of device and the resource utilization lower limit of physical server, so that it is to be migrated to ensure that definite needs migrate Virtual machine is more accurate, and then the virtual machine for solving task produced by performing same application in cloud computation data center is migrating Carry out data transmission the problem of shared resource is high afterwards.
The embodiment of the present invention provides a kind of device 20 for migrating virtual machine, as shown in fig. 7, described device 20 includes:
Monitoring resource condition module 21, for obtaining the resource utilization of physical server.
Analysis module 22, for being more than the resource profit of the physical server when the resource utilization of the physical server During with the rate upper limit, all virtual machines on the physical server are divided at least one virtual machine set, wherein, single virtual All virtual machines in machine set perform task caused by same application.
The analysis module 22, is additionally operable to the utilization of resources according to each virtual machine at least one virtual machine set Rate, determines the virtual machine to be migrated on the physical server, until removing the virtual machine to be migrated on the physical server The sum of resource utilization of all virtual machines in addition is less than or equal to the resource utilization upper limit of the physical server.
The monitoring resource condition module 21, is additionally operable to obtain the migration band of each virtual machine in the virtual machine to be migrated Width, wherein, migration bandwidth represents the bandwidth that virtual machine takes in transition process.
The analysis module 22, is additionally operable to according to the migration bandwidth, will belong to same void in the virtual machine to be migrated The virtual machine (vm) migration of plan machine set to other single physical servers in addition to the physical server, other described physics take The resource utilization of business device is less than the resource utilization upper limit of the physical server.
In another implementation of the embodiment of the present invention, the analysis module 22, is additionally operable to be taken according to the physics The resource utilization of device of being engaged in and the resource utilization upper limit of the physical server, judge the utilization of resources of the physical server Whether rate is more than the resource utilization upper limit of the physical server;
When the resource utilization of the physical server is less than or equal to the resource utilization upper limit of the physical server When, according to the resource utilization of the physical server and the resource utilization lower limit of the physical server, judge the thing Whether the resource utilization for managing server is less than the resource utilization lower limit of the physical server;
When the resource utilization of the physical server is less than the resource utilization lower limit of the physical server, by institute State all virtual machines on physical server and be determined as the virtual machine to be migrated, and the virtual machine to be migrated is divided into described At least one virtual machine set;
When the physical server resource utilization be greater than or equal to the physical server resource utilization lower limit, And when being less than or equal to the resource utilization upper limit of the physical server, determine to treat there is no described on the physical server Migrate virtual machine.
In another implementation of the embodiment of the present invention, the analysis module 22, specifically for determine it is described at least The first virtual machine set in one virtual machine set, in the first virtual machine set the resource utilization of all virtual machines it With more than or equal to other virtual machine set at least one virtual machine set in addition to the first virtual machine set In all virtual machines the sum of resource utilization;
Judge after all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, institute Whether the resource utilization for stating physical server is less than or equal to the resource utilization upper limit of the physical server;
It is described after by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers When the resource utilization of physical server is less than or equal to the resource utilization upper limit of the physical server, it is determined that described the Virtual machine to be migrated in one virtual machine set, until all in addition to all virtual machines to be migrated on the physical server The sum of resource utilization of virtual machine is less than or equal to the resource utilization upper limit of the physical server;
It is described after by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers The resource utilization of physical server be more than the physical server the resource utilization upper limit when, then according to by described first to After all virtual machine (vm) migrations to other described physical servers in N virtual machine set, the resource of the physical server Utilization rate is less than or equal to the resource utilization upper limit of the physical server, to determine to be less than or equal at least one void The minimum positive integer N of the quantity of plan machine set;
All virtual machines in described first to N-1 virtual machine set are determined as virtual machine to be migrated;
The virtual machine to be migrated in the N virtual machine set is determined, until except described all on the physical server The sum of resource utilization of all virtual machines beyond virtual machine to be migrated is less than or equal to the resource profit of the physical server With the rate upper limit.
In another implementation of the embodiment of the present invention, the monitoring resource condition module 21, is additionally operable to obtain institute State the resource utilization of other single physical servers.
The analysis module 22, is additionally operable to judge all virtual machine (vm) migrations to be migrated in the single virtual machine set extremely After other described single physical servers, whether the resource utilization of other single physical servers is more than the physics The resource utilization upper limit of server.
The analysis module 22, is additionally operable to when the resource utilization of other single physical servers is more than the physics During the resource utilization upper limit of server, according to each to be migrated virtual in the migration bandwidth and the single virtual machine set The resource utilization of machine, determines the target virtual machine in all virtual machines to be migrated in the single virtual machine set.
The analysis module 22, is additionally operable to the migration bandwidth order from big to small according to the target virtual machine, by institute Target virtual machine is stated to migrate successively to the target physical server nearest apart from other described single physical servers, and by described in Other virtual machine (vm) migrations to be migrated in single virtual machine set in addition to the target virtual machine are to other described single physics Server, the resource utilization of the target physical server are less than the resource utilization upper limit of the physical server.
In another implementation of the embodiment of the present invention, described device 20 further includes:
Setting module 23, for setting the resource utilization upper limit of the physical server and the money of the physical server Source utilization rate lower limit.
A kind of device for migrating virtual machine provided in an embodiment of the present invention, when the resource utilization of physical server is more than thing When managing the resource utilization upper limit of server, all virtual machines on physical server are divided at least one virtual machine set, And virtual machine to be migrated is determined according to the resource utilization of each virtual machine, until physical server resource utilization be less than or Equal to the resource utilization upper limit of physical server.The migration bandwidth of each virtual machine is obtained afterwards, and will according to migration bandwidth Each virtual machine set to be migrated is migrated to other same physical servers.Wherein, each physics in other physical servers The resource utilization of server is less than the resource utilization upper limit of physical server.It is compared to and is provided in the prior art in order to realize Source is concentrated, by the virtual machine (vm) migration of task produced by multiple same applications of execution to multiple and different physical servers, this hair Bright embodiment can according to virtual machine perform task whether belong to same application caused by task, it is at least one to determine Virtual machine set to be migrated, and by the virtual machine (vm) migration to be migrated in each virtual machine set to other same physical services Device, ensure that after the transition process that is finished, task produced by making the same application of execution as far as possible it is all virtual Machine is run on same physical server.Also, the virtual machine of task is not same produced by same application is performed When on physical server, reduce the transmission range between these virtual machines as far as possible, reduce because after migration transmission range compared with Far take the probability that vast resources carries out data transmission.Therefore, in the case of in resource set, cloud computation data center is solved The virtual machine of task carries out data transmission the problem of shared resource is high after migration produced by the middle same application of execution.
Each embodiment in this specification is described by the way of progressive, identical similar portion between each embodiment Divide mutually referring to what each embodiment stressed is the difference with other embodiment.It is real especially for device For applying example, since it is substantially similar to embodiment of the method, so describing fairly simple, related part is referring to embodiment of the method Part explanation.
One of ordinary skill in the art will appreciate that realize all or part of flow in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, the program can be stored in computer read/write memory medium In, the program is upon execution, it may include such as the flow of the embodiment of above-mentioned each method.
The above description is merely a specific embodiment, but protection scope of the present invention is not limited thereto, any Those familiar with the art the invention discloses technical scope in, the change or replacement that can readily occur in, all should It is included within the scope of the present invention.Therefore, protection scope of the present invention should be subject to scope of the claims.

Claims (10)

  1. A kind of 1. method for migrating virtual machine, it is characterised in that the described method includes:
    Obtain the resource utilization of physical server;
    When the resource utilization of the physical server is more than the resource utilization upper limit of the physical server, by the thing All virtual machines are divided at least one virtual machine set on reason server, wherein, it is all virtual in single virtual machine set Machine performs task caused by same application;
    According to the resource utilization of each virtual machine at least one virtual machine set, determine on the physical server Virtual machine to be migrated, until the utilization of resources of all virtual machines on the physical server in addition to the virtual machine to be migrated The sum of rate is less than or equal to the resource utilization upper limit of the physical server;
    The migration bandwidth of each virtual machine in the virtual machine to be migrated is obtained, wherein, migration bandwidth represents that virtual machine is migrating During the bandwidth that takes;
    According to the migration bandwidth, the virtual machine (vm) migration that same virtual machine set is belonged in the virtual machine to be migrated is extremely removed into institute Other single physical servers beyond physical server are stated, the resource utilization of other physical servers is less than the thing Manage the resource utilization upper limit of server;
    According to the migration bandwidth order from big to small of target virtual machine, the target virtual machine is migrated to described in distance successively The nearest target physical server of other single physical servers, and the destination virtual will be removed in the single virtual machine set Other virtual machine (vm) migrations to be migrated beyond machine are to other described single physical servers, the resource of the target physical server Utilization rate is less than the resource utilization upper limit of the physical server.
  2. 2. according to the method described in claim 1, it is characterized in that, it is described acquisition physical server resource utilization it Afterwards, the method further includes:
    According to the resource utilization of the physical server and the resource utilization upper limit of the physical server, the thing is judged Whether the resource utilization for managing server is more than the resource utilization upper limit of the physical server;
    When the resource utilization of the physical server is less than or equal to the resource utilization upper limit of the physical server, root According to the resource utilization of the physical server and the resource utilization lower limit of the physical server, the physical services are judged Whether the resource utilization of device is less than the resource utilization lower limit of the physical server;
    When the resource utilization of the physical server is less than the resource utilization lower limit of the physical server, by the thing All virtual machines are determined as the virtual machine to be migrated on reason server, and by the virtual machine to be migrated be divided into it is described at least One virtual machine set;
    It is and small when the resource utilization of the physical server is greater than or equal to the resource utilization lower limit of the physical server In or equal to the physical server the resource utilization upper limit when, determine on the physical server there is no described to be migrated Virtual machine.
  3. It is 3. according to the method described in claim 1, it is characterized in that, described according to each virtual machine on the physical server Resource utilization and at least one virtual machine set, determine the virtual machine to be migrated on the physical server, until institute State the sum of resource utilization of all virtual machines on physical server in addition to the virtual machine to be migrated and be less than or equal to institute The resource utilization upper limit of physical server is stated, including:
    Determine the first virtual machine set at least one virtual machine set, it is all virtual in the first virtual machine set The sum of resource utilization of machine, more than or equal at least one virtual machine set in addition to the first virtual machine set Other virtual machine set in all virtual machines the sum of resource utilization;
    Judge after all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the thing Whether the resource utilization for managing server is less than or equal to the resource utilization upper limit of the physical server;
    After by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the physics When the resource utilization of server is less than or equal to the resource utilization upper limit of the physical server, it is determined that described first is empty Virtual machine to be migrated in plan machine set, until all virtual in addition to all virtual machines to be migrated on the physical server The sum of resource utilization of machine is less than or equal to the resource utilization upper limit of the physical server;
    After by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the physics When the resource utilization of server is more than the resource utilization upper limit of the physical server, then according to virtual to N by first After all virtual machine (vm) migrations to other described physical servers in machine set, the resource utilization of the physical server is small In or equal to the physical server the resource utilization upper limit, to determine to be less than or equal at least one virtual machine set Quantity minimum positive integer N;
    All virtual machines in first to N-1 virtual machine set are determined as virtual machine to be migrated;
    The virtual machine to be migrated in the N virtual machine set is determined, until needing to be moved except described on the physical server Move the resource utilization that the sum of resource utilization of all virtual machines beyond virtual machine is less than or equal to the physical server The upper limit.
  4. 4. method as claimed in any of claims 1 to 3, it is characterised in that described according to the migration bandwidth, List of the virtual machine (vm) migration of same virtual machine set extremely in addition to the physical server will be belonged in the virtual machine to be migrated Before other a physical servers, the method further includes:
    Obtain the resource utilization of other single physical servers;
    Judge by all virtual machine (vm) migrations to be migrated in the single virtual machine set to other described single physical servers it Afterwards, whether the resource utilization of other single physical servers is more than the resource utilization upper limit of the physical server;
    When the resource utilization of other single physical servers is more than the resource utilization upper limit of the physical server, According to the resource utilization of each virtual machine to be migrated in the migration bandwidth and the single virtual machine set, the list is determined Target virtual machine in a virtual machine set in all virtual machines to be migrated.
  5. 5. according to the method described in claim 2, it is characterized in that, in the resource utilization according to the physical server With the resource utilization upper limit of the physical server, judge whether the resource utilization of the physical server is more than the thing Before the resource utilization upper limit for managing server, the method further includes:
    Set the resource utilization upper limit of the physical server and the resource utilization lower limit of the physical server.
  6. 6. a kind of device for migrating virtual machine, it is characterised in that described device includes:
    Monitoring resource condition module, for obtaining the resource utilization of physical server;
    Analysis module, for being more than the resource utilization of the physical server when the resource utilization of the physical server In limited time, all virtual machines on the physical server are divided at least one virtual machine set, wherein, single virtual machine set In all virtual machines perform task caused by same application;
    The analysis module, is additionally operable to the resource utilization according to each virtual machine at least one virtual machine set, really Virtual machine to be migrated on the fixed physical server, until on the physical server in addition to the virtual machine to be migrated The sum of resource utilization of all virtual machines is less than or equal to the resource utilization upper limit of the physical server;
    The monitoring resource condition module, is additionally operable to obtain the migration bandwidth of each virtual machine in the virtual machine to be migrated, its In, migration bandwidth represents the bandwidth that virtual machine takes in transition process;
    The analysis module, is additionally operable to according to the migration bandwidth, same virtual machine collection will be belonged in the virtual machine to be migrated Other the single physical servers of the virtual machine (vm) migration of conjunction extremely in addition to the physical server, other physical servers Resource utilization is less than the resource utilization upper limit of the physical server;
    The analysis module, is additionally operable to the migration bandwidth order from big to small according to target virtual machine, by the destination virtual Machine is migrated to the target physical server nearest apart from other described single physical servers successively, and by the single virtual machine Other virtual machine (vm) migrations to be migrated in set in addition to the target virtual machine are described to other described single physical servers The resource utilization of target physical server is less than the resource utilization upper limit of the physical server.
  7. 7. device according to claim 6, it is characterised in that the analysis module, is additionally operable to according to the physical services The resource utilization upper limit of the resource utilization of device and the physical server, judges the resource utilization of the physical server Whether the resource utilization upper limit of the physical server is more than;
    When the resource utilization of the physical server is less than or equal to the resource utilization upper limit of the physical server, root According to the resource utilization of the physical server and the resource utilization lower limit of the physical server, the physical services are judged Whether the resource utilization of device is less than the resource utilization lower limit of the physical server;
    When the resource utilization of the physical server is less than the resource utilization lower limit of the physical server, by the thing All virtual machines are determined as the virtual machine to be migrated on reason server, and by the virtual machine to be migrated be divided into it is described at least One virtual machine set;
    It is and small when the resource utilization of the physical server is greater than or equal to the resource utilization lower limit of the physical server In or equal to the physical server the resource utilization upper limit when, determine on the physical server there is no described to be migrated Virtual machine.
  8. 8. device according to claim 6, it is characterised in that the analysis module, specifically for determining described at least one The first virtual machine set in a virtual machine set, in the first virtual machine set the resource utilization of all virtual machines it With more than or equal to other virtual machine set at least one virtual machine set in addition to the first virtual machine set In all virtual machines the sum of resource utilization;
    Judge after all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the thing Whether the resource utilization for managing server is less than or equal to the resource utilization upper limit of the physical server;
    After by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the physics When the resource utilization of server is less than or equal to the resource utilization upper limit of the physical server, it is determined that described first is empty Virtual machine to be migrated in plan machine set, until all virtual in addition to all virtual machines to be migrated on the physical server The sum of resource utilization of machine is less than or equal to the resource utilization upper limit of the physical server;
    After by all virtual machine (vm) migrations in the first virtual machine set to other described physical servers, the physics When the resource utilization of server is more than the resource utilization upper limit of the physical server, then according to virtual to N by first After all virtual machine (vm) migrations to other described physical servers in machine set, the resource utilization of the physical server is small In or equal to the physical server the resource utilization upper limit, to determine to be less than or equal at least one virtual machine set Quantity minimum positive integer N;
    All virtual machines in first to N-1 virtual machine set are determined as virtual machine to be migrated;
    The virtual machine to be migrated in the N virtual machine set is determined, until needing to be moved except described on the physical server Move the resource utilization that the sum of resource utilization of all virtual machines beyond virtual machine is less than or equal to the physical server The upper limit.
  9. 9. the device according to any one in claim 6 to 8, it is characterised in that the monitoring resource condition module, also For obtaining the resource utilization of other single physical servers;
    The analysis module, is additionally operable to judge all virtual machine (vm) migrations to be migrated in the single virtual machine set to the list After other a physical servers, whether the resource utilization of other single physical servers is more than the physical server The resource utilization upper limit;
    The analysis module, is additionally operable to when the resource utilization of other single physical servers is more than the physical server The resource utilization upper limit when, according to the money of each virtual machine to be migrated in the migration bandwidth and the single virtual machine set Source utilization rate, determines the target virtual machine in all virtual machines to be migrated in the single virtual machine set.
  10. 10. device according to claim 7, it is characterised in that described device further includes:
    Setting module, for setting the resource utilization upper limit of the physical server and the utilization of resources of the physical server Rate lower limit.
CN201510267151.8A 2015-05-22 2015-05-22 A kind of method and device for migrating virtual machine Active CN104866375B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510267151.8A CN104866375B (en) 2015-05-22 2015-05-22 A kind of method and device for migrating virtual machine

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510267151.8A CN104866375B (en) 2015-05-22 2015-05-22 A kind of method and device for migrating virtual machine

Publications (2)

Publication Number Publication Date
CN104866375A CN104866375A (en) 2015-08-26
CN104866375B true CN104866375B (en) 2018-05-11

Family

ID=53912224

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510267151.8A Active CN104866375B (en) 2015-05-22 2015-05-22 A kind of method and device for migrating virtual machine

Country Status (1)

Country Link
CN (1) CN104866375B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107203255A (en) * 2016-03-20 2017-09-26 田文洪 Power-economizing method and device are migrated in a kind of network function virtualized environment
CN107391228A (en) * 2017-07-25 2017-11-24 郑州云海信息技术有限公司 A kind of virtual machine migration management and device
CN108196935B (en) * 2017-12-06 2021-11-02 南京邮电大学 Cloud computing-oriented virtual machine energy-saving migration method
CN112181604B (en) * 2020-10-27 2023-06-13 中国联合网络通信集团有限公司 Capacity-shrinking target selection method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102096601A (en) * 2011-02-11 2011-06-15 浪潮(北京)电子信息产业有限公司 Virtual machine migration management method and system
CN102811141A (en) * 2011-06-01 2012-12-05 鸿富锦精密工业(深圳)有限公司 Method and system for monitoring running of virtual machines
CN103957231A (en) * 2014-03-18 2014-07-30 成都盛思睿信息技术有限公司 Virtual machine distributed task scheduling method under cloud calculating platform
CN104503826A (en) * 2015-01-04 2015-04-08 中国联合网络通信集团有限公司 Virtual machine mapping method and device for cloud computing data center

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060069761A1 (en) * 2004-09-14 2006-03-30 Dell Products L.P. System and method for load balancing virtual machines in a computer network

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102096601A (en) * 2011-02-11 2011-06-15 浪潮(北京)电子信息产业有限公司 Virtual machine migration management method and system
CN102811141A (en) * 2011-06-01 2012-12-05 鸿富锦精密工业(深圳)有限公司 Method and system for monitoring running of virtual machines
CN103957231A (en) * 2014-03-18 2014-07-30 成都盛思睿信息技术有限公司 Virtual machine distributed task scheduling method under cloud calculating platform
CN104503826A (en) * 2015-01-04 2015-04-08 中国联合网络通信集团有限公司 Virtual machine mapping method and device for cloud computing data center

Also Published As

Publication number Publication date
CN104866375A (en) 2015-08-26

Similar Documents

Publication Publication Date Title
US20200104184A1 (en) Accelerated resource allocation techniques
CN103955399B (en) A kind of virtual machine migration method and device and physical host
CN103685256B (en) A kind of virtual machine migration management, apparatus and system
CN104866375B (en) A kind of method and device for migrating virtual machine
CN110348571A (en) A kind of neural network model training method, device, chip and system
CN104935628B (en) A kind of method that multiple associated virtual machines are migrated between multiple data centers
CN109067890A (en) A kind of CDN node edge calculations system based on docker container
CN105893113A (en) Management system and management method of virtual machine
CN106130960B (en) Judgement system, load dispatching method and the device of steal-number behavior
CN110347651A (en) Method of data synchronization, device, equipment and storage medium based on cloud storage
CN109271257A (en) A kind of method and apparatus of virtual machine (vm) migration deployment
CN106227587A (en) A kind of band snapshot virtual machine complete machine dynamic migration method and device
CN103647656A (en) Billing node load control method, data access control method and node
CN107479947A (en) A kind of energy consumption of virtual machine optimization method and system
CN106775949A (en) A kind of Application of composite feature that perceives migrates optimization method online with the virtual machine of the network bandwidth
CN107357630A (en) A kind of method, apparatus and storage medium for realizing that virtual machine is synchronous
CN115033340A (en) Host selection method and related device
US11409453B2 (en) Storage capacity forecasting for storage systems in an active tier of a storage environment
CN108540405B (en) Network resource migration method and device
CN107193649A (en) A kind of method for scheduling task and device based on NUMA system
CN104881467A (en) Data correlation analysis and pre-reading method based on frequent item set
CN112000460A (en) Service capacity expansion method based on improved Bayesian algorithm and related equipment
CN106201839A (en) The information loading method of a kind of business object and device
CN109995787A (en) A kind of data processing method and relevant device
CN107168795B (en) Codon deviation factor model method based on CPU-GPU isomery combined type parallel computation frame

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
EXSB Decision made by sipo to initiate substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant