Vagrant is excellent tool for creating easily new virtual machines. It takes less than 1 minute (image downloading take some times) getting vagrant up. If you would like to management multiple virtual machines easily select vagrant. In this instructions we create first new virtual machine and after that we build same time multiple virtual machines.
Next you download Ubuntu 14.04 (trusty32) box (like vagrant call their images). When we add image to box vagrant keep its in the memory, and we could then use it to later:
Generating vagrant's initializing file. Vagrantfile generating in to same directory where you give that command. Vagrantfile include config class which tell vagrant what you want to do with it. Now we just want to do only one virtual machine, but later we have to little bit modify this config-file, if we want to building up multiple virtual machines:
Set Vagrant up
And take connect to vagrant by ssh:
If you want destroy our virtual machine, you could give command:
Multiple virtual machines
Now we are successfully create new virtual machine. But, we want something more. We would like to create multiple virtual machines. First we have little modify our config vagrantfile.
And Vagrantfile code is:
We made two virtual machines "virtual1" and "virtual2". Line v.vm.box = "trusty32" tell that we use trusty32 box.
Set up multiple Vagrants
Virtual machines getting up, and when they are ready you can take connect to them by command:
And you can destroy them by command:
EDIT 2014-10-05: Update precise32 (Ubuntu 12.04) to trusty32 (Ubuntu 14.04).