Why is my docker machine not working under OSX?

1

I've installed Docker Toolbox v1.8.1b on OSX 10.10.5

This also installs VirtualBox v5.0.2

However, when the installation has finished and I run the Docker Quickstart Terminal, it does its thing, creates a new VM in virtualbox but then doesn't start it, finishing with the message that default is not running.

When I try to run the machine using docker-machine start default I get the message exit status 1.

When I go to VirtualBox and attempt to start the machine there, I get the following error message:

Failed to load VMMR0.r0 (VERR_VMM_SMAP_BUT_AC_CLEAR).


Result Code: 
NS_ERROR_FAILURE (0x80004005)
Component: 
ConsoleWrap
Interface: 
IConsole {872da645-4a9b-1727-bee2-5585105b9eed}

So is anyone else getting this or am I not following the instructions properly?

docker
docker-machine

3 Answers

5

I had exactly the same problem. It seems that there is a bug in recent versions of VirtualBox, which is fixed in the latest test build. See https://www.virtualbox.org/ticket/14412

I downloaded the latest VirtualBox test build from https://www.virtualbox.org/wiki/Testbuilds then used the uninstaller script provided in that installer to remove the buggy version before installing the new one.

Running the Docker QuickStart Terminal again got the default VM running, but it was missing a ca.pem file:

docker is configured to use the default machine with IP 192.168.99.100
For help getting started, check out the docs at https://docs.docker.com

open /Users/justin/.docker/machine/machines/default/ca.pem: no such file or directory

VirtualBox confirmed that the VM was running.

I could create a new VM and use it with docker successfully (in a different Terminal window):

Justins-MacBook:~ justin$ docker-machine create --driver virtualbox dev
Creating VirtualBox VM...
Creating SSH key...
Starting VirtualBox VM...
Starting VM...
To see how to connect Docker to this machine, run: docker-machine env dev
Justins-MacBook:~ justin$ eval "$(docker-machine env dev)"
Justins-MacBook:~ justin$ docker run hello-world
...

I then deleted the default VM:

Justins-MacBook:.docker justin$ docker-machine stop default
Justins-MacBook:.docker justin$ docker-machine rm default
Successfully removed default

Running the Docker QuickStart Terminal created a new default VM, and docker is now working happily with it.

Update: There is an open issue for this at: https://github.com/docker/toolbox/issues/119

answered on Stack Overflow Aug 23, 2015 by Justin Forder • edited Aug 23, 2015 by Justin Forder
0

ON Osx after installing docker or updating docker we have to reinstall the docker-machine again to make it work in CLI. Running the command below helped me.

base=https://github.com/docker/machine/releases/download/v0.16.0 &&
curl -L $base/docker-machine-$(uname -s)-$(uname -m) >/usr/local/bin/docker- 
machine &&
chmod +x /usr/local/bin/docker-machine
answered on Stack Overflow Feb 6, 2020 by shivanikoko
0

Just wanted to add: if you have docker for mac installed, they intentionally removed the docker-machine command starting from version 2.2.0.

You can find the discussion here: https://github.com/docker/for-mac/issues/4208

So, you need to install docker-machine separately, using the commands provided by @shivanikoko or using brew:

brew install docker-machine
answered on Stack Overflow Feb 17, 2020 by gbalduzzi

User contributions licensed under CC BY-SA 3.0