Microsoft added systemd for more compatible applications

Two major companies, Microsoft and Canonical, have teamed up to add systemd to the , allowing a greater number of compatible applications to be installed.

Microsoft: we made a mistake about open source

systemd is a Linux software application that acts as a system and service manager to initialize daemons/services at operating system startup. Systemd also supports tools that allow Linux administrators to easily manage and control these services after they are started.

As systemd is responsible for starting all other services, it runs as the first process (PID 1) created by the Linux kernel at startup. All other initial boot services are then started and managed by systemd, as shown by the process tree below from Ubuntu.

pstree ubuntu

On the other side of operating systems, the WSL (Windows Subsystem for Linux) currently uses init as a system and service manager, and so Linux applications that require systemd, such as Snap, microk8s () and systemctl, do not work properly.

WSL now supports systemd
Yesterday, Microsoft and Canonical they announced that the latest version of WSL (Windows Subsystem for Linux) in Windows 11 Insider builds now supports systemd, allowing you to install applications that require this service management.

If you're running a Windows 11 Insider build, you can in WSL 0.67.6 or later, using the command wsl --update. Once the update is complete, you can check the installed version using the corresponding command wsl --version.

You should then enable systemd by booting the desired WSL Linux distribution and adding the following lines to /etc/wsl.conf:

[boot] systemd=true

As the /etc folder is owned by root, you must use sudo for the console editor to edit the file. For example, sudo vi /etc/wsl.conf.

It should be noted that this process must be done for each distribution you want to enable systemd.

Finally, close the WSL window and from the Windows 11 Command Prompt (Command Prompt or ), close the WSL distributions with the command wsl.exe --shutdown and restart your Linux distribution and you will see systemd running as PID 1.

For more information on how systemd works in WSL and how it will allow you to run more applications in WSL, you can watch this video by Microsoft's Craig Loewen and Canonical's Oliver Smith.

iGuRu.gr The Best Technology Site in Greecefgns

every publication, directly to your inbox

Join the 2.086 registrants.
wsl, windows, linux, subsystem, systemd

Written by Dimitris

Dimitris hates on Mondays .....

Leave a reply

Your email address is not published. Required fields are mentioned with *

Your message will not be published if:
1. Contains insulting, defamatory, racist, offensive or inappropriate comments.
2. Causes harm to minors.
3. It interferes with the privacy and individual and social rights of other users.
4. Advertises products or services or websites.
5. Contains personal information (address, phone, etc.).