Xen Enters Mainline Kernel

Future versions of the Linux Kernel (such as 3.0) will include support for the Xen hypervisor. This means that Linux distributions will typically offer out of the box support for both hosting Xen and running as a guest operating system under Xen.

Xen requires operating system support from both the host and the guest. In other words, you need an operating system that has been modified in order to run Xen or to run under Xen. [Correction: Xen can run unmodified operating systems on a processor that supports x86 virtualisation, which to be fair, should include most modern desktop processors.] In the past, installing Xen (in most distributions) has been a more complicated procedure than for other virtualizers such as VirtualBox.

As it stands, the Linux Kernel offers support for KVM, a virtualization technology that can speed up the QEMU machine emulator. It is the hope of the Xen community that out of the box support for Xen will increase adoption. However, the degree to which built-in kernel support will raise the profile of Xen is debatable. The target of Xen has always been server admins who placed a higher premium on top-flight security and server specific features than they did on ease of use. Anyone who needs the features that distinguish Xen from other solutions would probably not have been dissuaded from using it by the difficult installation. Casual users, who need a simple installation via the package manager on distributions such as Ubuntu, would probably be better served by VirtualBox, QEMU or VMWare.

Who knows, perhaps someone will cook up a virtualization solution aimed at casual desktop users, but that uses Xen as its underlying technology? There might even be some scope for adding other features, such as application sandboxing, by making use of Xen.

The image that I used in this article, a picture of a zen garden, was taken from the Flicker account of CyboRoZ. I was able to use it here because it of the Creative Commons license that he released the work under.

Comments

Comment viewing options

Xen's management domain can be Linux, but it could also be BSD, Solaris, or any other operating system that wanted to add Xen support. (VirtualBox, QEMU, and VMware's workstation-class products are also type-2).

Indeed, NetBSD has had Xen (both Dom0 and DomU) support for a long time.

To clarify, Linux 3.0 does not contain the Xen hypervisor, but instead now has full Xen guest and management domain support in the mainline kernel. This clarification is because people already seem to misunderstand the kind of hypervisor that Xen is. It is a stand alone, pure type-1 hypervisor. It doesn't make sense to say that a type 1 hypervisor is included in Linux. Xen the hypversor is a small software layer that runs under traditional operating systems (such as Linux). The hypervisor is not included in Linux like KVM. KVM in contrast is an integrated hypervisor that is technically a type-2 hypervisor that relies on the fact that it runs on Linux. Xen's management domain can be Linux, but it could also be BSD, Solaris, or any other operating system that wanted to add Xen support. (VirtualBox, QEMU, and VMware's workstation-class products are also type-2)

Xen guest support has been in mainline Linux for a long time since 2.6.23 (IIRC). Also there is has been distro support for Xen since the very early days and there still is good distro support via SUSE/OpenSUSE, Debian, CentOS (5.x series which is still in common use), the Xen Cloud Platform (XCP), and other Linux distros.

As Ricardo commented above, Xen can also run unmodified guests, called HVM guests. Virtualization hardware support (e.g. VT-x, AMD-V) is required for these guest (just like KVM requires this support for all of it's guests).

Although it is true that traditionally Xen has had success for server environments, Xen is also being used for client-based solutions as well. For example, Citrix XenClient, Virtual Computer's NxTop, and (as Ricardo mentions) QubesOS.

Further, Xen has already added support for upstream QEMU, which means that using Xen for QEMU (HVM) guests would provide very similar user experiences. Plus, there is support to run paravirtualized (PV) on HVM drivers to improve performance on these HVM guests in Xen's case.

To say that Xen is not a good choice as compared to the other virtualization options on a desktop system is simply not true. It can be used just as well in place of the other virtualization solutions and there are likely use cases where Xen actually works better.