Switch Vagrant to use Parallels instead of VirtualBox

10,398

Solution 1

While it's not Parallels (which you may have already paid for), there is a plugin for using VMWare Fusion:

http://www.vagrantup.com/vmware

The plugin is not free, so you'll need to buy licenses for both the plugin and Fusion.

I get a kernel panic in my VM a few times a week. According to Mitchell, VirtualBox has had kernel panic issues on Macs for years that have never been well resolved, and swapping to Fusion is the best alternative.

Solution 2

Maybe this will help you (fresh and new)

https://github.com/yshahin/vagrant-parallels

Solution 3

Finally there is an official Vagrant Provider from and for Parallels! Unfortunately it's not mentioned on www.vagrantup.com.

See Paralles' Vagrant Documentation and the Parallels GitHub page of the Vagrant provider project. For further questions about the provider there is a dedicated official forum.

As of now there is just one limitation: "The Parallels provider supports all basic Vagrant features, except the next: "Forwarded ports" configuration is not available yet." (taken from the readme on GitHub)

Thank you, AgentK, for pointing out that that "Forwarded ports" are available as of Parallels 10 for Mac.

Solution 4

There was a large commit a few month ago, that merged the machine-abstraction branch:

which was even discussed a bit on Hacker News.

This branch brings in the "machine abstraction" code. This is a major milestone in the development of Vagrant as it abstracts all of the VirtualBox-specific code out into a plugin.

The gotcha:

White it is technically possible now to write plugins for other providers, there is still major work to be done to make this feasible.

And as of now, the only provider in master is virtualbox:

Solution 5

You can use Parallels with Vagrant. Here's a line by line set of instructions to do so (assumes you have Parallels and Vagrant installed).

  1. $ vagrant plugin install vagrant-parallels
  2. $ mkdir some-project/ && cd some-project
  3. $ vagrant init parallels/ubuntu-14.04
  4. $ vagrant up --provider parallels

Note, you only have to install vagrant-parallels once. Also note, you only have to pass in --provider parallels the first time you up, after that it will automatically use the parallels provider.

Share:
10,398
Wojciech Bednarski
Author by

Wojciech Bednarski

Software Engineer. Generation Y. Fiery Red person by Insight psychology test. Key values: competitive, determined, strong-willed, purposeful. https://www.linkedin.com/in/bednarski/

Updated on July 22, 2022

Comments

  • Wojciech Bednarski
    Wojciech Bednarski almost 2 years

    Is it possible to use Parallels instead of (insane slow) VirtualBox in Vagrant?

  • Wojciech Bednarski
    Wojciech Bednarski about 11 years
    Thank you! This is absolutely fantastic! I have Parallels but everything is better then Oracle VM, so I'm going to by Fusion right away.
  • andilabs
    andilabs about 10 years
    @WojciechBednarski could you share what is your expirience now on Mac OS X + VMWare Fusion + Vagrant? I am now using vagran with free VirtualBox on OS X and sometimes it is very unstable.
  • andilabs
    andilabs about 10 years
    @Gabe will it be easy to cooperate on same project with other collegeus using vagrant + virtualbox on Linux, when I start using vagrant + vmware fusion?
  • Wojciech Bednarski
    Wojciech Bednarski about 10 years
    @andi Fantastic, for example compilation time inside VM dropped from about 10min to 2min - same project same hardware. There is however some issue introduced in VMware Fusion 6.0.2 with sharing folders and some people have issue with it.
  • andilabs
    andilabs about 10 years
    @WojciechBednarski dzięki! so would you suggest to stay by fusion version 5?
  • Wojciech Bednarski
    Wojciech Bednarski about 10 years
    @andi or use 6.0 or 6.0.1
  • Gabe Martin-Dempesy
    Gabe Martin-Dempesy about 10 years
    @andi I believe each provider has a different "box" file format, so you would have to build separate VMs for VirtualBox and VMware.
  • wedi
    wedi over 9 years
    @AgentK: I incorporated your editing suggestion. Thanks!
  • ruslaniv
    ruslaniv about 6 years
    Worth mentioning that you can use Vagrant only with subscription based Pro or Business versions. Not with regular perpetually licensed Home version unfortunately.