Open TheOnlyWei opened 1 month ago
@TheOnlyWei this is the core
version! Try the full
version if you want systemd
or run tdnf install systemd
@elsaco
Do you have a link to the version? I don't find any "full" versions when I search "mariner" in the Microsoft Artifact Registry: https://mcr.microsoft.com/en-us/catalog?search=mariner
If I install it with tdnf install systemd -y
, it doesn't work in the container due to this error:
root [ / ]# systemctl
System has not been booted with systemd as init system (PID 1). Can't operate.
Failed to connect to bus: Host is down
Here is a README
inside the /etc/init.d
folder of the core version saying systemd should be installed:
root [ /etc/init.d ]# cat README
You are looking for the traditional init scripts in /etc/rc.d/init.d,
and they are gone?
Here's an explanation on what's going on:
You are running a systemd-based OS where traditional init scripts have been replaced by native systemd services files. Service files provide very similar functionality to init scripts. To make use of service files simply invoke "systemctl", which will output a list of all currently running services (and other units). Use "systemctl list-unit-files" to get a listing of all known unit files, including stopped, disabled and masked ones. Use "systemctl start foobar.service" and "systemctl stop foobar.service" to start or stop a service, respectively. For further details, please refer to systemctl(1).
Note that traditional init scripts continue to function on a systemd system. An init script /etc/rc.d/init.d/foobar is implicitly mapped into a service unit foobar.service during system initialization.
Thank you!
Further reading: man:systemctl(1) man:systemd(1) http://0pointer.de/blog/projects/systemd-for-admins-3.html https://www.freedesktop.org/wiki/Software/systemd/Incompatibilities
So, we can't use the alternative either. This makes this seem like a bug.
Is your feature request related to a problem? Please describe. I would like the core Azure Linux Mariner image to contain
systemctl
command as advertised by this document: https://microsoft.github.io/azurelinux/docs/#managing-services-with-systemdHowever, the latest version (
mcr.microsoft.com/cbl-mariner/base/core:2.0.20240628
) doesn't seem to havesystemctl
command.This is the version I am using. Let me know if I am using the wrong one.
Describe the solution you'd like Have
systemctl
available for Azure Linux Mariner.