-
Notifications
You must be signed in to change notification settings - Fork 292
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 pull images with WSL2 engine #6837
Comments
The EOF suggest a networking / firewall issue .. What happens if you get https://registry-1.docker.io/v2/library/nginx/manifests/latest with curl in WSL2 ? When i try to get this it needs a password , Have you tried a simple hello world container ? |
same behaviour here. Curl to the failed url (https://auth.docker.io/token\?scope\=repository%3Alibrary%2Fbusybox%3Apull\&service\=registry.docker.io) works without a problem. |
Currently facing the same issue here after a fresh Install of Windows, WSL2 Ubuntu 20.04 and Docker Desktop 2.3.0.3. Pulling any image from Docker Hub fails with the EOF error, but weirdly enough I can pull images from quay.io for example. The curls from above also seem to require authentication on my side (am logged in). |
Same issue here even with running hello-world |
I am facing the same issue. I also run a fresh installation of Windows, WSL2, Ubuntu and Docker. In Docker I can login to docker. But on command line it fails most of the time. When I try to perfom |
I just re-installed Windows 2004 from scratch (before, I did an upgrade, so I thought a fresh install might work). Even when using the getting started image
|
Same issue here, but only when i work directly in |
I checked it on my system. First in a subdir of ~, it gave the same error and also on another HD. It still gives the same error. The docker desktop apllication says that I am logged in but I am not able to login on command line. There I also get an orror with EOF. |
@PatrickGoettsch For me it was my router and after unchecking a setting it worked: This comment on another issue helped |
Thanks. Changing this helped and solved the issue for the moment. But this rises a question wether this problem is related to Docker or to in my case AVM? |
I would say Docker for Windows OR WSL related. I have a FritzBox as well, but I don't have a problem with pulling docker images on native linux works without any problems. It's just inside WSL 2 it doesn't work. I also think in WSL1 it worked as well without any problems. Maybe it's also a combination of the two. |
@kobelobster which ISP do you use? according to other issues it could be related to Vodafone since all people who where affected were either unitymedia or vodafone customer |
@mortensassi I am a Vodafone customer, however, I'm a Vodafone customer as well when working with Linux or using Docker without WSL2 and there it works without any problems. So I fail to see how it can be only related to AVM or Vodafone, if it works with the same components without Windows/WSL2. |
I have a similar issue.... If I pull an image or build from an image not cached locally, it just hangs. No error is thrown. However, I am able to pull images if I use |
This started happening to me yesterday. But first I had to reset docker to factory defaults because I couldn't start it anymore after a Windows 10 Pro Insider Preview upgrade |
It also started for me. As a workaround: I pull images in windows, after that they available in wsl2. |
same problem here. After i updated the latest insider preview i was getting stuck in pulling images. But i can pull image using windows command prompt. This error is only with wsl2. I cannot say that it is a problem with ISP since i was able to pull image on windows cmd. |
fixed by running with sudo |
I had the same problem and also couldn't build, and they were both related an auth issue. see my comment here If you run Edit: ...and now it doesn't work. Arg. Edit: Refer to #7808 |
Same issue here, was only able to pull images within WSL2 by using
Now in WSL2 (Ubuntu-18.04 or Ubuntu-20.04 with Docker Desktop integration):
|
Is there any fix for this? I can confirm pulling with sudo works, but I get an error when trying to do the same with docker-compose |
This workaround works for me - #7808 (comment) |
Laptop Asus reference this |
Issues go stale after 90 days of inactivity. Prevent issues from auto-closing with an If this issue is safe to close now please do so. Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows. |
Issue still exists - so please no stale... /remove-lifecycle stale |
/lifecycle frozen |
Observed something similar after upgrading to |
+1 |
Had the same issue, solved the same way as #6837 (comment) |
I meet the same problem ,but solved it by switch on 'Enable integration with my default WSL distro ' , |
Same here...gonna try some of these options to figure out which one works. I'm wondering whether it's stuff like this why people in my circle recommend no production containers on Docker on Windows...well, production Linux containers, anyway? |
I got it working. I've created a .wslconfig in %userprofile% (e.g. c:\users<yourusername>) and added
Then I modified /etc/wsl.conf in WSL
You probably don't need the hostname and generateHosts lines After that I reboot WSL Then resolv.conf wasn't available anymore in /etc so I created a new file: sudo nano /etc/resolv.conf
Change the nameservers to suit your needs. One more reboot and I now got docker working in WSL2 with cgroups and able to pull images without sudo. |
Does this work if you are hosting your own DNS, as well? (I have Technitium set up as a forwarder zone for a bunch of my stuff, and then as a sinkhole, as well.) not sure if that would muck anything up inside of this configuration?
From: Bertvdn ***@***.***>
Sent: Saturday, March 30, 2024 04:01
To: docker/for-win ***@***.***>
Cc: Katherine Moss ***@***.***>; Comment ***@***.***>
Subject: Re: [docker/for-win] Unable to pull images with WSL2 engine (#6837)
I got it working. I've created a .wslconfig in %userprofile% (e.g. c:\users<yourusername>) and added
[wsl2]
kernelCommandLine = cgroup_no_v1=all
dnsProxy = false
Then I modified /etc/wsl.conf in WSL
# Network host settings that enable the DNS server used by WSL 2. This example changes the hostname, sets generateResolvConf to false, preventing WSL from auto-generating /etc/resolv.conf, so that you can create your own (ie. nameserver 1.1.1.1).
[network]
hostname = ubuntu22-04-wsl
generateHosts = false
generateResolvConf = false
You probably don't need the hostname and generateHosts lines
After that I reboot WSL
Then resolv.conf wasn't available anymore in /etc so I created a new file:
sudo nano /etc/resolv.conf
search home.local
nameserver 192.168.40.1
nameserver 192.168.40.2
Change the nameservers to suit your needs.
One more reboot and I now got docker working in WSL2 with cgroups and able to pull images without sudo.
—
Reply to this email directly, view it on GitHub <#6837 (comment)> , or unsubscribe <https://github.com/notifications/unsubscribe-auth/ADS4MAAW7RGRC3VVEEX7EZDY2ZPMRAVCNFSM4NIMHBQKU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TEMBSG44TMMBSGY4Q> .
You are receiving this because you commented. <https://github.com/notifications/beacon/ADS4MAGV7U3HYMYMOVS5GU3Y2ZPMRA5CNFSM4NIMHBQKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOPDQDPTI.gif> Message ID: ***@***.*** ***@***.***> >
|
@Cambridgeport90 Not sure what you mean. If you want to pull public docker images you should be able to resolve public domain names. In my config I set it up to point to two pihole's but you could also point to to quad9 or something else. |
That’s what I was trying to figure out. Thanks!ß
From: Bertvdn ***@***.***>
Sent: Monday, April 1, 2024 10:29
To: docker/for-win ***@***.***>
Cc: Katherine Moss ***@***.***>; Mention ***@***.***>
Subject: Re: [docker/for-win] Unable to pull images with WSL2 engine (#6837)
@Cambridgeport90 <https://github.com/Cambridgeport90> Not sure what you mean. If you want to pull public docker images you should be able to resolve public domain names. In my config I set it up to point to two pihole's but you could also point to to quad9 or something else.
—
Reply to this email directly, view it on GitHub <#6837 (comment)> , or unsubscribe <https://github.com/notifications/unsubscribe-auth/ADS4MAA375QUWOCDMUS6N53Y3FVJRAVCNFSM4NIMHBQKU5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TEMBSHE4DINJVG43Q> .
You are receiving this because you were mentioned. <https://github.com/notifications/beacon/ADS4MAFTVGEUJLW7X6HZJGTY3FVJRA5CNFSM4NIMHBQKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOPD6PYSI.gif> Message ID: ***@***.*** ***@***.***> >
|
I have the same issue as in #6494, however I never had docker installed natively so I can't even uninstall it from WSL 2.
But running
docker
commands works without problemsHowever, when I now want to pull an image the image doesn't get pulled bc. of the error
Expected behavior
Actual behavior
And even when not using
docker-compose
butdocker
I also get an errorInformation
Steps to reproduce the behavior
This is a simple
docker-compose.yaml
I'm using, but like I said, even when usingdocker
instead ofdocker-compose
, I'm getting the same errorThe text was updated successfully, but these errors were encountered: