Hyper-V Turn Off vs Shutdown, they seem similar, but apparently, they are 2 different options on Hyper-V and other hypervisors. So, what is the difference between them? I will answer it in this article.
Simple question, when I am in Hyper-V manager there are two options that seem similar but I am sure they are different. "Turn Off..." and "Shut Down..." What do they each do?
- Question from serverfault.com
Hyper-V is one of the most popular Type-1 hypervisors. You may also be bothered by the 2 Hyper-V power options “Turn Off” and “Shut Down” which seem to have similar functions, as in the case above. They both seem to refer to closing the virtual machine, but since they are listed as 2 different options, there must also be some differences in their functions.
In this article, I will answer what’s the difference between Hyper-V turn off vs shutdown, and introduce other power options that may confuse you.
Right-click on the name of the running virtual machine on Hyper-V Manager, you can see the power options including Turn Off… and Shut Down…. What do they each refer to? What happens when you turn off a virtual machine? And what is the difference between turn off and shut down?
Here are the explanations:
Except for the dropping menu of Hyper-V VMs, you can also see these options in VM Settings > Management > Automatic Stop Action. You can select what this virtual machine will do when the physical computer shuts down.
Therefore, if you want to save the current state of your virtual machine and take care of the software and guest OS, you should choose to Shut Down your virtual machine. But if your virtual machine is not responding, and you backed up Hyper-V virtual machines or are prepared for the possible data loss, then you may choose to Turn Off the VM.
Sometimes your VM is totally frozen or just not responding, forcibly turning off it may cause more or less data loss. It is recommended that you backup your VMs before such risky operations. You can try free virtual machine backup software -- AOMEI Cyber Backup to backup VMs in simple steps. More »
Just like Hyper-V turn off vs shutdown, there are other virtual machine power options that are confusing to people unfamiliar with virtual machines. For example, the same confusion may also lie in Hyper-V reset vs turn off.
As Shut Down is a software level action, Turn Off and Reset are BIOS level actions. Therefore, you should use Reset command only in emergency situation when your Hyper-V VM is totally frozen.
Except for Hyper-V, there are also same confusion of power options on VMware. For example, what is the difference between reset and restart in VMware.
As you can see, Turn Off can be a risky operation and better be used only when the virtual machine is totally frozen or unresponsive, otherwise you may run into errors such as Hyper-V VM stuck in the stopping state, and possibly receive an error message Hyper-V failed to change state.
But what if the Turn Off, Shut Down, and Reset options are all unavailable? In this situation, you may need to using PowerShell commands to forcibly kill a frozen Hyper-V VM. Before you start, please remember to backup your VMs to avoid unexpected data loss.
1. Launch Windows PowerShell, and run the following command to get the VM’s GUID:
$VMGUID = (Get-VM "VMNAME").ID
2. Find the vmwp.exe process identifier (PID) for this VMGUID:
$VMWMProc = (Get-WmiObject Win32_Process | ? {$_.Name -match 'VMWP' -and $_.CommandLine -match $VMGUID})
3. Then, using the Stop-Process command, you must force-terminate this process:
Stop-Process ($VMWMProc.ProcessId) –Force
If you are not familiar with hypervisors and virtual machines, you may be confused by those power options that look functionally alike. And even minor mistake may cause serious consequences.
Therefore, in this article, I analyzed what is the difference between Hyper-V Turn Off vs Shutdown and other virtual machine power options, and introduced 1 way to kill the Hyper-V VM stuck in the stopping state.
Before you doing such a risky operation, please remember to backup your VMs to avoid unexpected errors. The best way to protect your VM data is to perform regular backups following the 3-2-1 backup rule.