News: 1653999314

  ARM Give a man a fire and he's warm for a day, but set fire to him and he's warm for the rest of his life (Terry Pratchett, Jingo)

Distrobox 1.3.0: Run (pretty much) any Linux distro under almost any other

(2022/05/31)


Developer Luca di Maio has released version 1.3.0 of DistroBox, a tool to simplify running different versions of Linux in containers.

[1]Distrobox is likely to be one of those tools that sounds either great or totally mystifying, depending on the sort of Linux user you are. If you routinely have to work with multiple different distros, you may be in the former group, and DistroBox could save you a fair amount of time and effort.

The tool is intended to simplify the creation and use of Linux system containers, making it easy to run one distro on top of another without the overhead of virtual machines. If you actively want virtual machines, or you're more used to them, you might know [2]Vagrant .

[3]

In case you don't, Vagrant is a handy tool to automate away some of the tedious software configuration management (SCM) of working with VMs.

[4]

[5]

It's a wrapper around your choice of hypervisor and SCM tools (primarily Puppet and Chef).

With a single command, Vagrant will create a new VM, install the OS of your choice in it and configure it. Then with another command, you can make an SSH connection into the new VM.

[6]

Distrobox does something similar to this, but using containers. So it's smaller, simpler, and much lighter-weight, but by [7]the definition of OS-level virtualization , it can only support running Linux environments on a Linux host.

Even if you don't work with this stuff, you're doubtless well aware that there are lots of Linux distros out there, and many of them are profoundly different from one another. If you develop or manage software that runs on Linux, you have to allow for these differences, which means a lot of testing and switching boxes and distros.

Distrobox is intended to simplify this and make some of the pain go away. It's a wrapper around two of the most common Linux container runtimes, Docker and Podman.

[8]

It offers commands to create, enter, leave, and remove Linux system containers: that is, a complete OS except the kernel, running inside a container on your existing kernel. So each container has its own init system and all the core files which make one distro different from another.

[9]Windows Subsystem for Linux gets bleeding-edge Ubuntu

[10]Minimal, systemd-free Alpine Linux releases version 3.16

[11]Red Hat Kubernetes security report finds people are the problem

[12]Hardening in the enterprise: SUSE releases Rancher 2.6.5 and NeuVector 5.0

It wraps the container engine in a simple command line, with just six commands: create , enter , list , stop , rm , and version . So, for instance, if you're running Fedora, you could create an Ubuntu container and test apps just as if they were running on Ubuntu.

But it's more powerful than just that. If you're using an immutable distro such as [13]the Silverblue version of Fedora , you can add a conventional distro in a container, and then inside that you can install and run apps as normal, and they will run directly on your kernel. Or on a non-glibc distro such as [14]Alpine Linux , run an app that needs glibc, such as Google Chrome. Distrobox maps your home directory into its containers by default so all your normal files are available, and you can run graphical apps that use both X.org and Wayland.

[15]Youtube Video

Di Maio [16]describes Version 1.3.0 as "a quite big release." This seems reasonable as it's a relatively new tool – version [17]1.0.0 only came out at the start of December.

The project's website has installation [18]instructions . Older versions are already in some distros' repositories, or you can get the latest release from [19]GitHub . ®

Get our [20]Tech Resources



[1] https://distrobox.privatedns.org/

[2] https://www.vagrantup.com/

[3] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=2&c=2YpY7oa6Z2Oxe54A3-Y8zHAAAANM&t=ct%3Dns%26unitnum%3D2%26raptor%3Dcondor%26pos%3Dtop%26test%3D0

[4] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=4&c=44YpY7oa6Z2Oxe54A3-Y8zHAAAANM&t=ct%3Dns%26unitnum%3D4%26raptor%3Dfalcon%26pos%3Dmid%26test%3D0

[5] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=3&c=33YpY7oa6Z2Oxe54A3-Y8zHAAAANM&t=ct%3Dns%26unitnum%3D3%26raptor%3Deagle%26pos%3Dmid%26test%3D0

[6] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=4&c=44YpY7oa6Z2Oxe54A3-Y8zHAAAANM&t=ct%3Dns%26unitnum%3D4%26raptor%3Dfalcon%26pos%3Dmid%26test%3D0

[7] https://www.theregister.com/2011/07/18/brief_history_of_virtualisation_part_3

[8] https://pubads.g.doubleclick.net/gampad/jump?co=1&iu=/6978/reg_software/front&sz=300x50%7C300x100%7C300x250%7C300x251%7C300x252%7C300x600%7C300x601&tile=3&c=33YpY7oa6Z2Oxe54A3-Y8zHAAAANM&t=ct%3Dns%26unitnum%3D3%26raptor%3Deagle%26pos%3Dmid%26test%3D0

[9] https://www.theregister.com/2022/05/13/wsl_ubuntu_preview/

[10] https://www.theregister.com/2022/05/26/alpine_linux_316_released/

[11] https://www.theregister.com/2022/05/18/red_hat_kubernetes/

[12] https://www.theregister.com/2022/05/17/suse_rancher_neuvector/

[13] https://www.theregister.com/2022/05/12/fedora_36_released/

[14] https://www.theregister.com/2022/05/26/alpine_linux_316_released/

[15] https://www.youtube.com/embed/Q2PrISAOtbY

[16] https://github.com/89luca89/distrobox/releases/tag/1.3.0

[17] https://github.com/89luca89/distrobox/releases/tag/1.0.0

[18] https://distrobox.privatedns.org/#installation

[19] https://github.com/89luca89/distrobox/releases

[20] https://whitepapers.theregister.com/



Multiple distros

VoiceOfTruth

-> If you routinely have to work with multiple different distros

Consider changing the way you work, and use one. You will save yourself duplication of effort.

Re: Multiple distros

karlkarl

Agreed.

You don't even need to pick a "good" one. I still mainly use Red Hat Enterprise 6 because I find Mate to be less polished than the Gnome 2 of old, I prefer the old OpenOffice, I prefer the old Gimp, I prefer the old Blender, I basically prefer the older revisions of everything.

However, instead I set up a Debian chroot (via debootstrap) for more recent development tools and web browsers. It basically gets me off that treadmill of losing the bits I like and want to keep using for the sake of compatibility with upstream.

Re: Multiple distros

Gene Cash

I can see testing being a huge part of this... e.g. making sure your startup scripts work in SysV and that systemd crap, for example. Or hunting down "why does it work on everything except Ubuntu?"

Re: Multiple distros

VoiceOfTruth

Your points are valid, but they are also symptoms of the differences between distributions. Developing for Linux is 100 times worse than Java. Not "write once debug everywhere", but "write for every distribution you want to target and debug everywhere". It is a waste of time.

telnet: Unable to connect to remote host: Connection refused