Virtual machines are an interesting technological resource that has been used since the 1960s to virtualize hardware, user sessions, storage or network devices, and of course software.
A fast, convenient and secure method to run operating systems, applications or games without having to touch the main system that acts as a host. It is used more and more in professional applications due to the increase in cloud computing infrastructures, but it is also a very interesting technology at the user level, be it for testing, running incompatible software, emulators, alternative operating systems, etc.
KEYS SUBSCRIBE TO THE NEW MCPRO NEWSLETTER
Digital Transformation in Spain PARTICIPATE AND SEND US YOUR SUCCESS STORY!
ICT investment trends in 2021 DOWNLOAD THE REPORT!
The operating systems supported by VMs are numerous (Windows, FreeBSD, GNU / Linux, OpenBSD, OS / 2 Warp, Solaris, MS-DOS, macOS under Hackintosh) and are only limited by the support of the virtualization software that we use. Not all work the same on different hardware and it depends on the type of hypervisor we use.
Starting with the simplest we have VirtualBox , free and free software, which allows us to install a lot of software on Windows, Linux, Macintosh and Solaris. Others like VMware are a true reference in the professional environment, but in addition to the paid versions, they offer the VMware Workstation Player version for free for non-commercial uses.
If you are using macOS, you will get the best performance with Parallels Desktop , although you can use the same VirtualBox or VMware Fusion , while for Windows, Microsoft offers its own native solution Hyper-V is integrated into Windows 10 Pro, Education and Enterprise and can easily enabled in the Windows features in the control panel or through a PowerShell command.
How to improve the use of virtual machines
Virtualization technologies are great, but they have a problem. Or to be more precise, they need a certain level of hardware because we have to give them a part of the resources (mainly processor, memory and storage) of the machine where we are going to install the virtual machines. Taking into account this important issue and even making it clear that at the consumer level it is difficult to obtain the same level of performance from a virtual machine as that obtained with a typical local installation, there are some issues where we can influence to improve the experience. We remind you:
1. Make sure Intel VT-x or AMD-V is available and activated
They are special extensions for processors that improve their virtualization capacity by activating hardware acceleration. Almost all the latest generation processors support them. AMD-V is enabled by default on supported models. With Intel processors it is different and the usual thing is that the Intel VT-x comes disabled by default, causing errors when using virtualization applications. The solution is simple and goes through entering the BIOS of the computer or the UEFI firmware configuration to activate this feature.
2. Create fixed-size and non-dynamic disks
When creating the virtual machine, you can choose between two different types of virtual disks. In general, applications such as VirtualBox or VMware use dynamically assigned disks that grow as you use them and you need more space. However, it is preferable to allocate a fixed space from the beginning, you will have higher performance and less fragmentation. It is the best option unless your disk space is critical and you have no choice but to use dynamic storage.
3. Choose the fastest storage drive
Many users tend to install and run virtual machines on a higher capacity secondary storage unit, which is usually a hard drive. If you can, make room for your SSD and use it instead, because the performance improvement will be brutal. For the same reason, avoid using external drives that – generally – will slow down the execution of virtual machines, unless you have fast media with Thunderbolt / USB 3.1 interfaces.
4. Install additional software tools
After installing a guest operating system on a virtual machine, you must install any additional software packages that the VM application you are using provides for them. VirtualBox, VMware or Parallels offer special tools and / or drivers that help each system work better on the particular hardware of your machine.
5. Allocate more RAM
Virtual machines are RAM eaters. Each virtual machine contains a complete operating system, so you have to distribute the RAM memory of the computer in several separate systems. Microsoft recommends at least 2GB of RAM for Windows 7/10 systems and the same can be said for current GNU / Linux distributions. That is the recommended minimum, but if you have enough hardware you will have to allocate a greater amount.
6. Allocate more CPU cores
In virtual machines the processor does matter, and a lot. In fact, it does most of the work. If you have a multicore processor, assign as many as you can afford. As with RAM, everything will depend on the number of virtual machines you start simultaneously and the system to be virtualized. Try several options until you balance and do not slow down your main system.
7. Adjust video settings
Adjusting the video settings can also improve the performance of your virtual machine and in addition to managing screen resolution as we would in the main system, we must make sure that we have 2D and 3D acceleration enabled. We can also manage the amount of dedicated video memory.
8. Exclude directories in the antivirus
Your computer’s security solution may be scanning the virtual machine files every time they are accessed, reducing performance. The antivirus cannot see inside the virtual machine to detect viruses that run in the guest operating system, so this scan is useless. To speed things up, add the virtual machine directory to your antivirus’s exclusion list.
9. Suspend instead of shutdown
When you’re done using the virtual machine, you may want to save its state rather than shutting it down completely. The next time you need it, just double click to start it up. The guest operating system will pick up where it left off instead of booting from scratch. The function is similar to hibernation or sleep. The application saves the contents of the virtual machine’s memory in a file on the hard disk, to be loaded when required by the user.
10. For virtual machines, upgrade your hardware
Everything said above is a help to improve the performance of our virtual machines, but there are no miracles when using this technological resource. Here the saying of the more the better is valid. As you have seen, for them to work properly we have to give them resources from our main machine. And not a few. If your hardware is not powerful enough and you use them, you can completely block your computer as soon as you run a system that requires a certain level of power, although the resource consumption of, for example, Windows 10 or DOS is totally different.
Don’t be scared and try. The use of virtual machines is a very valuable technological resource at business levels, but we can also take advantage of it as users. If you need help getting started, you can review a “step-by-step” case study of installing Windows 10 virtualized with VMware on a Windows 7 machine.