Created attachment 1210827 [details] virt-host-validate in Fedora 24 live guest Description of problem: Trying to enable Hyper-V in Windows 10 / Server 2016 guest resulted in error: "Virtualization support is disabled in the firmware." systeminfo report: Hyper-V Requirements: A hypervisor has been detected. Features required for Hyper-V will not be displayed. systeminfo report with <feature policy='disable' name='hypervisor'/>: Hyper-V Requirements: VM Monitor Mode Extensions: Yes Virtualization Enabled In Firmware: No Second Level Address Translation: Yes Data Execution Prevention Available: Yes C:\>wmic cpu get VirtualizationFirmwareEnabled VirtualizationFirmwareEnabled FALSE PS C:\> (Get-CimInstance Win32_Processor).VirtualizationFirmwareEnabled False virt-host-validate in Fedora 24 live guest: All check PASS except IOMMU, details in attachment Version-Release number of selected component (if applicable): Fedora 24 kernel-4.7.6-200.fc24.x86_64 qemu-system-x86-2:2.6.2-1.fc24.x86_64 qemu-kvm-2:2.6.2-1.fc24.x86_64 libvirt-1.3.3.2-1.fc24.x86_64 How reproducible: Every time Steps to Reproduce: 1. Install Windows 10 / Server 2016 guest 2. Try to enable Hyper-V 3. Hyper-V cannot be installed with error message Actual results: Nested virtualization worked Expected results: KVM in KVM seem work but Hyper-V does not Additional info: Hyper-V in Hyper-V guide https://msdn.microsoft.com/en-us/virtualization/hyperv_on_windows/user_guide/nesting
PowerShell check PS C:\> (Get-CimInstance Win32_Processor).SecondLevelAddressTranslationExtensions True PS C:\> (Get-CimInstance Win32_Processor).VirtualizationFirmwareEnabled False PS C:\> (Get-CimInstance Win32_Processor).VMMonitorModeExtensions True PS C:\> (Get-CimInstance Win32_OperatingSystem).DataExecutionPrevention_Available True WMIC check C:\>wmic cpu get SecondLevelAddressTranslationExtensions SecondLevelAddressTranslationExtensions TRUE C:\>wmic cpu get VirtualizationFirmwareEnabled VirtualizationFirmwareEnabled FALSE C:\>wmic cpu get VMMonitorModeExtensions VMMonitorModeExtensions TRUE C:\>wmic os get DataExecutionPrevention_Available DataExecutionPrevention_Available TRUE
Hi, please provide domain XML of the windows guest, I've tested it and it works so I guess that your XML doesn't enable the correct cpu feature for windows guest.
I have try to use the fedora-virt-preview and kernel-vanilla-stable repo and now it work with these packages (just add the repo and upgrade, no need to change the guest xml) kernel-4.8.1-1.vanilla.knurd.1.fc24.x86_64 libvirt-2.2.0-1.fc24.x86_64 qemu-kvm-2:2.7.0-3.fc24.x86_64 qemu-system-x86-2:2.7.0-3.fc24.x86_64
It seem to soon to tell. So the qemu 2.7 packages enable Windows 10 / Server to install Hyper-V, newer kernel or libvirt is not needed. But Hyper-V still not working correctly. When add this tag <feature policy='disable' name='hypervisor'/>, Hyper-V cannot start VM with error: "Virtual Machine could not be started because the hypervisor is not running" Without this tag, there is this error "Failed to start the virtual machine because one of the Hyper-V components is not running." and in Device Manager, this component "Microsoft Hyper-V Virtual Machine Bus Provider" report "Windows cannot initialise the device driver for this hardware. (Code 37)"
This comment was flagged as spam, view the edit history to see the original text if required.
It seem we need qemu 2.7 and kernel 4.10 to make Hyper-V on QEMU/KVM work. You may want to check this, I have not test this yet https://ladipro.wordpress.com/2017/02/24/running-hyperv-in-kvm-guest/
I just have sometime to test with kernel 4.10 and it seems working. I have not try to install OS yet, just try to boot VM, work with both gen. I am using kernel from Kernel vanilla repositories. I only need <cpu mode='host-passthrough'>, not <feature policy='require' name='vmx'/>. I think host-passthrough already pass the vmx flag. fc24 kernel-4.10.1-1.vanilla.knurd.1.fc24.x86_64 @kernel-vanilla-stable qemu-kvm-2:2.7.0-8.fc24.x86_64 @fedora-virt-preview libvirt-2.2.0-2.fc24.x86_64 @fedora-virt-preview