Docker and Windows - A connection attempt failed because the connected party did not properly respond after a period of time
Asked Answered
I

3

8

I installed the docker toolbox but when i try to create a container it gives me that error. The version is returned but it's not possible to create a container.

OS: Windows 10 Home

ERROR: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
Informality answered 24/4, 2020 at 13:2 Comment(0)
K
6

I had the same problem with Docker Desktop (Year 2021). None of the solutions worked. Finally I tried the following and it worked.

  1. Remove the following environment variable from windows DOCKER_HOST
  2. In docker desktop settings enable the following option Expose daemon on tcp://localhost:2375 without TLS
Koons answered 7/10, 2021 at 13:32 Comment(3)
That worked like charm, thank you so much. And I didn't even exposed daemon. removing the DOCKER_HOST only did the trick :)Lateshalatest
Good to know it helped.Koons
This worked for me yesterday, but today same problem. So sadProposition
K
4

Other resources suggested to deinstall and install docker for windows or the toolbox again, or said you couldn't run both at the same time. But that was not the problem for me. Turns out I just needed to update VirtualBox 6.0 to 6.1.

TLDR; Is your docker vm even running? Are you using a troublesome VirtualBox version? Update!

Kellsie answered 13/8, 2020 at 8:22 Comment(3)
Hi! Thanks for the answer. It's been a while since I had this problem and I gave up back then. But I'll try it again! ThanksInformality
I had this problem today and it was because I stupidly forgot to start the docker vm.Oregano
In my case it was second docker-compose running. Stopping it was not enough - I had to also restart Windows.Kial
J
1

In 2024, I've encountered this issue, and I disabled WSL Integration for Ubuntu on Docker Desktop -> Settings -> Resources -> WSL Integration to fix the issue.

Jacey answered 11/2 at 9:23 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.