i run CentOS in VirtualBox on physical Windows7. Now in centOS i have Docker and i need to run
docker-machine create --driver virtualbox host1
but i get error
Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path"
so do i need to install VirtualBox once again and in the CentOS? If yes, how can i do that?
thanks lot
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.
Being more specific about install VirtualBox on Mac Mojavi.
After downloading the VirtualBox-6.0.6-130049-OSX.dmg, double-click to install
Go to your applications folder and you will find the virtualbox.pkg like this:
Click on it to complete the installation.
After install is complete, you should see VirtualBox in the applications folder like this:
Afterwards you should refresh your terminal and rerun your command.
docker-machine create --driver virtualbox local-docker.
try to execute with superuser:
sudo docker-machine create -d virtualbox myvm1
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With