Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WSL 2 requires an update / The update only applies to machines with WSL #5014

Open
nphmuller opened this issue Mar 26, 2020 · 119 comments
Open
Labels
documentation request for documentation improvement workaround-available

Comments

@nphmuller
Copy link

  • Your Windows build number: Microsoft Windows [Version 10.0.19041.153]

  • What you're doing and what's happening:
    I'm starting Ubuntu for Windows and I immediately receive the following message:
    WSL 2 requires an update to its kernel component. For information please visit https://aka.ms/wsl2kernel.
    This has happened before, so I simply go to the website mentioned and download the update. No big deal. But when I run the update this message pops up: This update only applies to machines with the Windows Subsytem for Linux (there's a small typo in the message, by the way).

What do I do now? Seems I'm stuck between updates...

@Jimbles
Copy link

Jimbles commented Mar 27, 2020

I have the same problem with build 19041.172, I have used WSL1 before switching to the insiders program without issue

@onomatopellan
Copy link

onomatopellan commented Mar 27, 2020

For WSL2 you will need 2 Windows components so make sure they are already enabled:
Microsoft-Windows-Subsystem-Linux
VirtualMachinePlatform

Also it seems some people have problems with the installer extracting the kernel.
You can always extract it manually with:
msiexec /a "wsl_update_x64.msi" /qb TARGETDIR="C:\temp"
and then copy the kernel file from C:\temp to C:\Windows\System32\lxss\tools

Final version shouldn't have this problem since the install comes from Windows Update.

@nphmuller
Copy link
Author

@onomatopellan I had WSL2 working already, so I have both enabled. After an update it asked me to update WSL2 manually by downloading and executing the MSI file. On a previous update that worked perfectly and WSL2 worked again after updating. On this update however I receive the error message I described when executing the MSI file.

Thanks for the workaround! I'll try it out next week, when I have the system with this issue available again.

@sandys
Copy link

sandys commented Mar 28, 2020

im having this exact same issue. im on release 2004 (19041.172)

I'm stuck between updates. and my dev system is down.

@sandys
Copy link

sandys commented Mar 28, 2020

ok - i figured out the issue. the new update does not uninstall the old one (the slow insider ring one).

I right clicked the old msi - uninstalled it. now i can install the new one .

@Jimbles
Copy link

Jimbles commented Mar 30, 2020

@sandys Thanks! That worked for me :)

@tasahi
Copy link

tasahi commented Apr 2, 2020

@onomatopellan , thanks. It worked for me just fine. It seems that some Win update erases the kernel file.

@friday963
Copy link

ok - i figured out the issue. the new update does not uninstall the old one (the slow insider ring one).

I right clicked the old msi - uninstalled it. now i can install the new one .

Can you expand on this? I'm not sure where you found the MSI to uninstall.

I tried the recommended advice from @onomatopellan
msiexec /a "wsl_update_x64.msi" /qb TARGETDIR="C:\temp"
and then copy the kernel file from C:\temp to C:\Windows\System32\lxss\tools

But I still cannot get it to work.
I don't have a kernel file after executing those commands, its just an MSI file and when I click the file it says "The specified account already exists" and fails.

@onomatopellan
Copy link

onomatopellan commented Apr 4, 2020

@friday963 Something is broken in your install. Follow this and try again: https://support.microsoft.com/en-us/help/17588/windows-fix-problems-that-block-programs-being-installed-or-removed

BTW the msi file you need is here https://aka.ms/wsl2kernel

@friday963
Copy link

@friday963 Something is broken in your install. Follow this and try again: https://support.microsoft.com/en-us/help/17588/windows-fix-problems-that-block-programs-being-installed-or-removed

BTW the msi file you need is here https://aka.ms/wsl2kernel

You're right @onomatopellan , I needed to uninstall with that tool. Thanks for the help!

@swaroop1
Copy link

swaroop1 commented Apr 6, 2020

@sandys Thanks that worked for me!!

We need to uninstall " Windows Subsystem for Linux Update " just as we would uninstall a regular windows application

@iam-etienne-lm
Copy link

ok - i figured out the issue. the new update does not uninstall the old one (the slow insider ring one).

I right clicked the old msi - uninstalled it. now i can install the new one .

"Right clicked the downloaded msi" would have been correct.
Thanks!!!

@jakemitchellxyz
Copy link

ok - i figured out the issue. the new update does not uninstall the old one (the slow insider ring one).
I right clicked the old msi - uninstalled it. now i can install the new one .

"Right clicked the downloaded msi" would have been correct.
Thanks!!!

This solved it for me!

@baoanhng
Copy link

baoanhng commented Apr 30, 2020

Solved issue for me. We need to uninstall the latest one, then install it with downloaded kernel from the website.

@skipper46
Copy link

Solved issue for me. The problem was the path "C:\Users<UserName>\Downloads\wsl_update_x64.msi" to msi installation file.
I copied file to "C:\Temp\wsl_update_x64.msi", double-clicked and was installed OK.

@twocs
Copy link

twocs commented May 16, 2020

I saw the error "the update only applies to machines with the Windows Subsytem for Linux".

Reading this thread I saw advice to uninstall the old installer. I couldn't find any old installer, so I right clicked the newly downloaded wsl_update_x64.msi file and selected "uninstall". It successfully uninstalled. Then I right clicked it again and selected install, and no longer saw "the update only applies to machines with the Windows Subsytem for Linux" error. It installed successfully. @_@

@drphrozen
Copy link

I solved my issue by elevating a command line and executing wsl_update_x64.msi from there.

@jtsalten
Copy link

I had the same issue. Last Windows 10 2004 up to date. Previously WSL1 installed and working. I tried uninstalling WSL several times with no luck. Finally I uninstalled Docker for Windows, WSL, Virtual Machine Platform Platform and Hyper-V... and reinstalled again Hyper-V, restart, WSL, restart, VMP, restart, install Ubuntu 20, install Docker for Windows with WSL2 enabled... Now it works... But not knowing what it fails it's a bit scary because seems like you never know when will happen again... 😰

@CaduceusInc
Copy link

ok - i figured out the issue. the new update does not uninstall the old one (the slow insider ring one).
I right clicked the old msi - uninstalled it. now i can install the new one .

"Right clicked the downloaded msi" would have been correct.
Thanks!!!

Right! I only understood what he said after reading your comment. Works now, thanks!

@meizenga
Copy link

meizenga commented Jun 1, 2020

I had the same issue. Last Windows 10 2004 up to date. Previously WSL1 installed and working. I tried uninstalling WSL several times with no luck. Finally I uninstalled Docker for Windows, WSL, Virtual Machine Platform Platform and Hyper-V... and reinstalled again Hyper-V, restart, WSL, restart, VMP, restart, install Ubuntu 20, install Docker for Windows with WSL2 enabled... Now it works... But not knowing what it fails it's a bit scary because seems like you never know when will happen again... 😰

I had the same issue and your solution fixed it, but.... I also had to run Docker Desktop installer as Adminitrator (even my account is already local admin). Thanks @CaduceusInc

@jramiresbrito
Copy link

jramiresbrito commented Jun 5, 2020

I'm running on the same issue.

Running on
Win version: 2004, Compilation: 19640.1

Here are the steps I did:

Power Shell:

  • Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
  • dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
  • dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Microsoft Store:

  • Get the Ubuntu (Plain , not the 18 or 20 dist)

After install the Ubuntu and restart pc, on CMD:

  • system32>wsl -l -v

It shows:
NAME STATE VERSION
Ubuntu Stopped 1

Then, update the WSL2 Kernel:

Back to CMD:

  • wsl --set-version Ubuntu 2

The error prompts:

  • WSL2 requires an update to you Kernel component. To get more info please go to aka ms.

Checking the version and stays on Version 1:

  • system32>wsl -l -v

NAME STATE VERSION
Ubuntu Stopped 1

Tried to uninstall the manual update to WSL2 and installing it again, but the error keeps the same.

How can I solve this?

@benhillis
Copy link
Member

@jramiresbrito - Did the MSI install correctly? I assume you do not have a kernel under \windows\system32\lxss\tools?

@jramiresbrito
Copy link

@jramiresbrito - Did the MSI install correctly? I assume you do not have a kernel under \windows\system32\lxss\tools?

Yes. It did not complain and successfully finish the installation.

@benhillis
Copy link
Member

benhillis commented Jun 5, 2020

Do you have a %windir%\system32\lxss\tools\kernel file?

@jramiresbrito
Copy link

Do you have a %windir%\system32\lxss\tools\kernel file?

No, only a kernel.rollback file. How to get the kernel?

@gabrielgrant
Copy link

I was running into this issue during a fresh install of WSL (2) while following the instructions at: https://docs.microsoft.com/en-us/windows/wsl/install-win10

It turns out the issue was that I had missed the instruction to restart after enabling WSL and as part of enabling Virtualization (step 3)

image

Certainly kinda my fault for moving too quickly and not reading thoroughly, but should really just be Step 4, or at least would be nice if the bold text in step 1 telling you to not restart now instead said "wait to restart until after step 3 (or until 4)":

image

In addition, while trying @onomatopellan 's advice above to extract the kernel manually, ran into the following error:

The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2203.

It turns out the problem was that I had downloaded the MSI into the C:\Temp directory, and was also trying to extract it into that same folder. Apparently the folder in which the MSI is located gets locked during extraction, causing this failure. Creating a subdirectory and extracting into that instead worked. (thanks for this Stack Overflow answer for pointing me in the right direction on this one)

@onomatopellan onomatopellan mentioned this issue May 2, 2021
2 tasks
@Joshfindit
Copy link

Would also like to add to the "we can all do it" pile:

image

This is at the bottom of the install page in the Troubleshooting section, and I still got to this thread before rebooting.

@xumarcus
Copy link

xumarcus commented Jun 3, 2021

The installer linked above does not work (This installation package could not be opened). Troubleshooter says it's incompatible and Orca cannot open it. (Version: 10.0.19043) WSL2 eventually works through Windows update -> Advanced Options -> Receive updates ... though.

@alexhaydock
Copy link

I was running into this issue during a fresh install of WSL (2) while following the instructions at: https://docs.microsoft.com/en-us/windows/wsl/install-win10

It turns out the issue was that I had missed the instruction to restart after enabling WSL and as part of enabling Virtualization (step 3)

I got bitten by this one just now, even though I was 100% certain I'd rebooted since enabling the features in Step 1 and 3. I'm not a frequent Windows user so what I apparently missed is that shutting down and then starting the machine back up later is not the same as a restart because it's more of a pseudo-hibernation these days. After a proper restart everything works fine.

Just putting this here in case anyone else is battling the same issue under the same circumstances.

@AliAlhajji
Copy link

I was having the same problem. Uninstalling was not an option for me since I had not installed it previously.

Restarting the machine worked for me :)

@KorigamiK
Copy link

For WSL2 you will need 2 Windows components so make sure they are already enabled:
Microsoft-Windows-Subsystem-Linux
VirtualMachinePlatform

Also it seems some people have problems with the installer extracting the kernel.
You can always extract it manually with:
msiexec /a "wsl_update_x64.msi" /qb TARGETDIR="C:\temp"
and then copy the kernel file from C:\temp to C:\Windows\System32\lxss\tools

Final version shouldn't have this problem since the install comes from Windows Update.

God damn it! I had didn't realize that I had to install the update manually for wsl2. I'm glad that it's working now.

@ilayatshah
Copy link

I tried all of the above nothing worked for me. The only thing which worked for me was to manually type "feature" in the window search bar and click on the "Turn Windows features on or off". I unchecked both the "virtual machine platform" and "windows subsystem for Linux". Clicked ok and then restarted my computer. Again I followed the same procedure but this time I checked both the feature and again restarted my computer. Now I can install the downloaded MSI.

@Yuchen-Git
Copy link

hey, I just got the problem solved by going directly to the linked address,( the one in the error message) in case there still have people struggle with it, here is what I did:

  1. make sure you have both windows for subsystem feature and virtual machine feature enable, command line are the following

dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart
one for Enable the Windows Subsystem for Linux
another for Enable Virtual Machine feature

  1. then use the link the download the update (latest) (link: https://wslstorestorage.blob.core.windows.net/wslblob/wsl_update_x64.msi)
  2. reboot

referance link
https://docs.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package

@Dev-Soumyaranjan
Copy link

@friday963 Something is broken in your install. Follow this and try again: https://support.microsoft.com/en-us/help/17588/windows-fix-problems-that-block-programs-being-installed-or-removed

BTW the msi file you need is here https://aka.ms/wsl2kernel

Thanks It worked for me

@shlovee
Copy link

shlovee commented Feb 12, 2022

https://www.how2shout.com/how-to/solve-wslregisterdistribution-failed-with-error-0x800701bc.html

This link helped me to resolve the below error I was getting while trying to run docker on windows 11. I had to update the Kernel version.

Error: 0x800701bc WSL 2 requires an update to its kernel component. For information please visit https://aka.ms/wsl2kernel

@nckdistributable
Copy link

nckdistributable commented May 20, 2022

i just removed 'linux Subsystem For Windows' from Settings -> Apps
Than i installed wsl_update.msi again and it's worked well for me

@slonopotamus
Copy link

I just uninstalled Windows, installed Linux and everything worked fine for me since that day.

@junxian428
Copy link

wsl --update

@ilham76c
Copy link

ilham76c commented Feb 3, 2023

I'm running on the same issue.

Running on Win version: 2004, Compilation: 19640.1

Here are the steps I did:

Power Shell:

  • Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
  • dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
  • dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Microsoft Store:

  • Get the Ubuntu (Plain , not the 18 or 20 dist)

After install the Ubuntu and restart pc, on CMD:

  • system32>wsl -l -v

It shows: NAME STATE VERSION Ubuntu Stopped 1

Then, update the WSL2 Kernel:

Back to CMD:

  • wsl --set-version Ubuntu 2

The error prompts:

  • WSL2 requires an update to you Kernel component. To get more info please go to aka ms.

Checking the version and stays on Version 1:

  • system32>wsl -l -v

NAME STATE VERSION Ubuntu Stopped 1

Tried to uninstall the manual update to WSL2 and installing it again, but the error keeps the same.

How can I solve this?

I'm running on the same issue.

Running on Win version: 2004, Compilation: 19640.1

Here are the steps I did:

Power Shell:

  • Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
  • dism.exe /online /enable-feature /featurename:Microsoft-Windows-Subsystem-Linux /all /norestart
  • dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Microsoft Store:

  • Get the Ubuntu (Plain , not the 18 or 20 dist)

After install the Ubuntu and restart pc, on CMD:

  • system32>wsl -l -v

It shows: NAME STATE VERSION Ubuntu Stopped 1

Then, update the WSL2 Kernel:

Back to CMD:

  • wsl --set-version Ubuntu 2

The error prompts:

  • WSL2 requires an update to you Kernel component. To get more info please go to aka ms.

Checking the version and stays on Version 1:

  • system32>wsl -l -v

NAME STATE VERSION Ubuntu Stopped 1

Tried to uninstall the manual update to WSL2 and installing it again, but the error keeps the same.

How can I solve this?

thanks, I just downloaded the wsl2 kernel then installed it, and all problems solved.

@schuberng
Copy link

schuberng commented Feb 19, 2023

@friday963 Something is broken in your install. Follow this and try again: https://support.microsoft.com/en-us/help/17588/windows-fix-problems-that-block-programs-being-installed-or-removed

BTW the msi file you need is here https://aka.ms/wsl2kernel

I should say thank you for posting a tool that help fixing issues for program improperly uninstalled. Long story for short, back in days when I first touched cli and tried to play with with cli on file removal. After applied rm to where adobe pdf reader installed (could not really remember why), found out neither the old pdf reader could not be removed nor the newer version could be installed, because of my false operation.

So, this problem sits for years because of my laziness, until I finally came across your answer for fixing wsl issue and tried this tool that brings pdf reader back to life again. I know this sounds really stupid to people who read this post, but at least I got lesson learned.

@neilwang0913
Copy link

I think you might also need to run in admin for the 1st time.

@sai-kumar2413
Copy link

I'm starting Ubuntu for Windows and I immediately receive the following message:
"WSL 2 requires an update to its kernel component. For information please visit https://aka.ms/wsl2kernel."
sort out above problem by this command in PowerShell
wsl --update
after this update everything is clear
it may help for this problem

@ghost
Copy link

ghost commented Aug 21, 2023

it's very simple
after install and check all requirement
type wsl --update then wsl --install
done

@drakem58
Copy link

drakem58 commented Aug 28, 2023

I am running Windows 11 not 10 and ran into the same display after installing Ubuntu, "WSL 2 requires an update to its kernel component. For information please visit https://aka.ms/wsl2kernel." Went to the website, downloaded the fix, ran it, then reran ubuntu and it works now.

@kangarooo
Copy link

Removed Ubuntu, WSL update, WSL in Add windows features deselected WSL
Restart
Installed in Features WSL
Restart
Did https://learn.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package
Installed update
Restart
Opened WSL
Didnt open
In store opened Ubuntu 22.04.3
Installed
WORKS

It should fix it all automatically instead of manually guessing and removing all

@Lakshan-Madushanka
Copy link

Open the power shell and run the command wsl.exe --install worked for me.

@goyaoyuanchun
Copy link

@friday963 Something is broken in your install. Follow this and try again: https://support.microsoft.com/en-us/help/17588/windows-fix-problems-that-block-programs-being-installed-or-removed
BTW the msi file you need is here https://aka.ms/wsl2kernel

You're right @onomatopellan , I needed to uninstall with that tool. Thanks for the help!

this works for me : https://learn.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package

@itsmejyv
Copy link

itsmejyv commented Jul 27, 2024

This error happens to me also in Windows 11, this Manual Installation will fix it. Just make sure you enabled WSL on windows feature configuration. There's also included command there to enable virtual machine feature if ever you forgot to enable it.

@Harsh-1Byte
Copy link

Harsh-1Byte commented Oct 12, 2024

Hey Folks,
I found my solution to my problem at this wonderful article below do check it out:
https://learn.microsoft.com/en-us/windows/wsl/install-manual#step-4---download-the-linux-kernel-update-package

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation request for documentation improvement workaround-available
Projects
None yet
Development

No branches or pull requests