Category Archives: Virtualization

Vagrant error: Your VM has become inaccessible.

If you’ve deleted a virtual machine file still referenced by one of your projects, you’ll run into the following error when you try and instantiate the VM via vagrant up.

Your VM has become “inaccessible.” Unfortunately, this is a critical error with VirtualBox that Vagrant can not cleanly recover from. Please open VirtualBox and clear out your inaccessible virtual machines or find a way to fix them.

Vagrant creates a hidden folder within your project directory named .vagrant with files that refer to specific VM IDs.

.vagrant

Simply delete the .vagrant folder within your project and rerun vagrant up. Vagrant will rebuild the .vagrant directory with the correct files and ID.

For giggles, here’s a Github issue page regarding this with a few more details.

Posted in Code, Devops, Vagrant, Virtualization | 39 Comments

Vagrant error on OSX: Command: [“hostonlyif”, “create”]

I’ve found I occasionally run into an odd Vagrant error every now and then:

There was an error while executing `VBoxManage`, a CLI used by Vagrant for controlling VirtualBox. The command and stderr is shown below.

Command: [“hostonlyif”, “create”]

For me, this sometimes happens when I try to re-instantiate a virtual machine after my laptop’s battery has died and OSX has attempted to restore state. Other people seem to encounter this error under different conditions; even immediately after installing Vagrant and attempting to spin up a virtual machine for the first time.

Run the following command to bounce VirtualBox:

sudo /Library/StartupItems/VirtualBox/VirtualBox restart

and now running:

vagrant up

should go off without a hitch.

Posted in Code, Devops, OS X, Vagrant, Virtualization | Leave a comment