OS X下的docker,會出現下面錯誤:html
FATA[0032] An error occurred trying to connect: Get https://192.168.59.103:2376/v1.16/version: dial tcp 192.168.59.103:2376: i/o timeout
不是辦法的辦法是:恢復初始狀態,這意味着之前下載的p_w_picpaths沒了,原來的container也沒了...git
boot2docker stop boot2docker destroy
boot2docker init boot2docker up docker version
http://cxwangyi.github.io/notes/2015-01-13-docker-pitfalls.html github
docker version
command complainsdocker
FATA[0032] An error occurred trying to connect: Get https://192.168.59.103:2376/v1.16/version: dial tcp 192.168.59.103:2376: i/o timeout
while docker upgrade
shows that the client tne the server are of the same version (which means they should work together).app
The problem is because that I had created a host-only network vboxnet0
before in an experiment of building a VM cluster using VirtualBox on my Mac mini, and boot2docker init
would also create a boot2docker VM that uses vboxnet0
. However, boot2docker VM expects that the local network vboxnet0
has IP prefix 192.168.53.xxx, whereas my vboxnet0
has another IP prefix.tcp
The solution is simple:ide
Stop and destory boot2docker VM:ui
boot2docker stop boot2docker destroy
Delete my vboxnet0
local network from VirtualBox.spa
Recreate boot2docker VM and start it:code
boot2docker init boot2docker up docker version
When I run docker build
, it complains not enough disk space.
When above error happends with boot2docker, it means that the boot2docker VM, other than using has not enough disk space.
Clone the VMDK disk p_w_picpath created by boot2docker init
into a VDI p_w_picpath, enlarge it, mount it to VM, and repartition it. More details can be found here.