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

Unable to install WSL on fresh windows 10 #7584

Closed
rminehan opened this issue Oct 22, 2021 · 2 comments
Closed

Unable to install WSL on fresh windows 10 #7584

rminehan opened this issue Oct 22, 2021 · 2 comments

Comments

@rminehan
Copy link

Hello, I am new to WSL and am trying to follow the installation instructions here.

When I try to install WSL from an administrator PowerShell I get:

PS C:\Windows\system32> wsl --install
wsl : The term 'wsl' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
+ wsl --install
+ ~~~
    + CategoryInfo          : ObjectNotFound: (wsl:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

The prerequisites say:

You must be running Windows 10 version 2004 and higher (Build 19041 and higher) or Windows 11

I have run winver and got this output: 19043.928 so it appears I satisfy the prerequisites.


I have tried following the trouble shooting info here which references my "not recognized" error and says:

Ensure that the Windows Subsystem for Linux Optional Component is installed.

and points to older instructions for installing wsl via dism.exe

I followed those instructions being able to use dism.exe:

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

Deployment Image Servicing and Management tool
Version: 10.0.19041.844

Image Version: 10.0.19043.928
...
The operation completed successfully.

> dism.exe /online /enable-feature /featurename:VirtualMachinePlatform /all /norestart

Deployment Image Servicing and Management tool
Version: 10.0.19041.844

Image Version: 10.0.19043.928
...
The operation completed successfully.

then downloaded the wsl_update_x64.msi but when trying to run it got an error popup saying: "The Update only applies to machines with the Windows Subsystem for Linux".

I searched my system for wsl executables and found some related files like under C:\Windows\WinSxS such as:

C:/Windows/WinSxS/amd64_microsoft-windows-lxss-wsl_31bf3856ad364e35_10.0.19041.488_none_60be8a5c2dce0ea7/wsl.exe
C:/Windows/WinSxS/amd64_microsoft-windows-lxss-wslconfig_31bf3856ad364e35_10.0.19041.488_none_7eeccf5f03956a85/wslconfig.exe

So perhaps it's installed but the system path is broken?

When I try directly running the wsl.exe mentioned above it just gives a "Class not registered" error.


For background, this is a fresh installation of Windows 10 on a work computer just issued to me by my employer.

It's a Lenovo Thinkpad T490.

The company has an IT team with their own installation/security processes so perhaps that has broken wsl in some way.

@0xbadfca11
Copy link

Do Windows Update.
19043.928 is too old.
Support for wsl --install started in 19043.1151.
https://devblogs.microsoft.com/commandline/install-wsl-with-a-single-command-now-available-in-windows-10-version-2004-and-higher/

@rminehan
Copy link
Author

Thanks @0xbadfca11, running updates worked.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants