If you use Vagrant and Ubuntu VMs with VirtualBox provider, could happen that you don't have internet connection inside the VM and this leads to the pain in one place when you want to install some software or so...
If you strugle with it, add those lines to the Vagrantfile and your life will be better :)
config.vm.provider "virtualbox" do |v|
v.customize ["modifyvm", :id, "--natdnshostresolver1", "on"]
v.customize ["modifyvm", :id, "--natdnsproxy1", "on"]