Hypervisor-driven hibernation
AssigneeRed Hat Israel, Ltd.
InventorsMichael Tsirkin, Dor Laor
Life of this patent
Estimating the term…
Abstract
A system and method for hibernating virtual machines (VMs) are disclosed. In accordance with one embodiment, a computer system that executes a hypervisor and a virtual machine (VM) determines that the virtual machine is to be put to sleep, wherein the determining is performed without involvement of a guest operating system hosted by the virtual machine. In response, the hypervisor stops a first virtual processor of the VM and persists the state of the first virtual processor.
Claims10
A method comprising:
- executing, by a processing device, a hypervisor;
- identifying a first virtual machine that is executing and a second virtual machine that is executing, the first virtual machine comprising a plurality of virtual processors;
- determining, by the hypervisor, that the first virtual machine is to be hibernated while the second virtual machine remains awake, wherein the determining is performed without involvement of a guest operating system hosted by the first virtual machine;
- stopping by the hypervisor, in view of the determining, a first virtual processor of the plurality of virtual processors of the first virtual machine;
- persisting, by the hypervisor, a state of the stopped first virtual processor;
- and
- in response to a hardware fault that occurs after the stopping of the first virtual processor and the persisting of the state of the stopped first virtual processor, re-starting, by the hypervisor, the stopped first virtual processor, the re-starting comprising loading the state of the stopped first virtual processor.
An apparatus comprising:
- a memory to store a first virtual machine and a second virtual machine;
- and
- a processing device, operatively coupled to the memory, to execute the first virtual machine, the second virtual machine, and a hypervisor, wherein the processing device is to execute the hypervisor to:
- identify the first virtual machine and the second virtual machine, the first virtual machine comprising a plurality of virtual processors;
- determine that the first virtual machine is to be hibernated while the second virtual machine remains awake, wherein the determining is performed without involvement of a guest operating system hosted by the first virtual machine;
- stop, in view of the determining, a first virtual processor of the plurality of virtual processors of the first virtual machine;
- persist a state of the stopped first virtual processor;
- and
- in response to a clock event that occurs after the stopping of the first virtual processor and the persisting of the state of the stopped first virtual processor, re-start the stopped first virtual processor, the re-starting comprising loading the state of the stopped first virtual processor.
A non-transitory computer readable storage medium, having instructions stored therein, which when executed, cause a processing device to:
- execute, by the processing device, a hypervisor;
- identify a first virtual machine that is executing and a second virtual machine that is executing, the first virtual machine comprising a plurality of virtual processors;
- stop, via the hypervisor, a first virtual processor of the plurality of virtual processors of the first virtual machine while the second virtual machine remains awake, wherein the first virtual machine hosts a guest operating system that has no power management capability;
- persist, via the hypervisor, a state of the stopped first virtual processor;
- and
- in response to a hardware fault that occurs after the stopping of the first virtual processor and the persisting of the state of the stopped first virtual processor, re-start, via the hypervisor, the stopped first virtual processor, the re-starting comprising loading the state of the stopped first virtual processor.
Dependencies are inferred from the claim text.