Virtual machines can be provided in a computer to enhance flexibility and performance. A virtual machine typically refers to some arrangement of components (software and/or hardware) for virtualizing or emulating an actual computer, where the virtual machine can include an operating system and software applications. Virtual machines can allow different operating systems to be deployed on the same computer, such that applications written for different operating systems can be executed in different virtual machines (that contain corresponding operating systems) in the same computer. Moreover, the operating system of a virtual machine can be different from the host operating system that may be running on the computer on which the virtual machine is deployed.
In addition, a greater level of isolation is provided between or among applications running in different virtual machines. In some cases, virtual machines also allow multiple applications to more efficiently share common resources (processing resources, input/output or I/O resources, and storage resources) of the computer
For enhanced performance, virtual machines can be provided on multiple computers that are interconnected by a network. When deploying virtual machines on multiple computers, a human administrator usually has to decide at virtual machine creation time on which physical machine the virtual machine should be deployed. Often, placement of virtual machines is typically performed manually by an administrator. Although some systems are able to provide some indication to the administrator that migrating a virtual machine from one computer to another computer would be desirable, the actual selection of which computer a virtual machine should be migrated to is performed manually by the human administrator. Such manual placement of virtual machines by a human administrator is typically a time-consuming process and often does not lead to optimal or even better placement of virtual machines.
Although some techniques have been proposed to automate the migration of virtual machines across physical machines in response to various conditions, it is noted that such automated migration techniques do not consider some factors that may be relevant to effective or efficient execution of virtual machines.
Some embodiments of the invention are described, by way of example, with respect to the following figures:
A data center refers to some collection of computing resources, whether geographically concentrated or dispersed, that are able to cooperate to provide computing tasks for one or more clients. In one example, data centers 1 and 2 depicted in
Each physical machine includes one or more virtual machines. In the example of
A physical machine can be located within one cabinet (or rack), or alternatively, the physical machine can be located in multiple cabinets (or racks). The physical machines in each data center are interconnected by respective local networks (network 130 in data center 1 and network 132 in data center 2). In the example of
The data centers are interconnected by a global data network 134, which can be the Internet, a wide area network, or any other type of network. The term “network” is intended to refer to either a single network or some collection of multiple networks.
Examples of physical machines include computers, communications modules (e.g., switches, routers, etc.), and other types of machines. A physical machine indicates that the machine is an actual machine made up of software and hardware. Although each of the physical machines is depicted as being contained within a box, it is noted that a physical machine can be a distributed machine having multiple nodes that provide a distributed and parallel processing system.
A virtual machine refers to some partition or segment (made up of software and/or hardware) of the physical machine that is provided to virtualize or emulate a physical machine. From the perspective of a user, a virtual machine looks just like a physical machine. According to some embodiments, a virtual machine includes one or more software applications, an operating system, and one or more device drivers (which are typically part of the operating system).
It is noted that the operating systems that are part of corresponding virtual machines within a physical machine can be different types of operating systems or different versions of an operating system. This allows software applications designed for different operating systems to execute on the same physical machine.
The virtual machines within a physical machine are designed to share the physical resources of the physical machine. In the physical machine, these physical resources include the hardware of the physical machine, where the hardware can include one or more central processing units (CPUs), memory (volatile memory and/or persistent storage, such as disk-based storage), a network interface, and other resources (such as a storage area network interface, not shown).
As further depicted in the example of
Each local placement controller 136, 138 is able to determine an efficient placement of the virtual machines across physical machines based on predefined local criteria (according to a target policy set by an enterprise, a user, an administrator, etc.). The predefined local criteria according to the policy can include a target quality-of-service level to be provided, loading criteria (which specify some target loading level on a physical resource or machine), balancing criteria (which specify that load on physical machines should be balanced when possible), cooling criteria (which specify temperatures in physical machines that should not be exceeded), power criteria (which specify that power consumption should be reduced where possible), and other criteria. The loading criteria and balancing criteria are examples of distribution criteria in that such criteria tend to encourage distribution of virtual machines across a larger number of physical machines. On the other hand, the cooling criteria and power criteria are examples of consolidation criteria that tend to consolidate virtual machines onto fewer physical machines.
Each local placement controller 136, 138 is able to determine whether the current state of the overall corresponding data center (which includes the multiple physical machines) conforms to the policy. If the local placement controller determines that the state of the data center does not conform to the policy, then the local placement controller 136 can perform a re-evaluation to determine a different placement of virtual machines on physical machines to increase conformance to the policy.
If a different placement is determined by the local placement controller to be desirable, the local placement controller is able to perform migration of virtual machines from one physical machine to another physical machine within the data center. After placement of the virtual machines has been changed (by migration), the local placement controller can subsequently determine whether further migration should be performed. Note that workloads at the physical machines are continually changing. The local placement controller repeatedly checks (in a loop) whether the state of the data center conforms to policy. In effect, the local placement controller provides a feedback-driven mechanism to control the mapping of virtual machines onto physical machines. This feedback-driven mechanism allows automated adjustments of placement of the virtual machines on physical machines. By automating the virtual machine placement control, relatively quick response times can be achieved in changing placements of virtual machines in response to observed or predicted events that affect conformance with policy.
Migrating a virtual machine refers to moving the state of the virtual machine from one physical machine to another physical machine. The state of the virtual machine includes content of registers of various hardware devices (e.g., CPUs, I/O devices, and so forth). Data in memory associated with the migrated virtual machine can also be transferred gradually (e.g., lazily) to the destination physical machine to which the virtual machine is migrated. Control of the migration can be accomplished by using migration control software in the local placement controllers 136, 138, and/or by using migration control software in the physical machines.
The automated placement (initial and dynamic) of virtual machines on physical machines provided by the local placement controller 136, 138 according to some embodiments allows each data center to meet customer quality-of-service (QoS) goals and the data center's cost-of-service (CoS) goals on a given resource (made up of the physical machines in the system).
In addition to performing local placement of virtual machines on physical machines of a data center, the system of
In performing placement of virtual machines, the global placement controller 140 takes into account regional environment effects, which include at least some of the following: availability of alternative power sources such as sunlight, hydroelectric power, wind power, etc.; availability of cool temperature; presence of inclement weather; presence of a natural disaster; presence of civil or military unrest; presence of a regional power outage; and so forth. Generally, the term “regional environment effect” refers to some condition that affects a relatively large geographic region or a relatively large group of physical machines. Such regional environment effects may indicate that executing virtual machines in some geographic regions or on some group of physical machines may not be efficient or effective. For example, availability of sunlight in some geographic regions may mean that an alternative, cheaper source of power is available in such geographic regions. Therefore, it may make sense to migrate virtual machines to physical machines in geographic regions where such alternative source of power is available. Cooling costs are also a concern when executing virtual machines in physical machines. Generally, sophisticated cooling equipment may be used to cool a large number of physical machines in a data center. Such sophisticated cooling equipment may consume relatively large amounts of power and thus, may be expensive to run. Therefore, migrating virtual machines to geographic regions that have cooler weather may reduce the load on cooling equipment, and thus reduce cooling costs. Also, physical machines in geographic regions where inclement weather, a natural disaster, civil or military unrest, and/or power outage have occurred may not be available. Therefore, it may be desirable to migrate virtual machines from such geographic regions to other geographic regions.
In a different embodiment, instead of using separate global and local placement controllers, it is noted that a single-tiered placement controller (or a single-tiered group of placement controllers) can be used to perform control of placement of virtual machines within the data center and across data centers (or geographic regions).
As further depicted in
Next, the global placement controller 140 sends (at 206) command(s) to the appropriate entities to control migration of the selected virtual machine(s) across data centers. The appropriate entities can include local placement controllers 136, 138 and/or the physical machines that are involved.
The tasks of
The global placement controller 140 also includes a migration control module 304 to control the migration of selected virtual machines (selected by the VM layout selector 302) between or among physical machines in different groups. The VM layout selector 302 and migration control module 304 are software modules executable on one or more central processing unit (CPUs) 306 in the global placement controller 140. The CPU(s) is (are) connected to memory 308 and to a network interface 310 to allow the global placement controller 140 to communicate over the global data network 134.
As depicted in the example of
The virtual machines 108 and 110 in the physical machine 100 are designed to share physical resources, including hardware 408, which includes one or more CPUs 410, memory 412, a network interface 414, and other components. The network interface 414 allows each of the virtual machines 108 and 110 to communicate over the local network 130.
The physical machine 100 also includes a virtual machine monitor (VMM) 416, also called a hypervisor, which manages the sharing (by virtual machines 108, 110) of the physical resources, including the hardware 408, of the physical machine 100. The VMM 416 virtualizes the physical resources, including the hardware 408, of the physical machine 100. Also, the VMM 416 intercepts requests for resources from operating systems in the respective virtual machines 108, 110 so that proper allocation of the physical resources of the physical machine 100 can be performed. For example, the VMM 416 manages memory access, input/output (I/O) device access, and CPU scheduling for the virtual machines. Effectively, the VMM 416 provides an interface between the operating system of each virtual machine and the underlying hardware 408 of the physical machine 100. The interface provided by the VMM 416 to an operating system of a virtual machine is designed to emulate the interface provided by the actual hardware of the physical machine 100.
The other physical machine 102 similarly includes a VMM 418 that provides the interface between the virtual machines 112, 114, 116 and the physical resources, including hardware 420, of the physical machine 102.
As further depicted in
The local placement controller 136 also includes a VM layout selector 428 (to perform selection of a layout of the virtual machines mapped to physical machines within data center 1). Additionally, the local placement controller 136 includes a migration control module 430 to control migration of virtual machines from one physical machine to another physical machine (in accordance with the layout selected by the VM layout selector 428). In some implementations, the VM layout selector 428 and migration control module 430 are software modules executable on the CPU 422 of the local placement controller 136.
As noted above, in determining placement of virtual machines onto corresponding physical machines, the local placement controller 136 (more specifically the VM layout selector 428) takes into account various predefined criteria. One type of predefined criteria is related to loading of physical resources or machines. Since there are various different physical resources (e.g., CPU, memory, network interface, storage network, etc.), there are different loading criteria to consider. The different loading criteria thus include a loading criterion relating to the CPU usage, a loading criterion relating to memory usage, a loading criterion relating to network interface usage, a loading criterion relating to storage network usage, and any other loading criteria relating to usage of other resources.
Also, another loading criterion is an overloading criterion, which specifies that any particular physical machine should not be loaded by greater than some predefined threshold (e.g., 80%). If loading of a physical machine exceeds this predefined threshold, then migration of virtual machine(s) from the overloaded physical machine would be desirable.
As noted above, placement of virtual machines should satisfy a QoS goal of the system. This QoS may have been set by a user or by the system. One example QoS goal is the allocation of scheduling shares to each virtual machine within a physical machine. The VMM 416 or 418 according to some implementations includes a scheduler that schedules access to physical resources of the physical machine 100 or 102, where the scheduler in the VMM specifies the number of shares to allocate to each virtual machine.
Other example criteria that are considered by the VM layout selector 428 include cooling and power criteria. During operation, temperatures in physical machines can exceed a temperature threshold. If this occurs, then migration of virtual machines from the over-heated physical machines may be desirable. Cooling criteria can also specify cooling costs. In large data centers, for example, sophisticated cooling equipment is usually provided to cool physical machines. To reduce cooling costs, migration of virtual machines can be performed in a manner that allows some part of the cooling equipment to be turned off (or run in a lower power mode). In one example, virtual machines can be placed such that one or more physical machines can be turned off (or placed in a lower power state), such that corresponding cooling equipment can be shut off (or run in a lower power mode). The lower power state of a physical machine refers to any one of several possible power savings states of such machines, including sleep states, standby states, hibernation states, and so forth.
Power criteria are also considered by the VM layout selector 428. In addition to turning off (or placing into a lower power state) physical machines for the purpose of reducing cooling costs, such action can also be performed for the purpose of reducing power consumption of physical machines (for more efficient usage).
Both the cooling criteria and power criteria are considered consolidation criteria that favor migrating virtual machines onto fewer physical machines so that at least some of the physical machines can be turned off or otherwise placed into an idle state, for cost and power conservation. However, the cooling and power criteria are counter-balanced by some of the other factors, such as loading criteria that tend to favor distributing or spreading virtual machines across a larger number of physical machines.
Another criterion that can be considered by the VM layout selector 428 is the cost of performing migration of a virtual machine. Migrating a virtual machine from one physical machine to another physical machine is associated with a cost (in terms of the virtual machine being unavailable during migration and the bandwidth cost associated with moving data associated with the migrated virtual machine from one storage location to another storage location). If the VM layout selector 428 determines that the benefit of migrating a virtual machine is less than the cost of performing the migration, then the migration should not be performed.
The placement problem for identifying an optimal solution for placement of virtual machines on physical machines is a relatively complex problem. For a large system having many physical machines and virtual machines, the computation time for identifying the optimal placement of virtual machines can be very large. In accordance with an embodiment, a simulated annealing technique can be used to find an approximation of a globally optimal placement of virtual machines on physical machines. Generally, simulated annealing considers a current set (that represents some random placement of virtual machines on physical machines), and iteratively adjusts the current set until a better set can be identified. The simulated annealing algorithm attempts to replace a current solution with a random “nearby” solution. A new set that is more optimal than the current set is used as the new current set, and this process repeats until an approximated optimal solution is identified.
The simulated annealing algorithm performed by the VM layout selector 302 in the global placement controller 140 (
A flow diagram of a process performed by the VM layout selector 302 (
The VM layout selector then evaluates (at 506) the cost function based on the terms derived from the measured parameters. The cost function produces an output that provides some indication of the performance of the particular placement of virtual machines on physical machines (such as in the form of a goodness rating or some other indicator). Next, the VM layout selector searches (at 508) for a better layout that represents another placement of virtual machines on physical machines.
If a better virtual machine layout is found in the search (at 508) for the better layout, the VM layout selector causes the migration control module (304 in
The VM layout selector determines (at 512) if the process at 504-510 is to be repeated. Repetition of the process at 504-510 can be performed periodically or in response to predefined events (e.g., detection of overheating, alarm indicating some fault has occurred, indication of overloading, and/or change in regional environment effects, etc.).
Instructions of software described above (including the VM layout selector 302 or 428, migration control module 304 or 430) are loaded for execution on a processor (such as one or more CPUs). The processor includes microprocessors, microcontrollers, processor modules or subsystems (including one or more microprocessors or microcontrollers), or other control or computing devices. As used here, a “processor” can refer to a single component or to plural components.
Data and instructions (of the software) are stored in respective storage devices, which are implemented as one or more machine-readable storage media. The storage media include different forms of memory including semiconductor memory devices such as dynamic or static random access memories (DRAMs or SRAMs), erasable and programmable read-only memories (EPROMs), electrically erasable and programmable read-only memories (EEPROMs) and flash memories; magnetic disks such as fixed, floppy and removable disks; other magnetic media including tape; and optical media such as compact disks (CDs) or digital video disks (DVDs). Note that the instructions of the software discussed above can be provided on one computer-readable or computer-usable storage medium, or alternatively, can be provided on multiple computer-readable or computer-usable storage media distributed in a large system having possibly plural nodes. Such computer-readable or computer-usable storage medium or media is (are) considered to be part of an article (or article of manufacture). An article or article of manufacture can refer to any manufactured single component or multiple components.
In the foregoing description, numerous details are set forth to provide an understanding of the present invention. However, it will be understood by those skilled in the art that the present invention may be practiced without these details. While the invention has been disclosed with respect to a limited number of embodiments, those skilled in the art will appreciate numerous modifications and variations therefrom. It is intended that the appended claims cover such modifications and variations as fall within the true spirit and scope of the invention.
This Application claims the benefit of U.S. Provisional Application Ser. No. 61/004,869, filed Nov. 30, 2007, titled “Migration Of A Virtual Machine In Response To Regional Environment Effects”
Number | Name | Date | Kind |
---|---|---|---|
5745735 | Cohn | Apr 1998 | A |
5802062 | Gehani | Sep 1998 | A |
6321337 | Reshef | Nov 2001 | B1 |
6421739 | Holiday | Jul 2002 | B1 |
6732139 | Dillenberger et al. | May 2004 | B1 |
6901522 | Buch | May 2005 | B2 |
6934952 | Sarkar | Aug 2005 | B2 |
6944699 | Bugnion | Sep 2005 | B1 |
6970902 | Moon | Nov 2005 | B1 |
6985951 | Kubala | Jan 2006 | B2 |
7089558 | Baskey | Aug 2006 | B2 |
7127625 | Farkas | Oct 2006 | B2 |
7174381 | Gulko | Feb 2007 | B2 |
7203944 | van Rietschote | Apr 2007 | B1 |
7480908 | Tene | Jan 2009 | B1 |
7519964 | Islam | Apr 2009 | B1 |
7856549 | Wheeler | Dec 2010 | B2 |
7925923 | Hyser et al. | Apr 2011 | B1 |
20010034752 | Kremien | Oct 2001 | A1 |
20020194389 | Worley | Dec 2002 | A1 |
20040010787 | Traut | Jan 2004 | A1 |
20040117539 | Bennett | Jun 2004 | A1 |
20040186920 | Birdwell | Sep 2004 | A1 |
20040193476 | Aerdts | Sep 2004 | A1 |
20050039180 | Fultheim | Feb 2005 | A1 |
20050060590 | Bradley et al. | Mar 2005 | A1 |
20050149940 | Calinescu | Jul 2005 | A1 |
20050166074 | Hack | Jul 2005 | A1 |
20050166075 | Hack | Jul 2005 | A1 |
20050246505 | McKenney | Nov 2005 | A1 |
20050251802 | Bozek et al. | Nov 2005 | A1 |
20050278722 | Armstrong | Dec 2005 | A1 |
20060005189 | Vega et al. | Jan 2006 | A1 |
20060023884 | McKee | Feb 2006 | A1 |
20060041733 | Hyser | Feb 2006 | A1 |
20060075067 | Blackmore | Apr 2006 | A1 |
20060136913 | Sameske | Jun 2006 | A1 |
20060149906 | Misra | Jul 2006 | A1 |
20060195715 | Herington | Aug 2006 | A1 |
20060200819 | Cherkasova | Sep 2006 | A1 |
20060200820 | Cherkasova | Sep 2006 | A1 |
20060200821 | Cherkasova | Sep 2006 | A1 |
20060230407 | Rosu | Oct 2006 | A1 |
20070043860 | Pabari | Feb 2007 | A1 |
20070067435 | Landis | Mar 2007 | A1 |
20070079307 | Dhawan | Apr 2007 | A1 |
20070083642 | Diedrich | Apr 2007 | A1 |
20070124474 | Margulis | May 2007 | A1 |
20070171921 | Wookey et al. | Jul 2007 | A1 |
20070180280 | Bolan | Aug 2007 | A1 |
20070180436 | Travostino et al. | Aug 2007 | A1 |
20070180448 | Low et al. | Aug 2007 | A1 |
20070180450 | Croft et al. | Aug 2007 | A1 |
20070186212 | Mazzaferri et al. | Aug 2007 | A1 |
20070260417 | Starmer et al. | Nov 2007 | A1 |
20080104587 | Magenheimer | May 2008 | A1 |
20080104608 | Hyser | May 2008 | A1 |
20090031307 | Chodroff et al. | Jan 2009 | A1 |
20090228726 | Malik et al. | Sep 2009 | A1 |
20100057529 | Boss et al. | Mar 2010 | A1 |
Number | Date | Country | |
---|---|---|---|
61004869 | Nov 2007 | US |