20

The Linux README states that:

Linux has also been ported to itself. You can now run the kernel as a userspace application - this is called UserMode Linux (UML).

Why would someone want to do this?

1

4 Answers 4

24

UML is very fast for development and much easier to debug. If for example you use KVM then you need to setup an environment that boots from network or be copying new kernels in the VM. With UML you just run the new kernel.

At one point I was testing some networking code on the kernel. This means that you get very very frequent kernel panics or other issues. Debugging this with UML is very easy.

Additionally, UML runs in places where there's no hardware assisted virtualization, so it was used even more before KVM became commonality.

2
  • IIRC linode.com used to use UML for virtualisation.
    – Paul Cager
    Commented May 4, 2014 at 19:51
  • 3
    @PaulCager Yes, they did, from 2003 until switching to Xen in 2008. Commented May 4, 2014 at 22:14
13

Their web page has several reasons

Here are some of the things that UML is used for:

  • Hosting of virtual servers
  • Kernel development
  • Experimenting with new kernels and distributions
  • Education
  • Sandbox
1
4

UML was also the basis of the original version of the FAUmachine, which is a virtual machine that allows you to inject "hardware" faults into a running kernel.

1
  • Sounds interesting, but the url you provided is a broken link.
    – blee
    Commented May 28, 2014 at 12:43
2

Some containerization methods like Docker don't permit you to use, e.g. FUSE without running a privileged container, breaking down some of the security boundaries containers can offer. Sticking something like UML between your app and the containerization platform can give you access to more kernel features without compromising host security.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .