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

Cannot upgrade to version 2 even when Virtual Machine Platform is enabled #404

Closed
iggyvolz opened this issue Jun 13, 2019 — with docs.microsoft.com · 89 comments
Closed
Assignees

Comments

Copy link

I have enabled the VirtualMachinePlatform as instructed, but I am still unable to upgrade my distribution to version 2:

PS C:\WINDOWS\system32> Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform


Path          :
Online        : True
RestartNeeded : False



PS C:\WINDOWS\system32> wsl --set-version Ubuntu 2
Conversion in progress, this may take a few minutes...
For information on key differences with WSL 2 please visit https://aka.ms/wsl2
Please enable the Virtual Machine Platform Windows feature.
PS C:\WINDOWS\system32> wsl --list --verbose
  NAME      STATE           VERSION
* Ubuntu    Stopped         1

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

  • ID: b19a43be-b16a-d903-b69d-75dffce6c329
  • Version Independent ID: f9d4a118-1251-8d6b-43f5-2e64808dc527
  • Content: Install WSL 2
  • Content Source: WSL/wsl2-install.md
  • Product: windows-subsystem-for-linux
  • GitHub Login: @mscraigloewen
  • Microsoft Alias: mscraigloewen
@LaurentLienhard
Copy link

Reboot After enable-Windows feature ?

Copy link

janjiss commented Jun 13, 2019

I'm facing the same issue, even after reboot

Copy link

Same issue here. It could be that Virtual Machine Platform cannot be installed on Windows 10 Home Insider Preview, making this a Pro only feature. I hope that is not the case.

Copy link

Same issue, "Virtual Machine Platform" is checked on Features Panel, but still print "Please enable the Virtual Machine Platform Windows feature." .

Copy link

wrvsrx commented Jun 13, 2019

Same issue, and I installed Windows 10 Pro Insider Preview.

@wrvsrx
Copy link

wrvsrx commented Jun 13, 2019

I solved it on my PC.
Virtual Machine Platform needs "Virtualization"(or other similar options) option set to "Enabled" in UEFI. But if you open it with Powershell, system won't check if "Virtualization" option is set to enabled.
So setting the option in UEFI may solve this problem(at least it works on my PC).

@iggyvolz
Copy link
Author

Enabling virtualization appears to be working on my system; I can't believe I didn't think of doing that. The error message and/or docs should be updated to reflect that you need virtualization on as well.

@benhillis
Copy link
Contributor

Good suggestion, I will update the error message and documentation.

@benhillis benhillis self-assigned this Jun 13, 2019
@dmserrano
Copy link

I am attempting to install WSL 2 on Parallels Desktop 14 Home Edition, but it seems the enabling virtualization feature (Parallels calls it Nested Virtualization) has been moved to the Pro edition only.

Is there another way to enable virtualization or am I out of luck while using Home Edition? I apologize if there is a simple fix for this, I am new to Windows.

Copy link

scyto commented Jun 14, 2019

I hit same issue, hadn't realized a BIOS upgrade had turned off VT - thanks.
@microsoft if the conversion command exits immediately it show an error message that VT is not enabled....

Copy link

scyto commented Jun 14, 2019

i mean it should show an error

Copy link

I had the same issue due to virtualization being disabled in BIOS.

Before the fix, Bash shell command uname says it's running Linux 4.4. I guess that's what the MS system call emulator call itself.

In Powershell, the conversion command...

wsl --set-version Ubuntu 2

...should print "Conversion complete."
It did take a few minutes.

PS C:\WINDOWS\system32> wsl -l -v
NAME STATE VERSION

  • Ubuntu Stopped 2

After the fix, the real Linux kernel is running in a VM, so the kernel's uname version is 4.19 :

bob@craterlake:~$ uname -a
Linux craterlake 4.19.43-microsoft-standard #1 SMP Mon May 20 19:35:22 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

(note: craterlake is just the name of my PC)

Apparently this kernel was compiled over lunch on May 20 :-)

Copy link

"Please enable the Virtual Machine Platform Windows feature." same problem for me too. Did anyone get any easy fix?

Copy link

I fix it by launching both commands in an admin terminal. Use another session cause error message appear.

Copy link

Even with virtualization enabled in the BIOS and those two features enabled via Powershell, I still get this error:

Installing, this may take a few minutes...
WslRegisterDistribution failed with error: 0x80370109
Error: 0x80370109 The operation timed out because a response was not received from the virtual machine or container.

Copy link

the same issue under Surface Book 2 .
i can't find the VT option and then to enable it in UEFI panel of Surface Book 2 .
so , anybody else have solutions ?
thx

@MdMaksudulHossain
Copy link

MdMaksudulHossain commented Jun 19, 2019 via email

Copy link

tristanbarcelon commented Jun 19, 2019

Is WSL 2 available on the recently released Windows Server 18917 SAC (core edition) ISO? I've already enabled VirtualMachinePlatform feature and rebooted. CPU has virtualization extensions enabled. Yet, wsl is not a valid command. I did install Microsoft-Windows-Subsystem-Linux but this appears to be v1.

Copy link

Unable to execute WSL commands as the flags --set-version and --list --verbose are unknown
i tried to upgrade to WSL2 right after finishing the system upgrade to Version 10.0.18362 Build 18362

@tristanbarcelon
Copy link

tristanbarcelon commented Jun 20, 2019

@blkwtch 18362 is still less than 18917 and wsl v2 requires 18917 or newer. In addition, documentation fails to mention that to get WSL, you also need to enable this feature: Microsoft-Windows-Subsystem-Linux in addition to VirtualMachinePlatform just for WSL to be a valid command.

@craigloewen-msft
Copy link
Collaborator

@tristanbarcelon the WSL 2 install docs have been updated to include build number required and that you need WSL installed with a link of how to do so.

This thread is for the specific issue of seeing the error 'Please enable the virtual machine platform' when it is already enabled, and we're working on resolving that error. If you have other questions, or issues, I'd ask that you please open a new issue so we can address them there. Thanks for your help!

@scyto
Copy link

scyto commented Jun 20, 2019

@tristanbarcelon
The here link has the content for that, though i agree having the command in the main install doc would make things easier @mscraigloewen. I suspect @tristanbarcelon didn't read that / follow the here - maybe adding the command to the doc would make more sense than linking out.

Please note that you'll need to be running Windows 10 build 18917 or higher to use WSL 2, and that you will need to have WSL already installed (you can find instructions to do so here).

@tristanbarcelon
Copy link

tristanbarcelon commented Jun 20, 2019

@mscraigloewen , sorry didn't mean to cross post. I did follow WSL 2 install docs posted and nowhere does it state that WSL (v1) must already be installed. Once WSL v1 was installed, everything does work. When VirtualMachinePlatform is being enabled via DISM, is DISM checking to see whether virtualization features are enabled before proceeding? It didn't seem to. In my situation, I installed Windows 10 18917 on a VM but I had forgotten to enable virtualization features first before attempting to install WSL 1/2. It required me to delete, recreate the vm, run Set-VMProcessor -VMName 'vmname' -ExposeVirtualizationExtensions $true -Force, and re-install Windows 10 18917 or newer before re-attempting WSL 2 installation.

@craigloewen-msft
Copy link
Collaborator

@scyto I've added the command to enable WSL to the troubleshooting section of the install page to make it clearer for users running into a similar issue.

@tristanbarcelon no I don't believe DISM does check for that.

I believe the sidebar conversation's are now resolved, so please for any further questions or comments that aren't related to the original issue I'd request that you open a new issue and we can continue the discussion there rather than cluttering notifications of users watching this specific issue.

Copy link

Left some tips for installing Windows in VM.

I installed Windows 10 in VMware Workstation, and the build version is 18922.
At the first time, I face the same issue. However, just like @wrvsrx said, I managed to turn on the virtualization on the CPU, so I used the following procedure performing on VMware Workstation:

  1. Turn off the guest Windows.
  2. Click on the upper tab and select the "VM" .
  3. Click on the "Setting".
  4. Stay in "Hardware" tab.
  5. Click the "Processors" Device.
  6. Check the "Virtualization Intel VT-x/EPT or AMD-V/RVI".
  7. Boot the guest and upgrade the WSL again.

After that, I successfully upgrade my WSL to version 2. Thanks for all you comments.

@Radio-Broadcast
Copy link

Radio-Broadcast commented Jun 26, 2019

I have checked that virtualization is enabled I'm still getting errors:
0xc03a001a - operation could not be completed due to a virtual disk system limitation.
or
Error: 0x80370109 The operation timed out because a response was not received from the virtual machine or container.

depending on how I try and get Ubuntu to update to wsl 2

Edit: I got it working:
I manually changed the folder properties of the directory where Ubuntu is installed and disabled encryption and compression in the advanced settings tab of the folder attributes.

@MdMaksudulHossain
Copy link

MdMaksudulHossain commented Jun 26, 2019 via email

@SteveALee
Copy link

As described in #436 I was getting 0x80370102 and as suggested by @mscraigloewen I enabled virtualization in the horrid HP / AM BIOS.

But then ended up in a weird state where the store throught Ubuntu was installed and let me launch it but wsl said nothing was available. In case this was due to Ubuntu being installed as old WSL I uninstalled and re installed but install now fails with 0x80073D05

I tried re enabling the Platform and WSL but they were happy and said no reset needed.

So now I'm stuck :)

@freegnu
Copy link

freegnu commented Apr 17, 2020

Uninstalling Windows Subsystem for Linux Update and then reinstalling it fixed the problem without requiring a reboot. I verified that WSL 1 was working by installing a second WSL Linux Ubuntu 18.04 from the MS Store that worked fine while the WSL 2 upgraded Linux for Ubuntu from the MS Store complained about upgrading the kernel. I tried all the other stuff in this thread but WSL 2 was previously working fine. Also these 2 commands in a Admin Console are a lifesaver and fix the MS Store not working and other weird broken Windows stuff. I ran them before uninstalling and then reinstall WSL and Virtual Machine Platform.
sfc /scannow
dism /online /cleanup-image /restorehealth

@gottenheim
Copy link

gottenheim commented May 1, 2020

I've turned on slow ring of Insider Preview program,
image

checked that virtualization is enabled
image

Windows subsystem for Linux and Virtual Machine Platform components are also installed
image

And even more, yesterday I played in vagrant with VirtualBox virtual machine and all went fine. WSL1 also worked for me, but with WSL2 I have this
image

WSL1, as mentioned before, is also broken, so instead of having new feature I've lost existing. Can you help me?

P.S. Info from CPU-Z
image

@MdMaksudulHossain
Copy link

MdMaksudulHossain commented May 1, 2020 via email

@freegnu
Copy link

freegnu commented May 12, 2020

I've turned on slow ring of Insider Preview program,
image

checked that virtualization is enabled
image

Windows subsystem for Linux and Virtual Machine Platform components are also installed
image

And even more, yesterday I played in vagrant with VirtualBox virtual machine and all went fine. WSL1 also worked for me, but with WSL2 I have this
image

WSL1, as mentioned before, is also broken, so instead of having new feature I've lost existing. Can you help me?

P.S. Info from CPU-Z
image

WSL 2 isn't available in non-Preview until update 2004.

@rstefek
Copy link

rstefek commented May 15, 2020

I have checked that virtualization is enabled I'm still getting errors:
0xc03a001a - operation could not be completed due to a virtual disk system limitation.
or
Error: 0x80370109 The operation timed out because a response was not received from the virtual machine or container.

depending on how I try and get Ubuntu to update to wsl 2

Edit: I got it working:
I manually changed the folder properties of the directory where Ubuntu is installed and disabled encryption and compression in the advanced settings tab of the folder attributes.

worked for me, uncompressed AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows...

@birdmanmandbir
Copy link

@freegnu same problem on 2004..

@flaprano
Copy link

flaprano commented Jun 5, 2020

@freegnu same problem on 2004..

The same happening here.
Almost giving up on use WSL. The support seems pretty bad.

@birdmanmandbir
Copy link

@flaprano You can try solutions in this issue: wsl-#5328

@NicTanghe
Copy link

hello so wsl 1 doesn`t even work.
im also on windows 2004

@MaximoTrinidad
Copy link

Yes! There was a link to update the WSL 2 Kernel:
https://aka.ms/wsl2kernel

In my case, I had to run it twice, and everything is working.

WSL2-Update_2020-05-28_9-08-10

@Vishnu05
Copy link

I am attempting to install WSL 2 on Parallels Desktop 14 Home Edition, but it seems the enabling virtualization feature (Parallels calls it Nested Virtualization) has been moved to the Pro edition only.

Is there another way to enable virtualization or am I out of luck while using Home Edition? I apologize if there is a simple fix for this, I am new to Windows.

Yeah, same here, needed some help to resolve this

@Robinzon100
Copy link

the version 2 upgrade worked after I enabled intel virtualization technology in BIOS>advance,
if you can't find what I'm talking about or where's the option ill be glad to take pictures of the bios

good luck everybody and have a beautiful day

@freegnu
Copy link

freegnu commented Jul 27, 2020 via email

@MdMaksudulHossain
Copy link

MdMaksudulHossain commented Aug 11, 2020 via email

@scyto
Copy link

scyto commented Aug 11, 2020

@MdMaksudulHossain assuming you don't have fundamental connectivity issue try this microsoft/WSL#5256 (comment)

@MdMaksudulHossain
Copy link

MdMaksudulHossain commented Sep 2, 2020 via email

@freegnu
Copy link

freegnu commented Sep 6, 2020 via email

@RenanZX
Copy link

RenanZX commented Oct 16, 2020

I have AMD processor, same problem

@shmuli9
Copy link

shmuli9 commented Nov 1, 2020

Yes! There was a link to update the WSL 2 Kernel:
https://aka.ms/wsl2kernel

In my case, I had to run it twice, and everything is working.

WSL2-Update_2020-05-28_9-08-10

Reinstalling the WSL2 kernel fixed the issue for me

Thanks

@codepolariz
Copy link

I have enabled the VirtualMachinePlatform as instructed, but I am still unable to upgrade my distribution to version 2:

PS C:\WINDOWS\system32> Enable-WindowsOptionalFeature -Online -FeatureName VirtualMachinePlatform


Path          :
Online        : True
RestartNeeded : False



PS C:\WINDOWS\system32> wsl --set-version Ubuntu 2
Conversion in progress, this may take a few minutes...
For information on key differences with WSL 2 please visit https://aka.ms/wsl2
Please enable the Virtual Machine Platform Windows feature.
PS C:\WINDOWS\system32> wsl --list --verbose
  NAME      STATE           VERSION
* Ubuntu    Stopped         1

Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

  • ID: b19a43be-b16a-d903-b69d-75dffce6c329
  • Version Independent ID: f9d4a118-1251-8d6b-43f5-2e64808dc527
  • Content: Install WSL 2
  • Content Source: WSL/wsl2-install.md
  • Product: windows-subsystem-for-linux
  • GitHub Login: @mscraigloewen
  • Microsoft Alias: mscraigloewen

I've turned on slow ring of Insider Preview program,
image
checked that virtualization is enabled
image
Windows subsystem for Linux and Virtual Machine Platform components are also installed
image
And even more, yesterday I played in vagrant with VirtualBox virtual machine and all went fine. WSL1 also worked for me, but with WSL2 I have this
image
WSL1, as mentioned before, is also broken, so instead of having new feature I've lost existing. Can you help me?
P.S. Info from CPU-Z
image

WSL 2 isn't available in non-Preview until update 2004.

Are you using a virtual machine? if yes you need to enable nested virtualization. In my case, i am using parallel and i faced the same issue. After enabling nested virtualization, WSL2 WORKED.
Follow the steps on this link or if you are using VMware or Virtualbox nested virtualization is bundled with the VM by default
https://patrickwu.space/2020/02/14/wsl-on-mac/

@f3ndot
Copy link

f3ndot commented Dec 6, 2020

After running bcdedit /set hypervisorlaunchtype auto start as described above my windows fails to boot. Had to run bcdedit /set hypervisorlaunchtype off to undo.

This also caused my machine not to boot. Trying to undo by running the other command didn't work in safe mode's command prompt. I'm stuck in a failed Win10 boot loop :(

Buyer beware

@freegnu
Copy link

freegnu commented Dec 7, 2020 via email

@ghost
Copy link

ghost commented Feb 22, 2021

I managed to update to wsl2 like this:

  1. I ran the command "wsl" in the power shell adm

  2. I opened another instance of the power shell and ran the command "wsl.exe --set-default-version Ubuntu 20.04 2"

@yiqiangjizhang
Copy link

I have the same issue, read all the Issueas above but none of them are working for me!
Here is what I get:
image

@ghost
Copy link

ghost commented Jun 14, 2021

try this:
bcdedit /set hypervisorlaunchtype auto start then shutdown /r in powershell as administrator

@freegnu
Copy link

freegnu commented Jun 14, 2021 via email

@ReinWD
Copy link

ReinWD commented Jul 9, 2021

Try running Dism.exe /online /Cleanup-Image /StartComponentCleanup & dism /online /cleanup-image /restorehealth & sfc /scannow

try this:
bcdedit /set hypervisorlaunchtype auto start then shutdown /r in powershell as administrator

combination of these commands helped.
Just upgraded to WSL2.

@mlclmtan
Copy link

For those who have WSL1 installed, make sure to run wsl --set-default-version 2 in powershell and Windows subsystem for Linux and Virtual Machine Platform components are also installed, then ready to upgrade to WSL2.
Simply install any other version from store, and open your original Ubuntu, remove the newly installed version, viola wsl -l -v it shows version 2!

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