How do i fix the error "WslRegisterDistribution failed with error: 0x80004005" which comes when I try to install kali linux?

Om Malhotra 35 Reputation points
2023-09-06T08:27:15.4+00:00

I downlaoded kali linux using the command in cmd

wsl -install -d kali-linux

Now whenever I try to open the app the error "WslRegisterDistribution failed with error: 0x80004005" shows up. I tried running cmd as administrator and then typed

kali

Still it shows the same error.

I have already enabled Virtual Machine Platform and Windows subsystem for linux. Changing the version of wsl too has no effect.

Any help would be appreciated!

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
8,168 questions
{count} votes

8 answers

Sort by: Most helpful
  1. Dimitri Baikrich 141 Reputation points
    2023-10-18T23:10:15.3133333+00:00

    I'm not sure if this will help anyone, but I have had the same issue and resolved it by installing the WSL package from the app store.

    For this, open an elevated PowerShell (right-click on PowerShell and "run as Administrator", then run:

    wsl --update
    

    And run Kali again.

    28 people found this answer helpful.

  2. Vanilou 20 Reputation points
    2023-09-20T17:59:14.24+00:00

    I fix the error by installing a previous version of kali given on the page https://learn.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package

    At the end of the page you have the section troublesshouting and Downloading distributions. I downloaded the given version of kali double click on the file, and confirmed that I wanted to reinstall an older version than the one I just installed that give the error.

    launching the previous version works! you can update kali in kali with:
    sudo apt update && sudo apt upgrade -y

    4 people found this answer helpful.

  3. win shaine 10 Reputation points
    2023-09-07T15:21:06.9766667+00:00

    You can try to update WSL first, and after that, rerun the installation.

    2 people found this answer helpful.

  4. Λ H S Ξ N 5 Reputation points
    2023-09-15T18:06:07.7133333+00:00

    Same issue here. Tried both solutions and all things OP mentioned, restarted afterwards, and nothing worked. On top of that, wsl --install -d kali-linux reports that it has already been installed, and launches it. However, wsl --list --all claims that Windows Subsystem for Linux has no installed distributions. 😒

    1 person found this answer helpful.

  5. Limitless Technology 43,941 Reputation points
    2023-09-06T12:27:00.7733333+00:00

    Hello

    Thank you for your question and reaching out.

    Go to the following registry key: ( Please take back up before any changes)

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LxssManager

    On the right pane, locate Start and set the Value Data to 2.

    Exit REGEDIT, and reboot the machine to see if it works.

    --If the reply is helpful, please Upvote and Accept as answer--