LoginSignup
0
0

More than 3 years have passed since last update.

docker-machineでホスト(Virtualbox)を立ち上げる際にエラーになる

Last updated at Posted at 2021-01-23

とあるDockerの教材をもとに、docker-machineを使用してVirtualboxをホストとして立ち上げた際に下記エラーが出力しました。

$ docker-machine create --driver virtualbox default
Creating CA: /Users/.docker/machine/certs/ca.pem
Creating client certificate: /Users/.docker/machine/certs/cert.pem
Running pre-create checks...
Error with pre-create check: "VBoxManage not found. Make sure VirtualBox is installed and VBoxManage is in the path"

対応

単純に使用していたmacのPCにVirtualBoxが入っていなかっただけでした。
下記OracleのサイトからVirtualBoxをダウンロードしてインストールしたところ問題なく立ち上がりました。

$ docker-machine create --driver virtualbox default
Running pre-create checks...
(defalut) Image cache directory does not exist, creating it at /Users/.docker/machine/cache...
(defalut) No default Boot2Docker ISO found locally, downloading the latest release...
(defalut) Latest release for github.com/boot2docker/boot2docker is v19.03.12
(defalut) Downloading /Users/.docker/machine/cache/boot2docker.iso from https://github.com/boot2docker/boot2docker/releases/download/v19.03.12/boot2docker.iso...
(defalut) 0%....10%....20%....30%....40%....50%....60%....70%....80%....90%....100%
Creating machine...
(defalut) Copying /Users/.docker/machine/cache/boot2docker.iso to /Users/.docker/machine/machines/defalut/boot2docker.iso...
(defalut) Creating VirtualBox VM...
(defalut) Creating SSH key...
(defalut) Starting the VM...
(defalut) Check network to re-create if needed...
(defalut) Found a new host-only adapter: "vboxnet0"
(defalut) Waiting for an IP...
Waiting for machine to be running, this may take a few minutes...
Detecting operating system of created instance...
Waiting for SSH to be available...
Detecting the provisioner...
Provisioning with boot2docker...
Copying certs to the local machine directory...
Copying certs to the remote machine...
Setting Docker configuration on the remote daemon...
Checking connection to Docker...
Docker is up and running!
To see how to connect your Docker Client to the Docker Engine running on this virtual machine, run: docker-machine env defalut
$ 

最後に

しれっと教材ではVirtualBoxでホストを立ち上げてましたが、VirtualBoxをインストールしていなければ立ち上がりませんよね。基本的なことですが、いきなり出くわすと面食らっちゃいますね。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0