Skip to content
ohsudo, Home
Windows

WSL "WslRegisterDistribution failed with error: 0x80370102": turn on virtualization

Fix WSL "WslRegisterDistribution failed with error: 0x80370102": enable virtualization in the firmware, Virtual Machine Platform, the hypervisor or nested virtualization.

Beginner3 min readApplies to WSL 2 · Windows 10 2004+ · Windows 11 · Windows Server 2022+

by OhSudo ··

You install Ubuntu in WSL, and it stops on the first run:

WslRegisterDistribution failed with error: 0x80370102
Error: 0x80370102 The virtual machine could not be started because a required feature is not installed.

Newer versions of WSL may say it another way:

Wsl/Service/RegisterDistro/CreateVm/HCS/HCS_E_HYPERV_NOT_INSTALLED

WSL 2 runs a real Linux kernel in a lightweight virtual machine. The error means that machine can’t start, because something it needs is switched off. There are four usual suspects, and one of them is outside Windows: the firmware.

  1. FirmwareCPU virtualization (VT-x / AMD-V)
  2. Windows featuresVirtual Machine Platform
  3. Hypervisorstarted at boot
  4. WSL 2 virtual machinecan't start: 0x80370102(breaks here)
WSL 2 runs a real Linux kernel in a lightweight virtual machine. Every layer below it must be on, starting outside Windows, in the firmware.

TL;DR

In an administrator PowerShell:

Terminal window
systeminfo | Select-String "Virtualization|Hyper-V|hypervisor"
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
bcdedit /set hypervisorlaunchtype auto

Restart. If systeminfo said virtualization is off in the firmware, enable it there too (section 2).

1. See what’s missing

Terminal window
systeminfo | Select-String "Virtualization|Hyper-V|hypervisor"

Two kinds of answers:

Hyper-V Requirements: Virtualization Enabled In Firmware: No

That points at section 2. Or:

Hyper-V Requirements: A hypervisor has been detected. Features required for Hyper-V will not be displayed.

That means the hardware side is fine, and a hypervisor is running. The Performance tab in Task Manager shows the same thing: CPU → Virtualization: Enabled.

2. Enable virtualization in the firmware

If it’s off, no Windows setting will help. Restart, enter the BIOS/UEFI setup (usually F2, F10, F12 or Del during boot), and look for:

  • Intel VT-x or Intel Virtualization Technology, on Intel machines;
  • SVM Mode or AMD-V, on AMD machines.

It’s often under Advanced, CPU Configuration or Security. Enable it, save, and restart.

3. Enable the Windows features

WSL 2 needs Virtual Machine Platform, which is separate from WSL itself:

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

Restart, then bring WSL up to date and try again:

Terminal window
wsl --update
wsl --set-default-version 2
wsl --install -d Ubuntu

4. The hypervisor is turned off

Some guides, and some older emulators and virtualization tools, turn off the Windows hypervisor at boot. Features can then be on, and WSL still fails. Check:

Terminal window
bcdedit /enum | Select-String hypervisorlaunchtype

If it says Off, turn it back on and restart:

Terminal window
bcdedit /set hypervisorlaunchtype auto

5. Windows itself runs in a virtual machine

Then the machine has to pass virtualization through to Windows. This is nested virtualization, and it’s set on the host, with the VM powered off.

On a Hyper-V host:

Terminal window
Set-VMProcessor -VMName "MyWindowsVM" -ExposeVirtualizationExtensions $true

In VMware, enable Virtualize Intel VT-x/EPT or AMD-V/RVI in the VM’s processor settings. In VirtualBox, it’s Enable Nested VT-x/AMD-V.

In the cloud, it depends on the machine type: on Azure, choose a size that supports nested virtualization. If a provider doesn’t offer it, use WSL 1 (next section).

6. When you can’t enable it: WSL 1

WSL 1 doesn’t use a virtual machine, so none of this applies:

Terminal window
wsl --set-default-version 1
wsl --install -d Ubuntu
wsl --list --verbose

It’s a real option for scripts and command-line tools. It has no real Linux kernel, though, so Docker and other programs that rely on kernel features won’t run in it.

Warning

A failed install can leave a half-registered distribution behind. If the error stays after the fix, remove it with wsl --unregister Ubuntu and install again. That command deletes the distribution’s files, so only use it when there’s nothing in it to keep.

Shell, we have a problem!

Similar, but different: 0x8007019e means the Windows Subsystem for Linux feature isn’t enabled at all. 0x800701bc means the WSL 2 kernel needs updating: run wsl --update. 0x80370114 usually means a Windows security setting blocks the virtual machine (the Exploit Protection control flow guard override for vmcompute.exe). For virtual machines under Hyper-V, see the hypervisor is not running. For Docker Desktop’s own message, see WSL 2 installation is incomplete.

Found this useful? Share it.

Found a mistake? Let us know at contact@ohsudo.com.

Articles

Related articles