To install and use .box extension machine we have to follow these steps:
1. Installing Virtualbox:
$ sudo apt-get install virtualbox $ sudo apt-get install virtualbox-dkms
2. Installing vagrant:
Please don’t install the repository version, because this is very old and the commands don’t work.
Download the latest package through this:
$ wget https://releases.hashicorp.com/vagrant/1.8.1/vagrant_1.8.1_x86_64.deb $ dpkg -i vagrant_1.8.1_x86_64.deb
3. Go to the location where the box is located, in my case location is in Download folder:
root@nitin.pant:Download# vagrant init ubuntu/trusty64 root@nitin.pant:Download# vagrant up Bringing machine 'default' up with 'virtualbox' provider... ==> default: Importing base box 'ubuntu/trusty64'... ==> default: Matching MAC address for NAT networking... ==> default: Checking if box 'ubuntu/trusty64' is up to date… ==> default: Setting the name of the VM: prd-ldap01-lim_default_1451607183195_24962 ==> default: Clearing any previously set forwarded ports… ==> default: Clearing any previously set network interfaces... ==> default: Preparing network interfaces based on configuration... default: Adapter 1: nat ==> default: Forwarding ports... default: 22 (guest) => 2222 (host) (adapter 1) ==> default: Booting VM... ==> default: Waiting for machine to boot. This may take a few minutes... default: SSH address: 127.0.0.1:2222 default: SSH username: vagrant default: SSH auth method: private key
Now your box machine ready to use. It will be in VirtualBox now, and start it from there or use it according to your requirements.