Virtualisation

What is Hypervisor?

Definition

A hypervisor is the software layer that creates and runs virtual machines, allocating physical CPU, memory and IO between them. A type-1 hypervisor runs directly on the hardware; KVM is unusual in being a type-1 hypervisor implemented as a Linux kernel module, which lets it use the whole Linux driver ecosystem.

Why Hypervisor matters

A type-1 hypervisor runs directly on the hardware; KVM is unusual in being a type-1 hypervisor implemented as a Linux kernel module, which lets it use the whole Linux driver ecosystem.

Hypervisor in practice

When you're running a server on a KVM hypervisor, you look at the actual hardware allocation: vCPUs, RAM, disk I/O. You adjust these from the panel, often hot-adding extra memory without a reboot. Get it wrong by overcommitting the host, and your neighbours' noisy workloads starve your instance's CPU or IO, turning a perfectly configured guest into a sluggish one. Nested virtualisation means you can run a hypervisor inside your hypervisor, handy for testing, but it costs performance and can confuse your own resource counting.

What people get wrong about Hypervisor

The common error is treating the hypervisor as a container boundary. It isn't. A hypervisor gives you a full virtual machine, your own kernel, your own /proc, no shared namespace. People assume their neighbour's processes are invisible or their custom kernel is impossible, then hit limitations. The correction: with KVM, you get genuine isolation and control, so you can boot a hand-rolled image or run nested virtualisation, things a container can't do.

Hypervisor — common questions

What does type-1 hypervisor mean?

A type-1 hypervisor runs directly on the host hardware, not on top of an operating system. KVM is special because it's a type-1 hypervisor implemented as a Linux kernel module, so it can use the whole Linux driver ecosystem for managing hardware. That gives you the performance of bare-metal virtualisation with the flexibility of Linux.

How is KVM different from containers like OpenVZ?

KVM provides true virtualisation: each guest gets its own kernel, its own /proc, and no shared namespace, so you have full root access and can run custom kernels. Containers share the host kernel and namespaces, which limits what you can do. With KVM, you get isolation and control, including the ability to run nested virtualisation or boot a custom ISO.

More from virtualisation

KVM
KVM is full hardware virtualisation built into the Linux kernel, giving each guest its own kernel and hardware-enforced isolation from other tenants.
OpenVZ
OpenVZ is container-based virtualisation in which every instance shares the host kernel, so guests cannot load kernel modules or run a different operating system.
LXC
LXC is Linux-native containerisation that isolates processes with namespaces and cgroups while sharing the host kernel.
Nested virtualisation
Nested virtualisation lets a virtual machine itself run virtual machines, by exposing the processor virtualisation extensions to the guest.
vCPU
A vCPU is a virtual processor presented to a guest, backed by scheduling time on a physical core or thread.
cloud-init
cloud-init is the standard mechanism for configuring a virtual machine on first boot, using metadata supplied by the platform.