Windows Subsystem for Linux (WSL) allows users to run a Linux distribution within Windows. However, many users encounter the error message:

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

This issue prevents the installation of a Linux distribution via WSL, particularly in WSL 2, and is often related to missing or misconfigured system features. In this article, we will discuss the common causes and provide step-by-step solutions to resolve the issue.


Why Does This Error Occur?

Several factors can trigger this error when trying to install a Linux distribution via WSL:

  1. Hyper-V and Virtualization are Disabled: WSL 2 requires Hyper-V and hardware virtualization to be enabled.
  2. BIOS Virtualization is Disabled: If hardware virtualization is turned off in the BIOS, WSL 2 cannot function properly.
  3. LxssManager Service is Corrupt or Disabled: This service manages the WSL instances, and if it malfunctions, errors may appear.
  4. Using a Windows Insider Preview Build: Pre-release Windows builds can have bugs that interfere with WSL.
  5. Nested Virtualization is Disabled: Some configurations require nested virtualization to be enabled for Hyper-V.
  6. Dynamic Memory Issues: WSL might not function properly if dynamic memory settings in Hyper-V interfere with resource allocation.

Solutions to Fix the WslRegisterDistribution Error 0x80370102

Solution 1: Enable Hyper-V in Windows

Hyper-V is a key feature required for running WSL 2. Follow these steps to enable it:

  1. Press Win + S and type Turn Windows features on or off.
  2. Click on the matching result to open Windows Features.
  3. Scroll down and check Hyper-V.
  4. Click OK and restart your computer.

After rebooting, check if the error persists.

Solution 2: Enable Hardware Virtualization in BIOS

Hardware virtualization needs to be enabled from the BIOS settings:

  1. Restart your PC and enter BIOS/UEFI by pressing the specific key (usually Esc, F2, F10, or Del) during boot.
  2. Navigate to the Advanced or Performance tab.
  3. Look for Virtualization Technology (VT-x or AMD-V) and enable it.
  4. Save changes and exit BIOS.

Once enabled, boot into Windows and verify if WSL now works.

Solution 3: Enable Virtual Machine Platform

The Virtual Machine Platform is another essential component for WSL 2:

  1. Open Control Panel > Programs > Turn Windows features on or off.
  2. Find Virtual Machine Platform and enable it.
  3. Click OK and restart your computer.

Solution 4: Restart the LxssManager Service

The LxssManager service manages WSL distributions. Restarting it may resolve the error:

  1. Press Win + R, type services.msc, and hit Enter.
  2. Locate LxssManager in the list.
  3. Right-click and select Restart.
  4. Close the window and check if the error is resolved.

Solution 5: Enable Nested Virtualization and Adjust RAM Settings

Nested virtualization allows running virtual machines inside other virtual machines. If WSL is used within a virtualized environment, enabling this might help.

Step 1: Enable Nested Virtualization

  1. Open PowerShell as Administrator.
  2. Run the following command:
    Set-VMProcessor <VMName> -ExposeVirtualizationExtensions $true

    (Replace <VMName> with your actual VM name.)

Step 2: Adjust RAM Settings in Hyper-V

  1. Open Hyper-V Manager.
  2. Right-click on your Virtual Machine and select Settings.
  3. Click Memory in the left panel.
  4. Uncheck Enable Dynamic Memory.
  5. Set the RAM value to at least twice the current value (e.g., 2048MB → 4096MB).
  6. Click Apply and OK.

Restart your virtual machine and check if WSL now functions correctly.

Solution 6: Switch to WSL Version 1

If you don’t require WSL 2, switching to WSL 1 can bypass this issue:

  1. Open PowerShell as Administrator.
  2. Run the following command:
    wsl --set-default-version 1

Now try installing the Linux distribution again.


Conclusion

If you’re experiencing the “WslRegisterDistribution failed with error: 0x80370102” error, the problem is most likely due to missing or disabled system features like Hyper-V, Virtualization, or the Virtual Machine Platform. Follow the solutions above to systematically troubleshoot and resolve the issue.

If none of the methods work, consider updating your Windows version or reinstalling WSL. You can also contact Microsoft support for further assistance.

Categorized in:

How To,