12

How can I install Vagrant 1.0.6. with an already manually installed VirtualBox 4.2.6 on Ubuntu 12.04? All of my known ways fail:

  1. Download *.deb file for 64bit and dpkg --install vagrant_x86_64.deb gives me the error Vagrant not installed. Use apt-get install vagrant after using vagrant up.
  2. Using apt-get install vagrant wants to remove (!) my manual VirtualBox installation.

What to do?

mcbetz
  • 3,009
  • 7
  • 28
  • 40

3 Answers3

9

Use:

apt-get install vagrant --no-install-recommends

as a work-around.

See https://bugs.launchpad.net/ubuntu/+source/vagrant/+bug/1125097

Eric Carvalho
  • 53,609
  • 102
  • 137
  • 162
3

Find you installed vagrant in /opt/vagrant and create a symlink on you local bin.

sudo ln -s /opt/vagrant/bin/vagrant /usr/local/bin/vagrant

Hope that helps.

mmrs151
  • 159
  • 1
  • 4
1

Up to 1.0.7 the recommended way of installing vagrant is through RubyGems.

Update: now that someone down voted the answer, I realized that it should be updated anyway.

NOTE: Since Vagrant 1.1.x (now 1.2.4) the recommended way of installation is using the install package (DEB, RPM) for Linux, DMG for OS X and MSI Windows.

If you have up-to-date ruby version installed, just gem install vagrant.

You can install ruby using package management, of course. However, rbenv/ruby-build or RVM is highly recommended, it's more flexible and works great in terms of managing ruby versions.

Update: since 1.2, recommended way of installing Vagrant is using the installers for your OS.

Terry Wang
  • 9,505
  • 4
  • 37
  • 30
  • Currently the vagrant documentation says,"But note that the packages [not the ruby gem] are the preferred and best supported method of installation." The answer about the symbolic link worked for me. P.S. Agree, however, about RVM in generally and specifically if using the vagrant gem. – GSP Feb 13 '13 at 01:25
  • Cool. Good to see it worked fine for you. I actually never tried to install the vagrant .deb package as I already have Ruby;-) – Terry Wang Feb 17 '13 at 23:08