A virtual machine (VM) is a simulation that uses your system resources, including processor cores, memory, and storage, to boot into an operating system without affecting the host system. VMs are almost as old as regular PCs, tracing their origin back to the 1960s when developers at IBM sought to improve resource utilization with the help of virtualization. Since then, virtual machines have witnessed tremendous growth in popularity among causal users and developers.
Virtual machines were my first introduction to the world of Linux and other operating systems when I was a Windows loyalist. Although I've now set up dual boot for Windows 11 and Linux on my desktop, I will still continue to use VMs for a variety of reasons.
1 Test new operating systems…
Do you want to try out a new OS but don't want to risk damaging your current operating system? Well, you can configure a VM to run a new operating system within minutes, if not seconds. Meanwhile, it can take hours to set up a fresh installation of the same OS on your host machine if you’re not familiar with dual and multi-boot setups.
Even setting aside the time taken to install a new OS, it’s a real hassle to set up a multi-boot environment on your PC. Another drawback of installing multiple operating systems is that you’ll have to restart your system every time you want to switch to another OS. Contrast that with the ability to run several operating systems at the same time on a VM and it’s hard to ignore the convenience.
2 … And break them without any repercussions
Setting up an OS is one thing, but what about playing around in one? There are plenty of ways to break an OS, and if you’re not careful enough, it’s possible to damage it beyond repair. Since a VM works in an isolated environment, you won't have to worry about accidentally damaging the host system when you're inside. Moreover, hypervisors like VirtualBox and Hyper-V (the software that runs the VM) allow you to test your favorite OS without causing permanent damage, thanks to a feature called a snapshot. This is like an image backup that creates a record of the state of your VM at a specific point in time — sort of like a checkpoint in a video game. You can then use snapshots to infinitely roll back changes.
So, even if you were to break the VM, you can load an older snapshot and continue right where you left off. Of course, you should never use them as a replacement for backups, but they can serve as a quick way to restore your system if you don’t mind the extra disk space occupied by multiple snapshots.
3 Use legacy software and hardware
There are plenty of outdated apps and games that may not run on your system due to the lack of compatibility with your current drivers and OS. This problem is especially true for ancient hardware and peripherals that haven’t seen updated drivers in ages.
VMs are a simple and effective way to boot outdated applications. You can even use them to work in legacy hardware as long as you have enough functioning ports that are compatible with the peripherals.
4 Run potentially malicious apps
Let’s say you downloaded software from a dubious website but don’t want to install it on your main PC. While a combination of Windows Defender, Malwarebytes, and common sense is enough to keep your system free of viruses, you can never be too careful when it comes to the security of your system. VMs come in handy by allowing you to run potentially malicious apps without compromising the security of your host PC.
Of course, you can’t just blindly install any application you find on the internet. There are still many viruses out there that can infect the host system if you aren’t careful. One of the safest ways to convert your VM into a malware-testing environment is to turn off the network adapter and disable all file-sharing services for the serial and USB ports to prevent the malware from escaping the VM.
5 High portability and fault-tolerance
VMs also have the added advantage of not being bound to a single PC. As long as you have the same hypervisor installed on two or more systems, you can easily create identical VMs across your computers. You can even use snapshots to share the changes you make to the VM with all your systems to resume your work when you cycle between your host machines.
Combine this with the full data recovery facility offered by snapshots, and virtual machines can be used to create and store backups of important files. In fact, you can even create a VM version of your host system and save all your data by exporting its snapshot to your favorite hypervisor.
Can virtual machines replace dual-booting?
With their ease of deployment, robust fault tolerance, and high data recovery, virtual machines are a fantastic way to get hands-on experience with a new operating system. That being said, VMs and hypervisors have their own set of limitations, namely a steep decline in performance for most hardware-intensive tasks. You’ll also need a beefy PC with a good processor and other components if you wish to run multiple virtual machines at the same time. So, virtual machines definitely won’t replace dual and multi-boot systems anytime soon.
But for casual users who want a convenient method to use obsolete software or test out an obscure Linux distro, creating a virtual machine is the most straightforward and easy-to-use solution.