Windows 11 wsl2 does not work

lordsnoake

New Member
Feb 19, 2023
3
0
1
Hello,
I have been having issues with windows 11 wsl2 working under proxmox.
I am fairly new so i am just going to go based off on the threads that i saw of the information that i might be asked for.

This is the configuration from my vm. I added the args based on another thread that i saw that i thought might helped but unfortunately it did not.
This is the thread https://forum.proxmox.com/threads/cant-get-wsl2-to-work-on-win11-under-proxmox-7-2-ve.115582/
I also followed the nested virtualization guide (https://pve.proxmox.com/wiki/Nested_Virtualization) but no avail as well

Code:
args: hv_relaxed,hv_vapic,hv_spinlocks=0x1fff,hv_vpindex,hv_runtime,hv_crash,hv_time,hv_synic,hv_stimer,hv_tlbflush,hv_ipi,hv_reset,hv_frequencies...
bios: ovmf
boot: order=ide0;ide2;net0
cores: 16
cpu: host
efidisk0: wd_blue_three_td_hdd:vm-105-disk-0,efitype=4m,pre-enrolled-keys=1,size=4M
ide0: wd_blue_three_td_hdd:vm-105-disk-1,size=1000G
ide2: local:iso/Win11_22H2_English_x64v1.iso,media=cdrom,size=5427180K
machine: pc-q35-7.1
memory: 32000
meta: creation-qemu=7.1.0,ctime=1676776066
name: dev
net0: e1000=0E:C7:CF:57:BA:30,bridge=vmbr0,firewall=1
numa: 0
ostype: win11
scsihw: virtio-scsi-single
smbios1: uuid=75334601-012a-4865-8a3f-3557162e2db0
sockets: 1
tpmstate0: wd_blue_three_td_hdd:vm-105-disk-2,size=4M,version=v2.0
vmgenid: 6c9ec98e-50b4-47cf-bb11-311160eff844

This is my
Code:
pveversion -v

Code:
root@proxmox:/etc/pve/qemu-server# pveversion -v
proxmox-ve: 7.3-1 (running kernel: 5.15.74-1-pve)
pve-manager: 7.3-3 (running version: 7.3-3/c3928077)
pve-kernel-5.15: 7.2-14
pve-kernel-helper: 7.2-14
pve-kernel-5.15.74-1-pve: 5.15.74-1
ceph-fuse: 15.2.17-pve1
corosync: 3.1.7-pve1
criu: 3.15-1+pve-1
glusterfs-client: 9.2-1
ifupdown2: 3.1.0-1+pmx3
ksm-control-daemon: 1.4-1
libjs-extjs: 7.0.0-1
libknet1: 1.24-pve2
libproxmox-acme-perl: 1.4.2
libproxmox-backup-qemu0: 1.3.1-1
libpve-access-control: 7.2-5
libpve-apiclient-perl: 3.2-1
libpve-common-perl: 7.2-8
libpve-guest-common-perl: 4.2-3
libpve-http-server-perl: 4.1-5
libpve-storage-perl: 7.2-12
libspice-server1: 0.14.3-2.1
lvm2: 2.03.11-2.1
lxc-pve: 5.0.0-3
lxcfs: 4.0.12-pve1
novnc-pve: 1.3.0-3
proxmox-backup-client: 2.2.7-1
proxmox-backup-file-restore: 2.2.7-1
proxmox-mini-journalreader: 1.3-1
proxmox-widget-toolkit: 3.5.3
pve-cluster: 7.3-1
pve-container: 4.4-2
pve-docs: 7.3-1
pve-edk2-firmware: 3.20220526-1
pve-firewall: 4.2-7
pve-firmware: 3.5-6
pve-ha-manager: 3.5.1
pve-i18n: 2.8-1
pve-qemu-kvm: 7.1.0-4
pve-xtermjs: 4.16.0-1
qemu-server: 7.3-1
smartmontools: 7.2-pve3
spiceterm: 3.2-2
swtpm: 0.8.0~bpo11+2
vncterm: 1.7-1
zfsutils-linux: 2.1.6-pve1

Not really sure what else to do or what guide to follow.
Any help or a guide is greatly appreciated.
 
HI, what issues exactly are you having with wsl?

From your config it looks like you didn't set scsi as the drive controller. Did you follow the windows 11 best practices [1]? And did you install the VirtIO drivers? If not, maybe create a new vm following the best practices and test if wsl works then. (Don't forget to set the cpu to `host`, I don't think that's in the best practice guide). Don't bother setting the extra args in your conf for now.

Also, did you install wsl correctly? You need to run wsl --install as admin in powershell, then reboot and download whatever linux distro you want from the microsoft store. If it errors at first and tells you to activate something or other, google the error; you might need to change some windows settings.

Best of luck :)

PS: I don't know how much ram your host has, but if you want to use 32 GiB ram you want 32768 MiB not 32000, see [2].

[1]: https://pve.proxmox.com/wiki/Windows_2022_guest_best_practices
[2]: https://en.wikipedia.org/wiki/Byte#Multiple-byte_units
 
Last edited:
glad to hear :)
would you mind sharing what exactly the problem was and how you fixed it for other users who might find this thread?
 
The following run as admin user in cmd worked for me on win11 wsl2 for ubuntu


Code:
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
 

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!