What Is a Virtual Machine (VM)? Virtual vs Physical Servers
A virtual machine is a computer created in software that runs its own operating system on a hypervisor. How it differs from physical servers and containers.

Short answer: A virtual machine (VM) is a software-created equivalent of a physical computer. It behaves as if it had its own CPU, memory, disk and operating system, but draws those resources from the physical server underneath through a layer called the hypervisor. A single physical server can run many virtual machines at once, isolated from one another. A virtual server is simply a virtual machine used as a server; VPS and cloud servers are commercial forms of the same technology.
What is a virtual machine?
The definition still in use dates back to 1974. In their paper in Communications of the ACM, Gerald Popek and Robert Goldberg defined a virtual machine as "an efficient, isolated duplicate of the real machine". They expected three things from the layer that runs virtual machines, which we now call the hypervisor: programs should behave essentially as they would on the real machine, slow down at worst only slightly, and that layer should be in complete control of system resources.
The idea is older still. IBM began the work with CP-40 at its Cambridge research center in 1964 and announced VM/370 on August 2, 1972. KVM, one of the building blocks of today's server virtualization, uses the hardware virtualization support in Intel and AMD processors and entered the kernel with Linux 2.6.20, released in February 2007.
How does a virtual machine work?
A software layer called the hypervisor runs on the physical server. The hypervisor pools CPU, memory, storage and network resources and allocates a share to each virtual machine. The operating system inside the virtual machine sees that share as its own hardware and does not know that other virtual machines run on the same hardware.
On disk, a virtual machine is a handful of files: a disk image holding the virtual disk (VMDK on VMware, VHDX on Hyper-V, usually qcow2 on KVM) and a configuration file holding settings such as CPU, memory and network card. That is why virtual machines are easy to copy, move and back up: the server has become a few files.
Hypervisor types: Type 1 and Type 2
Red Hat's classification distinguishes two kinds of hypervisor:
- Type 1 (bare metal): The hypervisor runs directly on the hardware, with no general-purpose operating system in between. This is the type used for server virtualization. Examples: VMware vSphere (ESXi), Microsoft Hyper-V and KVM. Proxmox VE brings KVM and Linux containers (LXC) together in an open-source management platform.
- Type 2 (hosted): The hypervisor runs as an application on an ordinary operating system such as Windows or Linux. It suits development and testing; examples are VMware Workstation and Oracle VirtualBox.
Which Type 1 hypervisor to use is a decision that comes back whenever a licensing model changes. That is what happened after Broadcom acquired VMware; we cover it in our VMware, Proxmox and KVM article.
Virtual server vs physical server
On a physical server a single operating system uses all of the hardware. With virtual servers the same hardware is shared among several virtual machines. The differences show up most clearly here:
- Provisioning time: A physical server needs a hardware order, mounting and cabling. A virtual server is created from a ready resource pool in minutes.
- Resource use: Idle capacity on a physical server is wasted. With virtualization the same hardware carries several workloads, so it is used more efficiently.
- Portability: A running virtual machine can be moved from one physical server to another (vMotion on VMware, Live Migration on Hyper-V), so hardware maintenance happens without stopping the workload.
- Snapshots: Before a change, the virtual machine's current state is saved; if the change goes wrong, you return to that point.
- Performance: The hypervisor layer has a cost, but hardware support in processors keeps it small. Microsoft describes Hyper-V as delivering "near-native performance".
- Isolation: Virtual machines run isolated from one another but share the same hardware and the same hypervisor. A flaw in the hypervisor can affect every virtual machine, so hypervisor patches should not be postponed.
A physical server is still the right choice in some cases. The main ones are large databases that need the whole machine, workloads that use special hardware such as GPUs on their own, and software whose licensing terms make virtualization expensive.
Virtual machine vs container
Containers also provide isolation, but at a different layer. As Docker puts it, a virtual machine is an abstraction of hardware: each one carries a full copy of an operating system and can take up tens of GBs. A container is an abstraction at the application layer: containers on the same machine share the operating system kernel, and their images are typically tens of MBs.
That is why containers are lighter and start faster; but because they share one kernel, their isolation is not as strong as a virtual machine's. Nor are the two alternatives to each other: in cloud providers' managed Kubernetes services, containers run on virtual machines that act as nodes.
VPS, VDS and cloud servers
The hosting industry sells virtual machines under different names:
- VPS (virtual private server): A virtual server with its own operating system, created by partitioning a physical server.
- VDS (virtual dedicated server): Runs on shared hardware, but its resources are allocated to a single customer.
- Cloud server: The virtual machine delivered on the cloud model. It is created from a resource pool in minutes, can be scaled up or down, and is paid for by use. More in our IaaS article.
What these names include varies from provider to provider. When comparing, look past the name to guaranteed resources, redundancy and the support model.
Backing up virtual machines: a snapshot is not a backup
A snapshot records a virtual machine's state at a given moment and is very useful as a return point before a change. But it is not a backup. VMware's own guidance is not to use snapshots as backups: a snapshot file is only a change log of the original virtual disk, and if the base disk is lost, the snapshot alone cannot bring the virtual machine back.
The right method for virtual machines is image-based backup, which copies the virtual machine's image to separate storage, plus replication to another site for critical workloads. We explain how to design backups in our backup article.
Frequently asked questions
What does VM mean? VM stands for virtual machine: a software-created equivalent of a physical computer, running its own operating system.
What is a virtual machine used for? For running several systems isolated from one another on one physical server. Consolidating servers onto less hardware, development and testing, running legacy applications on new hardware, and disaster recovery are the main uses.
Is a virtual server the same as a VPS? Technically yes: both are virtual machines. VPS is the name hosting providers use when they sell a virtual server.
How many virtual machines can run on one physical server? There is no fixed number. It depends on the CPU, memory and disk needs of the virtual machines and on how the hypervisor shares resources. Allocating more than the physical capacity (overcommit) is possible, but when load rises every virtual machine slows down.
Are virtual machines secure? Virtual machines run isolated from one another. Still, because they all depend on the same hypervisor, the hypervisor must be kept up to date and access to its management interface restricted.
Virtual machine or container? If you need a full operating system, different operating systems or strong isolation, a virtual machine is the right choice. If you need to start and stop many copies of the same application quickly, a container fits better. The two can also be used together: containers can run on virtual machines.
Sources
- Popek and Goldberg, Formal Requirements for Virtualizable Third Generation Architectures: definition of a virtual machine (Communications of the ACM, July 1974)
- IBM, VM History Timeline: CP-40, CP-67 and the announcement of VM/370 (August 2, 1972)
- Kernel Newbies, Linux 2.6.20: KVM enters the Linux kernel (February 5, 2007)
- Red Hat, What is a hypervisor?: Type 1 and Type 2 hypervisors
- Microsoft, Hyper-V overview: Hyper-V as a Type 1 hypervisor
- Proxmox, Proxmox Virtual Environment: open-source platform combining KVM and LXC
- Docker, What is a container?: containers vs virtual machines
- Broadcom KB 318825, Best practices for using VMware snapshots: why snapshots should not replace backups
- How we run this layer: virtualization platforms