Hyper-V How to Fix Virtual machine could not be started because the hypervisor is not running

Hyper-V How to Fix Virtual machine could not be started because the hypervisor is not running

After a client’s power failure where the UPS failed to properly shutdown the Hyper-V Server, VMs were not able to start.
See below for the error we got every time we tried to start a VM:

Start-vm : ‘win-8-mngmt’ failed to restore virtual machine state. (Virtual Machine ID B790B331-90AD-4D68-B2B4-34B604F849A2) Virtual machine ‘win-8-mngmt’ could not be started because the hypervisor is not running (Virtual machine ID B790B331-90AD-4D68-B2B4-34B604F849A2). the following actions may help you resolve the problem: 

(1) Verify that the processor of the physical computer has a supported version if hardware-assisted virtualization.

(2) Verify that hardware-assisted virtualization and hardware-assisted data execution protection are enabled in the BIOS of the physical computer. (If you edit the BIOS to enable either setting, you must turn off the power to the physical computer and then turn it back on. Resetting the physical computer is not sufficient.)

(3) If you have made changes to the Boot Configuration Data store, review these changes to ensure that the hypervisor is configured to launch automatically.

All VMs were on a saved status and were not able to start.
The Hyper-V’s version was 2012R2.

For our case it seemed that updates that were already installed and run after the reboot of the server created the problem:
The following updates caused the issue: KB5009624 and KB5009624.
So here it is how to uninstall them from command line:

wusa /uninstall /kb:5009624
wusa /uninstall /kb:5009595

Just to be on the safe side, download and install hotfix KB5010794 which fixes this bug.
You must download it manually from the Microsoft Update Catalog.
Download and install from within Hyper-V from this link:

https://www.catalog.update.microsoft.com/Search.aspx?q=KB5010794

In case you want to remove and re install the hyper-V feature use the following Power Shell commands:

Remove-WindowsFeature -Name Hyper-V
Install-WindowsFeature -Name Hyper-V

OTHER PRODUCTS