Today we found out that there was a patch messing with our Hyper-V host running Windows 2019, and that it broke how the Hyper-V manager shows the VMs. This patch was possibly KB5022286, but we are not sure at this time.
The Hyper-V manager showed only 2 VMs but we had 10 VMs running.
When doing a get-vm via powershell, most of the VMs were started but they were not shown on the Hyper-V manager:
After checking the event logs under “Applications and Services Logs”, “Microsoft”, “Windows”, “Hyper-V-VMMS”, “Admin” we noticed that there was a VM with issues on the configuration file.
To fix this, we need to go over where the configuration files are saved.
Typically, this is under C:\ProgramData\Microsoft\Windows\Hyper-V\
Once you identify the linked file to the VM that’s issuing the log entry, delete this file. We can register the VM later on.
After deleting the file, restart the Hyper-V service “Hyper-V Virtual Machine Management Service” via services.msc
You can also do the following from an elevated prompt:
sc stop vmms sc start vmms
This won’t cause any downtime, and all your running VMs will be re populated inside the manager.