69

I am trying run vagrant but after vagrant up error appears:

No usable default provider could be found for your system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.

I installed before VirtualBox version 4.3.26 r989888 and Linux Ubuntu (64 bit)

After: vagrant box add precise32 http://files.vagrantup.com/precise32.box

==> box: Adding box 'precise32' (v0) for provider: box: Downloading: http://files.vagrantup.com/precise32.box box: Progress: 100% (Rate: 1425k/s, Estimated time remaining: --:--:--) ==> box: Successfully added box 'precise32' (v0) for 'virtualbox'!

when I list vagrant box list

lucid32   (virtualbox, 0)
precise32 (virtualbox, 0)

What is wrong with "provider"

vagrant package --base vagrant-ubuntu64

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.

How to help him detect VirtualBox ?

Scott Stensland
  • 26,870
  • 12
  • 93
  • 104
Tomasz
  • 1,368
  • 3
  • 17
  • 31
  • 2
    The error message says Vagrant cannot access VBoxManage. Open your terminal type VBoxManage and check if it is recognized. If not then find the VBox location on your file system (where you will see VBoxManage) and add it to your PATH as instructed by Vagrant message. It should do the trick. – Arek Czarnogłowski Apr 05 '15 at 20:05

8 Answers8

55

Quick note - Vagrant 1.8.4 and Virtualbox 5.1.X aren't compatible on MacOS 10.11 (can't set a provider).

Virtualbox 5.0.10 works just fine.

etusm
  • 4,082
  • 1
  • 30
  • 26
  • Thanks for reporting! Was struggling for a while now. – psiyumm Jul 14 '16 at 12:39
  • 1
    Dude! Life saver, this should be the answer for OSx 10.11 – feilong Jul 14 '16 at 16:05
  • Correct. Unfortunately vagrant up doesn't report this. For the records: vagrant package --base trusty Vagrant has detected that you have a version of VirtualBox installed that is not supported by this version of Vagrant. Please install one of the supported versions listed below to use Vagrant: 4.0, 4.1, 4.2, 4.3, 5.0 – Steffo Jul 14 '16 at 18:50
  • 2
    FYI: Vagrant 1.8.5 should work with 5.1 (just checked Vagrant's changelog on Github), but is unreleased as of today. – gottlike Jul 17 '16 at 19:05
  • Awesome - Just installed 5.0.14 on MacOS 10.12 without error. I could run the stock vagrant box and an install of VirtualHostX 7 without error :) – itsricky Jul 18 '16 at 05:46
  • 1
    Verified this fixes it, here is the bug: https://github.com/mitchellh/vagrant/issues/7578 – Taylor Hughes Jul 20 '16 at 18:13
  • Same problem on Ubuntu 16.06. Had to donwload Vagant 1.8.5 from their site as the apt package version was only at 1.8.1. – ArneHugo Sep 05 '16 at 09:13
  • 1
    Had similar issue with Vagrant 1.9.1 with older versions of virtual box. I installed virtual box 5.1 and it works perfect. – Teddy Belay Jan 12 '17 at 02:25
  • As comment above, I had this issue... updating to Virtualbox 5.1.26 and Vagrant 1.9 works on OSX 10.11 El Capitan :) – Leon Sep 06 '17 at 10:27
23

I was able to fix this simply by installing the latest version of Vagrant (as of this writing 1.7.4).

Adam
  • 1,755
  • 20
  • 31
  • 1
    I was on Vagrant 1.7.2 and VirtualBox 5.0.8 and upgrading to Vagrant 1.7.4 fixed this for me too – icc97 Nov 04 '15 at 14:23
  • 1
    Actually 1.7.4 only made partial progress for me. What ultimately fixed it was removing the .vagrant folder from the project directory. – Ricky Nelson Dec 05 '15 at 19:16
  • 2
    Thanks! -- updating to Vagrant 1.8.1 with VirtualBox 5.0.10 worked for me as well. Did not have to remove the .vagrant file. Now somebody tell us why. :) – Valerie Parham-Thompson Jan 19 '16 at 04:37
22

simply try to bring vagrant up and specify provider you want to use:

vagrant up --provider virtualbox

As per screenshot below, it will tell you the reason why specified provider is not working. In my case, it was an unsupported version of VirtualBox 5.2. I had to downgrade it to v 5.1

enter image description here

Serge V.
  • 3,377
  • 3
  • 20
  • 28
8

There seems to have been an issue reported since VirtualBox 4.3.12:

VirtualBox automatically create the following environment variable VBOX_MSI_INSTALL_PATH

However, vagrant (if you look for the base.rb file) uses the variable VBOX_INSTALL_PATH

So you can - update the variable name VBOX_MSI_INSTALL_PATH and change it to VBOX_INSTALL_PATH - create a new variable name VBOX_INSTALL_PATH with the same value as VBOX_MSI_INSTALL_PATH

Reminder on windows go to My Computer (right click) --> Properties --> Advanced System Settings --> Environment Variables and look for the variable you need to manage

Frederic Henri
  • 51,761
  • 10
  • 113
  • 139
  • Thank you for providing the most in depth and insightful answer. So many of the responses on this particular question on other threads of this same topic provide a generic "this worked for me" without an explanation of what the root cause is, and plausible resolutions. – truedat101 Feb 19 '18 at 21:12
5

ok so I was having the same issue with windows, vagrant and virtualbox and did this.

  1. click on "This PC" / "My Computer" on windows desktop
  2. Select "Properties"
  3. Go to "Advanced" tab
  4. Click "Environment Variables..." at the bottom
  5. Under System Variables click "New..."
  6. Set "Variable name" to "VBOX_INSTALL_PATH"
  7. Set "Variable value" to "C:\Program Files\Oracle\VirtualBox\"
  8. Select "OK" and close all the other settings windows

credit goes to here: https://github.com/mitchellh/vagrant/issues/3852

I am assuming that there is a Environment Variable ( or PATH for linux users I think :P) that needs the "path" to the virtualbox executable.

Ruben Arevalo
  • 367
  • 2
  • 4
  • 8
2

I'm running macOS 10.12 and installed vagrant 5.1 using homebrew.

I got the same error as the OP and fixed it by downloading the latest version of VirtualBox (v5.1.6).

N.B. This version is labeled amd64 on the download page, this is just the name of the 64 bit standard and will install fine on Intel macs.

Pete
  • 76
  • 5
2

I had installed Virtualbox 6.1 and Vagrant 2.2.6 and got this error on a Mac. I had to revert Virtualbox to 6.0 and then vagrant up worked with ubuntu/trusty64. See @Serge Voloshenko's answer above for how to discover if it's a compatibility issue.

inostia
  • 7,777
  • 3
  • 30
  • 33
0

It is just the Version problems either it can be problem from vagrant or from Virtual box to connect

Try this : vagrant up --provider virtualbox

Above command will help if the version of virtual box is compatible or not and it will also suggest which are the current linkable versions of Virtual box

Currently : 4.0,4.1,4.2,4.3,5.0,5.1,5.2 are the versions of virtual box that are working

By the way, If you are worrying about version of Vagrant, I have tried current version : 2.0.3

miltone
  • 4,416
  • 11
  • 42
  • 76