There are a few different virtual machine infrastructures now. Which one is least tedium depends on host.
If you are running OSX, the mostly-open-source virtualbox is acceptable.
If you are running linux on modern x86-64, IMHO the libvirt/QEMU-KVM system is more transparent, seems to be faster, and, surprisingly, easier. (surprsingly because it has terrible graphical design which is usually a signifier of other terrible things)
At the bottom I mention some other VM-ish infrastructure which I don’t truly understand but might wish to explain to myself in the future
How to get a Virtualbox virtual machine running with the minimum of dicking around, on osx.
This is from a year ago. I hope things have improved since then.
For the sake of argument, let’s assume Ubuntu/Debian/Mint or one of those other dpkg distributions.
Set up all the following things.
What? Didn’t work for you? ‘Course not. There are details.
Virtualbox extensions need extra installation because why would you want things to just work by default? Your favourite thing to do is dick around with yak shaving right?
Shared folders should now work.
Wait what? Integration is STILL flakey? You still need to install the Guest additions, you duffer:
sudo apt-get install dkms
Didn’t work, eh? Maybe you don’t have the right sources in your package manager:
sudo bash echo "deb http://download.virtualbox.org/virtualbox/debian wily contrib" \ >> /etc/apt/sources.list.d/oracle.list # http doesn't work because oracle were too poor to spring for the right cert wget -q https://www.virtualbox.org/download/oracle_vbox.asc -O- | apt-key add - apt-get update apt-get install dkms
Virtual box also ships with a virtual CD image with the right installers on, hidden in a submenu somewhere, which saves bandwidth.
You can skip some of these steps if you are happy to trust a complete stranger to build your OS for you; osboxes hosts some prebuilt machines of suspect pedigree.
What a disaster of naming! What a shit name! What a remarkably tidy and easy bit of technology. It exploits some hardware+kernel tricks the others don’t, apparently. I don’t really pretend to understand the stack here.
Even the GUI, virt=manager, though of course awful as nearly all GUIs are, is barely worse than the other VM GUIs with massive commercial backing.
On ubuntu, do this
sudo apt install virt-manager libvirt-bin qemu-kvm
Now everything magically works if you run virt-manager, which creates new KVM machines for you in the usual VM way. Has AFAICT all the features I care about in Virtualbox without any extra download.
Don’t really know what vagrant is
If you are a developer, Vagrant will isolate dependencies and their configuration within a single disposable, consistent environment, without sacrificing any of the tools you are used to working with (editors, browsers, debuggers, etc.). Once you or someone else creates a single Vagrantfile, you just need to vagrant up and everything is installed and configured for you to work. Other members of your team create their development environments from the same configuration, so whether you are working on Linux, Mac OS X, or Windows, all your team members are running code in the same environment, against the same dependencies, all configured the same way
Want an OS that uses modern hardware virtualisation to run apps separately to improve your privacy?
Qubes, the VM-based OS, does that. Very tinfoil-hat and CPU wasting, but if you are going to insist on doing high-security things, probably worthwhile.
Not sure how this weathers meltdown and spectre Intel CPU bugs, but possibly badly.
Maybe you want to run Qubes on an AMD CPU, eh?
Many of these. For practical purposes, people usually mean docker when they say this.
See containerized apps.