Virtualization Options in CentOS

Virtualization is a method that allows a system administrator to run one instance of an operating system (called a virtual machine) within another. Each virtual machine operates as though it were a standalone dedicated server of its own, but it is really depending on the resources of its host.

Many commercial vendors offer virtualization options for virtual private servers (VPS) and other virtualization techniques, but there are also several free and open source options, some of which come packaged with various Linux distributions. CentOS repositories includes two primary virtualization options, and you are, of course, free to choose others.

KVM – Kernel-based Virtual Machine is a virtualization system for the Linux kernel that supports numerous guest operating systems, including several Linux distributions, BSD variants, Windows, and a variety of Unix-like operating systems. KVM is designed for full hardware-assisted virtualization, although paravirtualization is in the works. Since it is a kernel module, it works with the standard, non-modified Linux kernel and creates virtual machines on the /dev/kvm device.

Xen – Xen supports both paravirtualization and hardware-assisted full virtualization, and both of these types can run at the same time. In order to work, Xen must boot its hypervisor even before CentOS boots. It then boots CentOS as the administrative domain, making it the main OS. Additional clients or unprivileged domains can then be added. Because of the nature of the hypervisor, a Xen virtualization system must run the CentOS Xen kernel rather than the standard kernel. Like KVM, Xen supports several Unix-like OSes, including Linux, BSD, and Solaris. The latest version also has Windows virtualization capabilities.

Both virtualization options have their advantages and their limitations. For more information, you can read the full CentOS / Red Hat Enterprise Linux virtualization manual online.