A virtual machine (VM) is a software-based en­vir­on­ment that emulates a complete computer in the context of vir­tu­al­isa­tion. It allows multiple operating systems to run con­cur­rently on a physical host. We explain the func­tion­al­ity, benefits, and setup of VMs on Windows 11.

Cloud Migration with IONOS
The Hy­per­visor al­tern­at­ive
  • Great price-to-per­form­ance ratio with no vir­tu­al­isa­tion costs
  • Migration as­sist­ance from IONOS Cloud experts included
  • No vendor lock-in & open source based

What is a virtual machine?

A VM is a virtual computer with its own operating system, accessing the resources of a host system. The guest system behaves like an in­de­pend­ent PC with RAM, storage, and a file system. The found­a­tion is the hy­per­visor, which runs as an ap­plic­a­tion in the host system or directly on the hardware. It manages resource al­loc­a­tion and separates VMs from one another—a concept known as en­cap­su­la­tion.

Image: Image: Hypervisor-based hardware virtualisation
Schematic rep­res­ent­a­tion of hy­per­visor-based hardware vir­tu­al­isa­tion

Many hy­per­visors also offer emulation features. This allows runtime en­vir­on­ments for different operating systems to be used on in­com­pat­ible hardware.

Virtual machines in practical use

With hardware vir­tu­al­isa­tion, you allocate the resources of a physical system to multiple virtual machines. Each VM operates in­de­pend­ently from the host and other VMs—an advantage for security, stability, and flex­ib­il­ity.

Typical ap­plic­a­tion areas are

  • Shared hosting,
  • VPS solutions and
  • Server con­sol­id­a­tion.

Busi­nesses con­sol­id­ate ap­plic­a­tions like mail, file, or database servers on shared hardware with virtual machines. This saves costs and prevents unused computing power. VMs are also used in software de­vel­op­ment, for example, testing across different systems. VMs can be quickly created, cloned, and com­pletely deleted without traces.

Emulation also allows sim­u­lat­ing non-native software systems, such as running Linux on Windows. This creates an overhead since ad­di­tion­al resources are needed for the hy­per­visor and the guest system. Per­form­ance loss is a concern, es­pe­cially with resource-intensive ap­plic­a­tions. Assign clear hardware limits to virtual machines and ensure that the total load does not exceed the host’s capacity.

An overview of the ad­vant­ages and dis­ad­vant­ages of virtual machines

Below, we outline the main ad­vant­ages and dis­ad­vant­ages of virtual machines. The impact of these pros and cons primarily depends on how you want to deploy VMs and what purpose you aim to achieve with vir­tu­al­isa­tion.

Ad­vant­ages of virtual machines:

  • Multiple operating systems can be used sim­ul­tan­eously on a single hardware
  • Better util­isa­tion through server con­sol­id­a­tion
  • Isolation increases security and stability
  • Cent­ral­ised main­ten­ance saves time and costs
  • Flexible de­ploy­ment and easy migration

Dis­ad­vant­ages of virtual machines:

  • Per­form­ance loss due to hy­per­visor overhead
  • Bot­tle­necks during high util­isa­tion on shared systems
  • Hy­per­visor can be a vul­ner­ab­il­ity for attacks
  • Licensing issues with virtual operating systems often unclear

How to create a virtual machine tutorial

Below, we show you with a step-by-step guide how to create a virtual machine on a Windows host and run Ubuntu Linux as a guest system. For the tutorial, we use Windows 11. Oracle VM Vir­tu­al­Box is used as hy­per­visor software.

Note

To follow the guide on your own system, you just need a Windows PC with internet access. The software used in the tutorial is available for free download from the internet.

Step 1: Choose hy­per­visor software

To provide virtual operating systems, various software solutions are available. Leading products are from companies like Oracle, VMware, and Parallels.

The following table shows the most popular hy­per­visor products for Windows, Linux, and macOS, as well as possible guest systems.

Vir­tu­al­isa­tion software Host systems Guest systems
Oracle VM Vir­tu­al­Box
  • Windows
  • Linux
  • Mac OS X
  • macOS
  • Solaris
  • Windows
  • Linux
  • Solaris
  • FreeBSD
VMware Work­sta­tion Player
  • Windows
  • Linux
  • Windows
  • Linux
  • NetWare
  • Solaris
  • FreeBSD
VMware Fusion
  • Mac OS X
  • macOS
  • Windows
  • Linux
  • NetWare
  • Solaris
  • FreeBSD
  • macOS
  • Mac OS X
Parallels Desktop for Mac
  • Mac OS X
  • macOS
  • Windows
  • Linux
  • macOS
  • Mac OS X
  • Solaris
  • FreeBSD
  • Android OS
  • Chrome OS

For the following tutorial, we used the hy­per­visor VM Vir­tu­al­Box from Oracle. The software is available to users for free under the GNU General Public License (GNU GPLv2). We recommend down­load­ing it from the provider’s website. Proceed as follows:

  1. Visit the page Oracle Download Page.

  2. Select the current download package for your operating system (in our case, Windows).

  3. Save the .exe file with the binary data in any directory on your computer.

Note

As a com­ple­ment to the core software, Oracle provides the Oracle VM Vir­tu­al­Box Extension Pack, a pro­pri­et­ary extension module for the open-source vir­tu­al­isa­tion software, free of charge. However, you do not need the Extension Pack for this tutorial.

Step 2: Install Oracle VM Vir­tu­al­Box

Once the download is complete, execute the binary package by double-clicking the .exe file. Follow the in­struc­tions of the in­stall­a­tion wizard to install Oracle VM Vir­tu­al­Box locally on your system.

At the end of the in­stall­a­tion process, the software launches the Oracle VM Vir­tu­al­Box Manager. Here, you create and manage your virtual machines.

Image: Oracle VirtualBox Manager start screen
Start screen of the Oracle Vir­tu­al­Box Manager. The empty field on the left side indicates that no virtual machines have been created yet.

Step 3: Download operating system image

To run a guest system in a virtual machine, you need an operating system image. This is a memory image that the hy­per­visor software can interpret as a system hard disk. Such images can be in the open file format .iso. Common vir­tu­al­isa­tion solutions also work with pro­pri­et­ary container formats for image files, such as .vmdk (VMware), .vhd (Xen and Microsoft Hyper-V), and .vdi (Oracle VM Vir­tu­al­Box).

For this tutorial, we use the open-source operating system Ubuntu 24.04, which can be down­loaded as an .iso file from the official Ubuntu project website. Proceed as follows:

  1. Go to the Ubuntu download page.

  2. Select the current version of the operating system and click ‘Download’

  3. Save the .iso file locally on your system.

Tip

If you want to run a virtual Windows PC as a guest system, you can find various image files for Hy­per­visor solutions from VMware, Hyper-V, Vir­tu­al­Box, and Parallels on the official Microsoft Developer Website.

Step 4: Create a new virtual machine

Use the ‘New’ button to add a new virtual machine to the Oracle VM Vir­tu­al­Box Manager. Enter a name for the new virtual machine (spaces are not allowed) and specify the location of the pre­vi­ously down­loaded ISO file. Ensure that the entries in the ‘Type’, ‘Subtype’, and ‘Version’ fields match the guest system to be installed.

Image: Oracle VirtualBox Manager: Selecting the operating system
We’ve chosen the operating system type Linux, the subsystem Ubuntu, and the version Ubuntu (64-bit).

Also, tick the box ‘Skip Un­at­ten­ded In­stall­a­tion’ if you want to use the usual Ubuntu in­stall­a­tion wizard after starting the VM. Otherwise, Vir­tu­al­Box will perform an automatic in­stall­a­tion of the operating system, and you won’t be able to set options like system language and keyboard layout yourself.

Note

If you prefer the ‘Un­at­ten­ded Install’ option, you must create a user account in the menu of the same name to log in to the virtual machine and complete the in­stall­a­tion of the VM!

Step 5: Assign hardware resources

Open the next category named ‘Hardware’. Here you can assign a portion of the memory and processor power provided by the host system to the new virtual machine. For Ubuntu 24.04, it is re­com­men­ded to reserve at least 4 GB of memory and 2 CPUs.

Image: Oracle VirtualBox Manager: Hardware allocation
Enable the option ‘Enable EFI’ if you want to emulate UEFI firmware instead of the classic BIOS.

Step 6: Create virtual hard disk

In the next step, decide whether to create a new virtual hard disk or assign an existing virtual hard disk to the virtual machine. In this tutorial, we will create a new virtual hard disk with a capacity of 25 gigabytes, where we will proceed to install the guest system from scratch.

To do this, select the option ‘Create a Virtual Hard Disk Now’, specify the desired storage location, and set the desired storage size with the slider. We will keep the default format VDI as the file type. If you tick ‘Pre-allocate Full Size’, the virtual hard disk will be created with the maximum required size from the start, instead of growing dy­nam­ic­ally. This can improve per­form­ance since the VM won’t con­stantly have to search for free storage resources later. However, enabling this option is not mandatory.

Image: Oracle VirtualBox Manager: Create Virtual Hard Disk
Create virtual hard disk in Oracle Vir­tu­al­Box Manager

Step 7: Complete creation process and start VM

Once you have con­figured the desired setup, click on ‘Finish’ to set up the virtual machine. The newly created VM will then appear with the name you have chosen in the list of available virtual machines.

Image: Oracle VirtualBox Manager with selectable VM
For each virtual machine, VM Vir­tu­al­Box creates a file folder that contains, along with the VDI file for the virtual hard disk, a log file and a defin­i­tion of the VM.

Once you click the ‘Start’ button in the ribbon, the virtual machine opens in a new window, and Vir­tu­al­Box boots the operating system stored in the ISO file. Since we chose to install Ubuntu from scratch, the virtual machine’s window shows the in­stall­a­tion manager’s startup screen.

Note

All changes you make in your VM are auto­mat­ic­ally written to the VDI file you created as the virtual hard drive during con­fig­ur­a­tion. If you want to run the guest system on another computer, simply copy your virtual machine‘s file folder (including the VDI file, log file, and defin­i­tion) to the cor­res­pond­ing device.

Go to Main Menu