Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path"

Yes you are absolutely correct. You need to install VirtualBox first of all.

You can do it by running yum install virtualbox for CentOS or

sudo apt-get install virtualbox for Ubuntu

Do so and then run your code and you will be good to go


It's an issue with permissions. You've installed docker as sudo. You need to run

sudo docker-machine create --driver virtualbox host1

OR

sudo docker-compose up 

to get around this.


I faced the same error in Ubuntu 18.04 but I realized that I had installed docker-machine using command : sudo snap install docker.

However install docker-machine using :

$ curl -L https://github.com/docker/machine/releases/download/v0.13.0/docker-machine-`uname -s`-`uname -m` >/tmp/docker-machine && \
chmod +x /tmp/docker-machine && \
sudo cp /tmp/docker-machine /usr/local/bin/docker-machine

Check your installation :

$ docker-machine version

Then install virtualbox using :

$sudo apt install virtualbox

Now you can create the docker-machine using the command :

$ docker-machine create --driver virtualbox dev

Hope this helps.