Cannot get nested virtualization to work in Windows 11, running inside of proxmox 8. Intel 13th gen CPU, NVIDIA GPU

jdaw

New Member
Aug 30, 2023
5
0
1
When I enable wsl2 through windows platform, win11 vm immediately starts to boot into advanced recovery console. Any advice?

I run Windows 11 as vm inside of proxmox 8. I successfully set gpu passthrough, and I am able to run Nvidia GPU inside of Win11. I can run games, furmark etc.

But when I try to run "Ubuntu" WSL2 in Windows, I get an error

Code:
    WslRegisterDistribution failed with error: 0x80370102
    Please enable the Virtual Machine Platform Windows feature and ensure virtualization is enabled in the BIOS.

As soon as I enable Virtual Machine Platform in Windows Features, windows stops to boot and immediately falls into Advanced Recovery Mode during startup. The only way to get it back is to manually load vsscsi driver there and then use the following command to disable hyperv/windows virtualization

Code:
    bcdedit /set hypervisorlaunchtype off

I went through many tutorials/forums. Already tried *-kvm* arg in vm configuration, tried *hidden=1* in various combinations. The result is the same all the time.

I understand that I can easily create another VM on host proxmox and ssh there, but I still would like to have ability to run WSL.

VM Configuration:

Code:
agent: 1
    args: -cpu host,-hypervisor,+vmx
    balloon: 0
    bios: ovmf
    boot: order=scsi1;net0;hostpci0;ide0;ide2
    cores: 32
    cpu: host,hidden=1
    efidisk0: local-lvm:vm-101-disk-2,efitype=4m,pre-enrolled-keys=1,size=4M
    hostpci0: 0000:01:00,pcie=1,x-vga=1
    hostpci1: 0000:00:14,pcie=1
    ide2: local:iso/virtio-win.iso,media=cdrom,size=522284K
    kvm: 1
    machine: pc-q35-8.0
    memory: 61440
    meta: creation-qemu=8.0.2,ctime=1692921033
    name: winvm
    net0: e1000=CE:84:8B:44:AF:AB,bridge=vmbr0,firewall=1
    numa: 0
    ostype: win11
    scsi1: /dev/disk/by-id/nvme-Samsung_SSD_990_PRO_2TB_S73WNJ0W320367J,size=1953514584K
    scsihw: virtio-scsi-single
    smbios1: uuid=9eb9d91e-9f15-4202-a969-3cad45232285
    sockets: 1
    tpmstate0: local-lvm:vm-101-disk-0,size=4M,version=v2.0
    vmgenid: 8a838a99-4567-472c-90bb-27991d71b95b

Relevant parts of systeminfo output in Windows 11 vm


Code:
OS Name:                   Microsoft Windows 11 Pro
    OS Version:                10.0.22621 N/A Build 22621
    Processor(s):              1 Processor(s) Installed.
                            [01]: Intel64 Family 6 Model 183 Stepping 1 GenuineIntel ~2995 Mhz
    BIOS Version:              EFI Development Kit II / OVMF 3.20230228-4, 6/6/2023
    Hyper-V Requirements:      VM Monitor Mode Extensions: Yes
                           Virtualization Enabled In Firmware: Yes
                           Second Level Address Translation: Yes
                           Data Execution Prevention Available: Yes
 
The only way I have been able to get this to work is to add the following to your vm config:

Code:
args: -cpu Cooperlake,hv_relaxed,hv_spinlocks=0x1fff,hv_vapic,hv_time,+vmx
cpu: host

See for reference: https://forum.proxmox.com/threads/a...virtualization-not-working.125987/post-581185

Of course doing this will disable the ability to do GPU passthrough of the onboard Intel Iris Xe graphics in my case. I do not know if you will still be able to passthrough an external GPU.
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!