for-win
for-win copied to clipboard
DNS Resolution Fails
Description
Starting docker desktop destroys DNS resolution in WSL 2 instances.
Please see this issue for extra details: https://github.com/microsoft/WSL/issues/11445
Reproduce
- Open WSL 2 instance integrated with docker desktop
- Open docker desktop
Expected behavior
$ ping google.com
should result in
PING google.com (142.250.189.142) 56(84) bytes of data.
64 bytes from mia09s26-in-f14.1e100.net (142.250.189.142): icmp_seq=1 ttl=116 time=5.39 ms
or similar
Instead I get
ping: google.com: Temporary failure in name resolution
docker version
4.29.0
docker info
unnecessary
Diagnostics ID
546D0419-D013-41FD-89C2-DC93C4345A54/20240416144617
Additional Info
As I mentioned in the WSL issue I linked,
I downgraded docker desktop to 4.24.0. Afterwards I was able to edit "bip" from docker engine in the app itself without error that 4.28.0 and later versions give. After setting bip, dns in WSL is working again.
Hello @aldobarr had the same issue. I downgraded Docker Desktop to version 4.27.2
https://docs.docker.com/desktop/release-notes/#4280 to work normally.
& '.\Docker Desktop Installer.old.exe' install --disable-version-check
I tried all the versions today between 4.27.2 and 4.24.2. All have the "bip" must be an ipv4 address
error after version 4.25.2. Although 4.25.0 - 4.25.2 do not have this error, the fix does not work on these version. From 4.25.0 onwards docker is completely unusable. 4.24.2 is the latest version I can use that works.
Resolution: https://github.com/microsoft/WSL/issues/11445#issuecomment-2097419554 https://github.com/microsoft/WSL/issues/11445#issuecomment-2129275411