Windows 8.1: Vagrant was unable to detect VirtualBox! Make sure VirtualBox is installed correctly.

This question is what I will answer in the hope that anyone with the same problem will be able to solve the problem without too many head bangs, as I did!

I just installed VirtualBox (4.3.16) and Vagrant (1.3.5) according to the instructions on my website. Everything seemed pretty clear and easy until I got to the command: vagrant up

This immediately returned an error:

Vagrant could not detect VirtualBox! Make sure VirtualBox is properly installed. Vagrant uses the `VBoxManage` binary that ships with VirtualBox, and requires this to be available on the PATH. If VirtualBox is installed, please find the `VBoxManage` binary and add it to the PATH environmental variable. 

This is an amazing error message ... Where should I find this PATH variable ???

+5
source share
4 answers

I found many suggestions on how to fix this, but none of them helped until I finally found that someone mentions that VirtualBox renamed the variable name, I still had to find where it happened after some additional digging, this is the solution that finally got the job done:

Locate the following file (the default installation path in Windows 8.1):

 C:\HashiCorp\Vagrant\embedded\gems\gems\vagrant-1.3.5\plugins\providers\virtualbox\driver\base.rb 

Open this file in your favorite text editor and search and replace all instances of VBOX_INSTALL_PATH with VBOX_MSI_INSTALL_PATH

Hope this helps someone get started with Vagrant and VirtualBox!

+7
source

You need to run vagrant from an elevated prompt, i.e. cmd should be "Run as administrator".

Wagrant (or VBoxManage.exe , for that matter) does not have to be in your PATH environment variable. The Virtual Box installer automatically sets the environment variable VBOX_INSTALL_PATH or VBOX_MSI_INSTALL_PATH , which Vagrant uses to find it, but Vagrant cannot start it if it has not been raised.

+10
source

For Vagrant 1.6.5 and Virtual Box 4.3.18, I believe that only rebooting the computer after installing the virtual box was a trick (I also reinstalled Vagrant)

+1
source

I had the same problem, however I had a version of Vagrant about 6 months ago, so I upgraded to the latest version and worked without any other changes.

https://www.vagrantup.com/downloads.html

0
source

Source: https://habr.com/ru/post/1203095/


All Articles