VirtualBox

Changeset 98468 in vbox for trunk/src/VBox/Installer


Ignore:
Timestamp:
Feb 3, 2023 2:54:32 PM (22 months ago)
Author:
vboxsync
Message:

Linux: Additions and host installer: Improve check if distribution is running systemd as init process, bugref:10347.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/linux/routines.sh

    r98103 r98468  
    187187}
    188188
    189 # Checks if systemd is the init system of choice
     189# Checks if systemctl is present and functional (i.e., systemd is the init process).
    190190use_systemd()
    191191{
    192     # First condition is what halfway recent systemd uses itself, and the
    193     # other two checks should cover everything back to v1.
    194     test -e /run/systemd/system || test -e /sys/fs/cgroup/systemd || test -e /cgroup/systemd
     192    systemctl status >/dev/null 2>&1
    195193}
    196194
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette