2

This is my first time to learn the Docker, I follow the steps as Docker's instructions mentioned, but wen I run below command in the Boot2Docker Start: $ docker run hello-world, I got below error response:

An error occurred trying to connect: 
Post https://192.168.59.103:2376/v1.19/containers/create: Service Unavailable
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
Ray
  • 215
  • 1
  • 4
  • 12
  • What version of VirtualBox do you have? – VonC Aug 07 '15 at 05:56
  • Hi Vonc, the version is:4.3.28 r 100309. – Ray Aug 07 '15 at 06:35
  • As in http://stackoverflow.com/a/30466305/6309, can you try `boot2docker start`, `boot2docker shellinit`, and `boot2docker ssh`? – VonC Aug 07 '15 at 06:36
  • It is so cool. I got below response now:Docker version 1.7.0, build 0baf609 docker@boot2docker:~$ docker run hello-world Unable to find image 'hello-world:latest' locally Pulling repository hello-world Get https://index.docker.io/v1/repositories/library/hello-world/images: dial tcp 52.5.165.233:443: connection timed out. So it means the network issue or still has any other problems? – Ray Aug 07 '15 at 07:02
  • Are you behind a proxy? – VonC Aug 07 '15 at 07:03
  • I checked my LAN setting on browser, and make sure that use proxy check box is unchecked, and run again, still show time out:-(. – Ray Aug 07 '15 at 07:51
  • Do you have an HTTP_PROXY environment variable defined (in your docker session)? – VonC Aug 07 '15 at 07:56
  • Try `unset http_proxy=`, and `docker restart` – VonC Aug 07 '15 at 08:00
  • Vonc, I find I have one https_proxy environment variable defined, I see it in my system variable and delete it now, the result still as before(time out). – Ray Aug 07 '15 at 08:16
  • VonC,I tried your way, however, still shows timeout. anyway, I agree with you, I think this issue should be network issue, so mark my question get answer and thanks a lot! – Ray Aug 07 '15 at 10:03
  • Let me know if you find the root cause of that timeout issue – VonC Aug 07 '15 at 10:13
  • docker run -it -p 80:80 fe65a2781dae /bin/bash, use this command, it can resolve my issue. – Ray Aug 09 '15 at 03:11
  • Great: I have included your comment in the answer for more visibility. What image is represented by `fe65a2781dae`? – VonC Aug 09 '15 at 09:21
  • fe65a2781dae tell the image id that when Docker running use it. – Ray Aug 11 '15 at 06:04

1 Answers1

0

In order to reset/restart boot2docker:

boot2docker start
boot2docker shellinit
boot2docker ssh

After that, any connection issue could be due to a proxy.

The OP Ray resolves the timeout issue by opening a bash in a container:

 docker run -it -p 80:80 fe65a2781dae /bin/bash, 
Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250