Install Vagrant
To get started with Vagrant, download the appropriate installer or package for your platform from our Vagrant downloads page. Install the package with the standard procedures for your operating system.
The installer automatically adds vagrant
to your system path
so that it is available in terminals. If it is not found,
log out and back into your system; this is a common issue for Windows.
Rubygem installation is unsupported Vagrant 1.0.x has the option to be installed as a RubyGem. However, this installation method is no longer supported. If you have an old version of Vagrant installed via Rubygems, remove it prior to installing newer versions of Vagrant.
First development environment
If you are new to Vagrant, the next step to set up a development environment is to install a box.
How to use multiple hypervisors
Hypervisors often do not allow you to bring up virtual machines if you have more than one hypervisor in use.
Below are a couple of examples to allow you to use Vagrant and VirtualBox if another hypervisor is present.
Linux, VirtualBox, and KVM
If you encounter the following error message, it is because another hypervisor, like KVM, is in use.
You must add the additional hypervisors to the deny list in order for VirtualBox to run correctly.
First, find out the name of the hypervisor.
Use the blacklist
command to add the hypervisor to your denylist.
Restart your machine and try the vagrant
command again.
Windows, VirtualBox, and Hyper-V
If you encounter an issue with Windows, you will get a blue screen if you attempt to bring up a VirtualBox VM with Hyper-V enabled.
If you wish to use VirtualBox on Windows, you must ensure that Hyper-V is not enabled on Windows. You can turn off the feature with the following Powershell command for Windows 10.
For Windows 11, you can use an elevated Powershell.
You can also disable Hyper-V in the Windows system settings.
- Right click on the Windows button and select ‘Apps and Features’.
- Select Turn Windows Features on or off.
- Unselect Hyper-V and click OK.
You might have to reboot your machine for the changes to take effect. More information about Hyper-V can be read here.