Unix & Linux
windows windows-subsystem-for-linux distribution-choice
Updated Thu, 29 Sep 2022 18:56:32 GMT

What is involved in a WSL "distribution"?


WSL allows the user to use any distribution of their choice, and Ubuntu is installed by default.

I don't really understand the relevance of the distribution in the WSL context. My understanding is that Linux distribution refers to the skin of the OS. A UI layer on top of the OS core. But when using WSL you just use the command line, or perhaps run an independant single gui application. So what is the relevance of distribution in this context, and what difference does it make which distribution you choose?




Solution

My understanding is that Linux distribution refers to the skin of the OS. A UI layer on top of the OS core.

That's not correct. Linux distributions differ in many fundamental ways which go beyond the look&feel of the GUI:

  • versions of the kernel, plus various customizations (Want the latest kernel and cutting-edge software? Use Fedora. Want stability? Use RHEL.)
  • support for different hardware devices
  • package managers (RHEL has rpm, yum, and dnf; Debian has dpkg and apt; ArchLinux has pacman; and so on)
  • software packages and tools (Debian, for instance, has only free and open source software in its main repo)
  • repositories, with different timelines for updates and bugfixes

However, if your main use is just writing some Bash script, your experience will be more or less the same regardless of the distro.





Comments (5)

  • +0 – This is very helpful. Is the Kernel one package, or a collection/composition of packages? — Aug 22, 2022 at 18:29  
  • +0 – @BenCarp It depends on the distribution, and what you consider the kernel. Firmware is usually in a separate package (even though on Windows that would be part of the drivers themselves), and some distributions have the kernel modules in a separate package from the kernel itself. — Aug 22, 2022 at 22:18  
  • +4 – "If your main use is just writing some bash script, your experience will be more or less the same" -- this assumes a relatively mainstream distribution, as opposed to something like NixOS (where /usr/bin has no file other than env, and /bin has no file other than sh) or GUIX. — Aug 22, 2022 at 23:06  
  • +0 – @CharlesDuffy Strongly agree - Even on WSL. I spent way too many hours last weekend trying to bootstrap GUIX on WSL as a hobby project (was partially, but not totally successful). I may take another look at it later, but I came away pretty convinced that GUIX's eschewing of the FHS makes running it on WSL a bit too challenging at this point. We can blame that on WSL, or GUIX, or just the combination of both, but they don't get along all that well. I'll probably look at NixOS on WSL (for my education) at some point as well, but I haven't yet. — Aug 23, 2022 at 04:10  
  • +0"Want the latest kernel and cutting-edge software? Use Fedora." -- Just realize that, on WSL, the kernel in Fedora is not applicable or used. — Aug 23, 2022 at 16:41