LinuxVirtBr:

Some virtualization technologies (eg. Xen and L4Linux) are hypervisor based, while others (eg. KVM) use Linux as the basis for the virtualized platform. Before answering the obvious question - Which is better, hypervisor based or Linux based? - here is a short explanation of the difference.

How things works

In a normal - not virtualized - GNU/Linux system the Linux kernel controls the hardware and all the processes running on the system.

In Linux based virtualization, virtual machines are managed in a way similar to normal processes in the system. If desired, the Linux kernel can be modified to treat the virtual machines a little different from normal processes, for example giving them a different scheduling priority or keeping the virtual machines locked in memory, but basically they can be regarded as having some similarity to processes.

Hypervisor based systems, like Xen, do not have Linux in full control of the hardware. Instead, a smaller piece of software, the hypervisor, controls certain things in the system:

In the case of Xen, typically one of the virtual machines takes care of the other hardware bits, like device drivers for disk, network, video card, etc. The other virtual machines communicate with that first privileged virtual machine (domain 0) to manipulate their virtual devices. A hypervisor can be seen as a form of microkernel.

There are a number of advantages and disadvantages to each approach.

Hypervisor advantages

Linux based advantages

So, which is better?

Which approach is better depends entirely on what your goals are. For a Linux kernel maintainer (hi Linus) it is much easier if the software is small, simple and entirely inside the kernel. Interfaces to an external hypervisor mean an extra interdependency with another project.

For end users the functionality will probably be more important than what the underlying technology is. As long as the virtualization technology in question is efficient, easily manageable and available on the system by default it will do the job. End users will be interested in the Linux virtualization technology comparison table.

In the end, chances are that whatever technology makes it into the upstream (kernel.org) kernel and fulfills all of a user's technical needs will be the one that gets used. Practical availability trumps theoretical advantages every time.

LinuxVirtBr: HypervisorVsLinuxBased (last edited 2017-12-30 06:21:12 by localhost)