Xen
Xen[ARM Cortex-A15 MPCore|] is a type-1 hypervisor, providing services that allow multiple computer operating systems to execute on the same computer hardware concurrently. It was
originally developed by the University of Cambridge Computer Laboratory and is now being developed by the Linux Foundation with support from Intel.
The Xen Project community develops and maintains Xen Project as free and open-source software, subject to the requirements of the GNU General Public License, version 2. Xen Project is currently available for the IA-32, x86-64 and ARM instruction sets.
Software architecture
Xen Project runs in a more privileged CPU state than any other software on the machine.Responsibilities of the hypervisor include memory management and CPU scheduling of all virtual machines, and for launching the most privileged domain - the only virtual machine which by default has direct access to hardware. From the dom0 the hypervisor can be managed and unprivileged domains can be launched.
The dom0 domain is typically a version of Linux or BSD. User domains may either be traditional operating systems, such as Microsoft Windows under which privileged instructions are provided by hardware virtualization instructions, or paravirtualized operating systems whereby the operating system is aware that it is running inside a virtual machine, and so makes hypercalls directly, rather than issuing privileged instructions.
Xen Project boots from a bootloader such as GNU GRUB, and then usually loads a paravirtualized host operating system into the host domain.
History
Xen originated as a research project at the University of Cambridge led by Ian Pratt, a senior lecturer in the Computer Laboratory, and his PhD student Keir Fraser. The first public release of Xen was made in 2003, with v1.0 following in 2004. Soon after, Pratt and Fraser along with other Cambridge alumni including Simon Crosby and founding CEO Nick Gault created XenSource Inc. to turn Xen into a competitive enterprise product.The Open Source Xen Project continued to be supported by XenSource, then by Citrix following XenSource's acquisition in October 2007. This organization supports the development of the free software project and also sells enterprise versions of the software.
To support embedded systems such as smartphone/ IoT with relatively scarce hardware computing resources, the Secure Xen ARM architecture on an ARM CPU was exhibited at Xen Summit on April 17, 2007 held in IBM TJ Watson. The first public release of Secure Xen ARM source code was made at Xen Summit on June 24, 2008 by Sang-bum Suh, a Cambridge alumnus, in Samsung Electronics.
On October 22, 2007, Citrix Systems completed its acquisition of XenSource, and the Xen Project moved to the xen.org domain. This move had started some time previously, and made public the existence of the Xen Project Advisory Board, which had members from Citrix, IBM, Intel, Hewlett-Packard, Novell, Red Hat, Sun Microsystems and Oracle. The Xen Advisory Board advises the Xen Project leader and is responsible for the Xen trademark, which Citrix has freely licensed to all vendors and projects that implement the Xen hypervisor.
Citrix uses the Xen brand itself for some proprietary products unrelated to Xen, including XenApp and XenDesktop.
On April 15, 2013, it was announced that the Xen Project was moved under the auspices of the Linux Foundation as a Collaborative Project. The Linux Foundation launched a new trademark for "Xen Project" to differentiate the project from any commercial use of the older "Xen" trademark. A new community website was launched at xenproject.org as part of the transfer. Project members at the time of the announcement included: Amazon, AMD, Bromium, CA Technologies, Calxeda, Cisco, Citrix, Google, Intel, Oracle, Samsung, and Verizon. The Xen project itself is self-governing.
Release history for Xen Project (upstream project)
Xen in Linux distributions and Linux upstream
Since version 3.0 of the Linux kernel, Xen support for dom0 and domU exists in the mainline kernel.Uses
companies use hypervisors to provide virtual private servers. Amazon EC2, IBM SoftLayer, Liquid Web, Fujitsu Global Cloud Platform, Linode, OrionVM and Rackspace Cloud use Xen as the primary VM hypervisor for their product offerings.Virtual machine monitors also often operate on mainframes and large servers running IBM, HP, and other systems.
Server virtualization can provide benefits such as:
- consolidation leading to increased utilization
- rapid provisioning
- dynamic fault tolerance against software failures
- hardware fault tolerance
- the ability to securely separate virtual operating systems
- the ability to support legacy software as well as new OS instances on the same computer
Virtualization also has benefits when working on development : running the new system as a guest avoids the need to reboot the physical computer whenever a bug occurs. Sandboxed guest systems can also help in computer-security research, allowing study of the effects of some virus or worm without the possibility of compromising the host system.
Finally, hardware appliance vendors may decide to ship their appliance running several guest systems, so as to be able to execute various pieces of software that require different operating systems.
Technology
Types of virtualization
Xen offers five approaches to running the guest operating system:- HVM
- HVM with PV drivers
- PVHVM
- PVH
- PV.
Paravirtualization – modified guests
Through paravirtualization, Xen can achieve high performance even on its host architecture which has a reputation for non-cooperation with traditional virtualization techniques.
Xen can run paravirtualized guests even on CPUs without any explicit support for virtualization.
Paravirtualization avoids the need to emulate a full set of hardware and firmware services, which makes a PV system simpler to manage and reduces the attack surface exposed to potentially malicious guests.
On 32-bit x86, the Xen host kernel code runs in Ring 0, while the hosted domains run in Ring 1 and Ring 3.
Hardware-assisted virtualization, allowing for unmodified guests
CPUs that support virtualization make it possible to run unmodified guests, including proprietary operating systems. This is known as hardware-assisted virtualization, however, in Xen this is known as hardware virtual machine.HVM extensions provide additional execution modes, with an explicit distinction between the most-privileged modes used by the hypervisor with access to the real hardware and the less-privileged modes used by guest kernels and applications with "hardware" accesses under complete control of the hypervisor.
Both Intel and AMD have contributed modifications to Xen to exploit their respective Intel VT-x and AMD-V architecture extensions. Use of ARM v7A and v8A virtualization extensions came with Xen 4.3.
HVM extensions also often offer new instructions to allow direct calls by a paravirtualized guest/driver into the hypervisor, typically used for I/O or other operations needing high performance. These allow HVM guests with suitable minor modifications to gain many of the performance benefits of paravirtualized I/O.
In current versions of Xen only fully virtualized HVM guests can make use of hardware facilities for multiple independent levels of memory protection and paging. As a result, for some workloads, HVM guests with PV drivers provide better performance than pure PV guests.
Xen HVM has device emulation based on the QEMU project to provide I/O virtualization to the virtual machines. The system emulates hardware via a patched QEMU "device manager" daemon running as a backend in dom0. This means that the virtualized machines see an emulated version of a fairly basic PC. In a performance-critical environment, PV-on-HVM disk and network drivers are used during the normal guest operation, so that the emulated PC hardware is mostly used for booting.
Virtual machine migration
Administrators can "live migrate" Xen virtual machines between physical hosts across a LAN without loss of availability. During this procedure, the LAN iteratively copies the memory of the virtual machine to the destination without stopping its execution. The process requires a stoppage of around 60–300 ms to perform final synchronization before the virtual machine begins executing at its final destination, providing an illusion of seamless migration. Similar technology can serve to suspend running virtual machines to disk, "freezing" their running state for resumption at a later date.Target processors
The Xen hypervisor has been ported to a number of processor families.- Intel: IA-32, IA-64, x86-64
- PowerPC: previously supported under the XenPPC project, no longer active after Xen 3.2
- ARM: previously supported under the XenARM project for older versions of ARM without virtualization extensions, such as the Cortex-A9. Currently supported since Xen 4.3 for newer versions of the ARM with virtualization extensions, such as the
- MIPS: XLP832 experimental port
Scalability
Hosts
Xen can be shipped in a dedicated virtualization platform, such as Citrix Hypervisor.Alternatively, Xen is distributed as an optional configuration of many standard operating systems. Xen is available for and distributed with:
- Alpine Linux offers a minimal dom0 system that can be run from removable media, like USB sticks.
- Arch Linux provides the necessary packages with detailed setup instructions on their Wiki.
- Debian GNU/Linux and many of its derivatives;
- FreeBSD 11 includes experimental host support.
- Gentoo has the necessary packages available to support Xen, along with instructions on their Wiki.
- Mageia ;
- NetBSD can function as domU and dom0.
- OpenSolaris-based distributions can function as dom0 and domU from Nevada build 75 onwards.
- openSUSE 10.x to 12.x: only 64-bit hosts are supported since 12.1;
- Qubes OS uses Xen to isolate applications for a more secure desktop.
- SUSE Linux Enterprise Server ;
- Solaris ;
- Ubuntu
Guests
Unix-like systems as guests
Guest systems can run fully virtualized, paravirtualized, or fully virtualized with paravirtualized drivers. Most operating systems which can run on PCs can run as a Xen HVM guest. The following systems can operate as paravirtualized Xen guests:- Linux
- FreeBSD in 32-bit, or 64-bit through PVHVM;
- OpenBSD, through PVHVM;
- NetBSD
- MINIX
- GNU/Hurd
- Plan 9 from Bell Labs
Microsoft Windows systems as guests
Xen version 3.0 introduced the capability to run Microsoft Windows as a guest operating system unmodified if the host machine's processor supports hardware virtualization provided by Intel VT-x or AMD-V.During the development of Xen 1.x, Microsoft Research, along with the University of Cambridge Operating System group, developed a port of Windows XP to Xen — made possible by Microsoft's Academic Licensing Program. The terms of this license do not allow the publication of this port, although documentation of the experience appears in the original Xen SOSP paper.
James Harper and the Xen open-source community have started developing GPL'd paravirtualization drivers for Windows. These provide front-end drivers for the Xen block and network devices and allow much higher disk and network performance for Windows systems running in HVM mode. Without these drivers all disk and network traffic has to be processed through QEMU-DM. Subsequently, Citrix has released under a BSD license PV drivers for Windows.
Xen Management Consoles
Third-party developers have built a number of tools to facilitate the common tasks of administering a Xen host, such as configuring, starting, monitoring and stopping of Xen guests. Examples include:- Web-based HyperVM
- Web-based ConVirt
- the OpenNebula cloud management toolkit
- On openSUSE YaST and virt-man offer graphical VM management
- Web-based
- OpenStack natively supports Xen as a Hypervisor/Compute target
- CloudStack also supports Xen as a Hypervisor
- Novell's PlateSpin Orchestrate also manages Xen virtual machines for Xen shipping in SUSE Linux Enterprise Server.
- XEN-SHELL2 a lightweight console-based multi-user Xen VM management
Commercial versions
- Citrix XenServer
- Huawei FusionSphere
- Oracle VM Server for x86
- Thinsy Corporation
- Virtual Iron
- Crucible by Star Lab Corp.
Overview of Xen Projects releases in commercial distributions
Commercial distribution version | Release date of commercial version | Xen Projects version | Commercial release EOL date |
Citrix XenServer 6.0 | 2011-09-30 | 4.1.1 | 2016-09-26 |
Citrix XenServer 6.1 | 2012-09-28 | 4.1.3 | 2016-09-30 |
Citrix XenServer 6.2 | 2013-06-18 | 4.1.5 | 2018-06-26 |
Citrix XenServer 6.2 SP1 | 2013-12-16 | 4.1.5 | 2018-06-26 |
Citrix XenServer 6.5 | 2015-01-13 | 4.4.1 | 2018-06-26 |
Citrix XenServer 6.5 SP1 | 2015-05-12 | 4.4.1 | 2018-06-26 |
Citrix XenServer 7.0 | 2016-05-24 | 4.6.1 | 2021-05-19 |
Citrix XenServer 7.1 | 2017-02-23 | 4.7.1 | 2022-08-01 |
Citrix XenServer 7.4 | 2018-02-27 | 4.7.4 | 2018-09-30 |
Citrix XenServer 7.5 | 2018-05-30 | 4.7.x | 2019-04-20 |
Citrix XenServer 7.6 | 2018-09-06 | 4.7.6 | 2019-07-06 |