What are the differences between KVM, Virtuozzo and OpenVZ?

These virtualization platforms are related, but they vary in terms of whether they're open source or commercial products and the types of instances they provide to run applications.

Virtualization platforms can vary significantly from one to the next, even if based on common components and technologies. KVM, Virtuozzo and OpenVZ are three such platforms. Although each one offers a unique approach to virtualization, they're all related, which can be confusing to those unfamiliar with the platforms.

Open source KVM hypervisor hosts multiple VMs

Kernel-based Virtual Machine is a highly implemented, open source virtualization technology built into the Linux kernel, which turns Linux into a hypervisor that can host multiple VMs. A guest OS runs in each VM and enables the VM to operate as a physical machine. KVM supports a number of guest OSes, such as Linux, Solaris, BSD, Windows and macOS. Virtualization administrators can run any combination of the guest OSes on the same physical server, which helps better use physical resources and provides flexibility.

KVM implements each VM as a regular Linux process that's managed by the Linux kernel. The system configures the VM with dedicated virtual resources -- such as CPUs, memory, adapters and drives -- and the VM can use any storage that Linux supports, including direct-attached and network-attached. KVM also offers live migrations, making it possible to move a running VM between physical Linux hosts without interrupting services.

To implement the KVM module, the host computer must run Linux 2.6.20 or later and support hardware virtualization. KVM inherits the Linux memory management features from the kernel and uses Security-Enhanced Linux, as well as secure virtualization, to isolate and secure the VM workloads.

There's some confusion around whether KVM is a type 1 or type 2 hypervisor. A type 1 hypervisor runs directly on the system hardware, and a type 2 hypervisor runs on the host OS like any other application. KVM doesn't fit neatly into either category because of how the KVM module converts the Linux OS into a hypervisor platform. However, because KVM operates at the kernel level, it delivers the same performance benefits as a hardware-based hypervisor, regardless of how it's labeled.

Virtuozzo provides VM and container instances

Similar to KVM, the Virtuozzo platform provides a hypervisor for hosting multiple VMs, each running its own OS and configured with its own virtual resources. But Virtuozzo adds something else: an OS layer that runs containerized applications, independent of the hypervisor or its VMs.

The Virtuozzo hypervisor provides a hardware-based virtualization layer that's loaded directly on bare metal, serving as an interface between the server hardware and VMs.

The Virtuozzo hypervisor provides a hardware-based virtualization layer that's loaded directly on bare metal, serving as an interface between the server hardware and VMs. Each VM is an independent environment with its own set of virtual resources, which admins can easily configure to accommodate different application workloads.

The Virtuozzo hypervisor is similar to KVM in most respects. The Virtuozzo hypervisor is built on top of KVM -- using the same core technologies to support virtualized workloads -- which makes the Virtuozzo hypervisor 100% upstream-compatible with KVM. Virtuozzo adds over 200 enhancements to the KVM core, leading to better performance and availability, while providing built-in backups.

Virtuozzo also offers an OS virtualization layer for running containers. The containers are fully isolated from each other, making them appear just like physical servers. Containers are easier to deploy and maintain than VMs as they better utilize physical resources, making it possible to support more containers per host compared to VMs. One drawback is that containers are limited to the same OS as the host system, which means they can run only Linux-based applications.

OpenVZ offers container-based virtualization

OpenVZ is an open source software that adds container-based virtualization to Linux. OpenVZ provides an OS-level virtualization technology that lets admins implement multiple Linux containers running in isolation from each other, without the VM overhead. Each container operates as a stand-alone server, supporting its own users, IP addresses, processes, applications and files. At the same time, the containers share the same underlying kernel, providing better resource utilization.

If OpenVZ sounds similar to Virtuozzo containerization, that's because it is. Virtuozzo uses OpenVZ's core technology in its own platform, enhancing the technology in a number of ways, just as it does with KVM. For example, Virtuozzo supports container backups, software-defined storage, additional memory policies and a new installer.

Because Virtuozzo and OpenVZ share a common foundation, they both include the same core features, such as kernel and command-line management tools. They also divide components into dedicated resources and burst resources. Dedicated resources are those guaranteed to the container whenever the container demands them. Burst resources are those available from unused capacity, which a container can borrow from other containers if they're not being used.

Although this can provide containers with the resources they require in the short term, the ability to burst resources can lead to a situation in which service providers oversell their platforms to accommodate as many containers as possible on a single host, leading to degraded performance and unstable applications. Hypervisor platforms such as KVM are also susceptible to overselling, but their underlying architecture helps prevent this from happening. OpenVZ's inherent design makes it much easier to oversell containers, something to watch for when shopping for container services.

Dig Deeper on IT systems management and monitoring

Software Quality
App Architecture
Cloud Computing
Data Center