# AI and Predictive Analytics in Datacenter Environments # http://dcai.bsc.es # Vagrant and VirtualBox # # Install VirtualBox (virtualizer) and Vagrant (manager of VM images). Commands for Ubuntu/Debian: sudo apt-get install virtualbox vagrant # If you use MacOS or Windows, check these URLs for instructions to install VirtualBox and Vagrant: # - https://www.virtualbox.org/wiki/Downloads # - https://www.vagrantup.com/downloads.html # Example with Ubuntu # # Download a pre-installed VM with Ubuntu Xenial: mkdir vm_test # Create a working directory cd vm_test # Enter the directory vagrant init ubuntu/xenial64 # Download the "VM descriptor" # Now we modify the “VM descriptor”, to tell the VM to use 4GB of RAM. # Open the file “Vagrantfile”, and add the following lines in the configuration, in between the “config” tags: # config.vm.provider "virtualbox" do |vb| vb.memory = "4096" end # Start Up the VM vagrant up # Download (1st time) and Start the VM # Entering the active VM vagrant ssh # Opening a Secure-Shell session # Inside the VM # # - To exit the VM just type “exit”. # - To stop the VM use the command “vagrant halt” (from outside the VM). # - To start the VM again use the command “vagrant up”. # - To delete the VM use “vagrant destroy”, and when doing “vagrant up” again, the VM will be downloaded as new.