-
Notifications
You must be signed in to change notification settings - Fork 826
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
localhost:PORT from windows host no longer gets handled by process running in WSL2 #8679
Comments
Thanks for reporting. @pmartincic could you please take a look? |
Maybe this has something do with that: Suddenly, I got (for Docker Desktop) It worked perfectly for months. The only thing changed was a Windows Update with update of WSL to 0.65.1
|
Same here, minikube cannot ssh to it container anymore.
|
/logs |
Hello! Could you please provide more logs to help us better diagnose your issue? To collect WSL logs, download and execute collect-wsl-logs.ps1 in an administrative powershell prompt:
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! |
Are you guys by chance using a private kernel? Could you share the output of |
I use the default Ubuntu 20.04 image I will provide logs later, when I am home |
uninstalling 10.0.22622.450 on
I'm trying to find an option to downgrade wsl back to [0.64.0]
WslLogs-2022-08-03_16-15-51.zip on WSL Ubuntu:
on Windows Host:
|
I can now reproduce in Windows 11 GA with 0.65.1 based on @mwidmann's updated description. $ $env:WSL_UTF8=1
$ wsl --status | clip.exe Default Distribution: Ubuntu-22.04
Default Version: 2
WSL version: 0.65.1.0
Kernel version: 5.15.57.1
WSLg version: 1.0.41
MSRDC version: 1.2.3213
Direct3D version: 1.601.0
DXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp
Windows version: 10.0.22000.795 In Ubuntu 22.04: python3 -m http.server And can browse in Edge to
|
I'm using Insider back to 22622.450, the connection from windows to localhost:80 hosted in kubernetes WSL2 "Docker Desktop" worked. from WSL2 Ubuntu from WSL2 Ubuntu from windows Powershell i'm trying to export my wsl Ubuntu distro, to uninstall wsl from windows, and try reinstall wsl without the Preview, in last scenario start work again in windows powershell until solution or work around was found 😥 |
I can confirm the same behavior. |
Ahhhh, this helps. I read the original bug description as saying that localhost:port was inaccessible from the windows host.
|
Any luck on this? Everything (docker desktop, kind) latest version, but since yesterday when this got updated it doesn't work, even with clean install. Just as a work around: just using docker destop without WSL engine, everything still works. |
@DmytryEmery - I'd suggest downloading a previous release from the github releases page. |
@benhillis thanks! |
While debugging this locally we have pushed https://github.com/microsoft/WSL/releases/tag/0.65.2 which will revert to the previous behavior. |
I have to revert this. While the first couple of requests worked fine, it is back to Tried on ports 8080 and 4400. localhost and 127.0.0.1 don't work. The IP Address eth0 has in ubuntu instance can be used to connect. I ran the BTW, the machine is already updated to the latest DEV Insider build This is what
and this is the output of
|
Can you explain how you did it ? Downloaded the packages and launched the installer but it wouldn't finish. Having the same problem after this night update , and of course the day it is most needed (merge and review for client project release...)
I have the exact same problem, it works for a few http/https requests and then back to ERR_CONNECTION_REFUSED afterwards |
The update was just offered to me through the Windows Store. That's why it was faster than my logs gathering. |
This is getting stranger and stranger. It appears that the problems start when a second port is opened with the same process. Running one node process on port 8080 works, starting a second one on port 4400 produces the Here's a new set of logs... |
Still the same issue with minikube using 0.65.2.
Forcing downgrade to 0.64.0 fixed the issue.
Sidenote, to downgrade:
1. download the package from github https://github.com/microsoft/WSL/releases/download/0.64.0/Microsoft.WSL_0.64.0.0_x64_ARM64.msixbundle
2. Open a powershell prompt
3. On the prompt, navigate to folder in which you downloaded the file
4. then type ( or copy paste ) : Add-AppxPackage -Path .\Microsoft.WSL_0.64.0.0_x64_ARM64.msixbundle
-ForceUpdateFromAnyVersion -ForceApplicationShutdown
|
Have the same issue with opening localhost and 127.0.0.1 on diffrent ports. It can work with localhost:3000, but doesn't work on localhost:3020 or vise versa. Both 0.65.1 and 0.65.2 have this issue. Downgrade to 0.64.0 is fixed problem Added logs (while launched server and tryed to get it from Windows) |
One more thing |
I can confirm this work, I was just missing the ForceUpdate part. |
0.65.2 not work for me |
0.65.2 doesn't work, thx @olivierchatry, reverting is an solution, but an --upgrade "version" or some type of downgrade procedure in docs will be easy. |
Another thing I noticed is that my computer freezes now regularly when I do EDIT: |
Btw, i had the same complete freezes after "WSL --shutdown" on 0.65... |
Taking another look, the revert should have fixed the issue... |
@hf35 - I'll try to repro locally, but it looks like 0.65.2 may not have the full revert. Taking a look. |
Ok I sorted this out, I tagged the wrong commit. Pushing a new build (0.65.3) here shortly. |
@hf35 - coudl you please file a new bug for that issue? I suspect this is vgpu related. |
@benhillis Should we be seeing 0.65.3 as an update for insiders at this point, or is that for manual install? |
|
@benhillis everyhing is ok on 0.65.3 with localhost
About freezes? I am not sure, how i can save log, because after shutdown command - my pc is completly freeze and and can't press button to collect logs |
I went through podman/docker desktop/rancher desktop/k3d/kind with 0.65.3 and as far as I can tell, it's fixed now. Thank you @benhillis and team for the fast fix, really appreciated |
I haven't tested it myself yet with the new version but I can only say also thanks especially for the extremely fast response time and fixes. Very much appreciated. |
Thanks everyone for the kind words, we're working on a fix here because the new localhost behavior is really neat (minus this bug). @hf35 - please file a new issue, that is unrelated. |
I downgraded wsl, rolledback windows update, tried all the combinations possible but nothing works, when I run any of my WebApp (React, Next, Nuxt, etc) and try to access https://localhost:3000, I keep getting WSL Versions tried: 0.65.3, 0.64.0, 0.61.8 $ ver $ wsl.exe --status |
@Ankit1598 Make sure you are not hitting #5575 |
I'm quite sure it is unrelated to this issue. Maybe you should try to use
http instead of https ?
|
The same issue appears on wsl 1.1.0 (now installed by default on insider previews). Downgrading to 1.0.3 fixed for me |
Yup, same for me. |
Same with WSL 1.1.0 for me. Works if i downgrade to 1.0.3. Maybe create a new issue? Seems to be some localhost related updates in 1.1.0: https://github.com/microsoft/WSL/releases/tag/1.1.0 Updated issue here: #9508 |
Back from the dead! Sorry for the inconvenience. This issue you're experiencing in 1.1.0 is currently being worked on and tracked at #9508 This issue, 8679, tracked other problems with the relay. |
same behavior again, downgraded from 1.1.2 to 1.0.3 and worked:
|
Popped up for the first time up after upgrading to 1.1.3:
|
@Persedes, I just realized that this bug was tracking code that was reverted. Could you open a new bug and post logs? Thanks! I'm going to lock this thread to direct people elsewhere. |
Version
Microsoft Windows [Version 10.0.25169.1000]
WSL Version
Kernel Version
5.15.57.1
Distro Version
Ubuntu 20.04
Other Software
No response
Repro Steps
Expected Behavior
Whatever is running on localhost:3000 in WSL is getting delivered to the Browser requesting it.
Actual Behavior
Edge get's an
ERR_CONNECTION_REFUSED
error.Accessing through the IP address of eth0 with the port works. So f.e. http://localhost:3000 or http://127.0.0.1:3000 fail, but http://172.25.170.221:3000 works.
This worked until this morning when I updated to the latest version (0.65.1) in the store.
Diagnostic Logs
No response
The text was updated successfully, but these errors were encountered: