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

WSL2 hangs on update (no output) #9528

Open
1 of 2 tasks
myz-dev opened this issue Jan 24, 2023 · 14 comments
Open
1 of 2 tasks

WSL2 hangs on update (no output) #9528

myz-dev opened this issue Jan 24, 2023 · 14 comments

Comments

@myz-dev
Copy link

myz-dev commented Jan 24, 2023

Version

Microsoft Windows [Version 10.0.19045.2486]

WSL Version

  • WSL 2
  • WSL 1

Kernel Version

5.10.102.1

Distro Version

Ubuntu 20.04

Other Software

No response

Repro Steps

  • Open Powershell as an admin.
  • run wsl.exe --update

Expected Behavior

I expect the program to terminate at some point and give me a message that tells me if the update was successful.

Actual Behavior

All I see is this output:

PS C:\WINDOWS\system32> wsl.exe --update
Installation: Windows-Subsystem für Linux

Diagnostic Logs

I created an issue with the Feedback Hub, but I am not sure it worked correctly.

@OneBlue
Copy link
Collaborator

OneBlue commented Jan 24, 2023

/dumps

@ghost
Copy link

ghost commented Jan 24, 2023

Hello! Could you please provide logs and process dumps to help us better diagnose your issue?

To collect WSL logs and dumps, download and execute collect-wsl-logs.ps1 in an administrative powershell prompt:

Invoke-WebRequest -UseBasicParsing "https://raw.githubusercontent.com/microsoft/WSL/master/diagnostics/collect-wsl-logs.ps1" -OutFile collect-wsl-logs.ps1
Set-ExecutionPolicy Bypass -Scope Process -Force
.\collect-wsl-logs.ps1 -Dump

The scipt will output the path of the log file once done.

Once completed please upload the output files to this Github issue.

Click here for more info on logging

Thank you!

@myz-dev
Copy link
Author

myz-dev commented Jan 25, 2023

Hi,
sorry, should have done that in the first place.
WslLogs-2023-01-25_08-06-20.zip

@ghost ghost removed the needs-author-feedback label Jan 25, 2023
@OneBlue
Copy link
Collaborator

OneBlue commented Jan 25, 2023

Thank you @myz-dev. Unfortunately I don't see any dumps on that zip file. Was wsl.exe running when you captured the dumps ?

Can you try capturing a dump of the hung process via task manager instead ?

@myz-dev
Copy link
Author

myz-dev commented Jan 26, 2023

Hi,
with the last dumps, I had open one shell and performed the task the bot had provided. In another shell I ran wsl.exe --update.
Now I have again started one Powershell shell with admin rights and have run wsl.exe --update. I let it run for a few minutes, then, before killing the process, I have created the dumps of the Powershell process, the wsl process and the console host process.
Because the zipped files were too big to attach to GitHub, I have for now only attached the wsl.DMP file.
I hope this helps.
wsl.zip

@ghost ghost removed the needs-author-feedback label Jan 26, 2023
@douwefokkema
Copy link

I am having a similar issue, occurring when closing code taht was started in a WSL terminal. I get a small window saying updatinf Code, I kill the terminal process ctrl Z. But "Updating window" remains.
vscode-inno-updater-1678354414.log

@douwefokkema
Copy link

A restart will solve this.

@AgainPsychoX
Copy link

I have similar issue. Restart didn't help. Just infinite Installing: Windows Subsystem for Linux...

WslLogs-2023-08-15_17-06-11.zip

@myz-dev
Copy link
Author

myz-dev commented Aug 16, 2023

Hi, after a few weeks it worked for me again. Maybe a Windows update fixed it? The latest patch I have installed seems to be July 11, 2023—KB5028166.

@philipsd6
Copy link

philipsd6 commented Sep 12, 2023

I'm having the same problem, on Window 10.0.19044 in Administrator Command Prompt.

wsl --update => hangs indefinitely at 0%

wsl --update --web-download downloaded fine, but then it hangs indefinitely on "Installing: Windows Subsystem for Linux".

@tomaszstec
Copy link

Hi, I'm having the same problem.

Edition	Windows 10 Pro
Version	22H2
Installed on	‎29.‎11.‎2023
OS build	19045.3803
Experience	Windows Feature Experience Pack 1000.19053.1000.0

WSL:

WSL version: 2.0.9.0
Kernel version: 5.15.133.1-1
WSLg version: 1.0.59
MSRDC version: 1.2.4677
Direct3D version: 1.611.1-81528511
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.19045.3803

Command invocation:

wsl --update

Effect (polish translation):

Sprawdzanie dostępności aktualizacji.
Aktualizowanie Podsystem Windows dla systemu Linux do wersji: 2.0.14.
The requested operation requires elevation.

The elevation window is shown to accept administrator rights and I granted it.
New console windows with title containing wsl.exe path appears and then the process hangs endlessly.

Mentioned flag --web-download does not change anything.

@stefan-oskamp
Copy link

I also had this issue. When trying to update from 2.0.9 to 2.0.14, it would download the update and say it is installing, but there is no progress and no output. Tried multiple times. The result was always the same, no matter whether I ran the command in an elevated or non-elevated cmd or whether I shutdown WLS first or not.

I then set my Window Region and Regional Format from German to English. Windows Display Language is always set to English. The WSL update then completed.

The reason I tried this is that it seemed to me that the WSL display language changed from the Windows Display Language to the Windows Region setting (i.e. from English to German in my case) with one of the recent WSL updates.

Of course, it might as well be normal that you need to try the update five times and that it is completely unrelated to the Windows Region settings.

@rhtenhove
Copy link

What may have helped in my case, but may also have been a placebo for impatience, was to wsl.exe --shutdown in a separate Administrator shell.

Also from 2.0.9 to 2.0.14, and the first time I've used the --update argument.

I tried this because during the update an already open WSL terminal stayed available and functional, which seemed odd.

@clayboc
Copy link

clayboc commented Nov 13, 2024

If you use Alt+Tab to move through the open "apps", you will see there is a prompt box asking to make changes to the system. This was causing the "hang" for me when updating WSL.

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

9 participants