VirtualBox

Changeset 56851 in vbox


Ignore:
Timestamp:
Jul 8, 2015 9:11:04 AM (10 years ago)
Author:
vboxsync
Message:

Installers/linux: systemd: systemctl enable missing.

File:
1 edited

Legend:

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

    r56850 r56851  
    222222ExecStart=${script} start
    223223ExecStop=${script} stop
     224
     225[Install]
     226WantedBy=multi-user.target
    224227EOF
    225228}
     
    349352    fi
    350353    get_chkconfig_info "${init_d_path}/init.d/${name}" || return 1
     354    if test -x "`which systemctl 2>/dev/null`"
     355    then
     356        systemctl enable "${name}"
    351357    # Redhat based sysvinit systems
    352     if test -x "`which chkconfig 2>/dev/null`"
     358    elif test -x "`which chkconfig 2>/dev/null`"
    353359    then
    354360        chkconfig --add "${name}" || {
     
    395401    test ! -z "${name}" || \
    396402        { log "${self}: missing argument" && return 1; }
     403    if test -x "`which systemctl 2>/dev/null`"
     404    then
     405        systemctl disable "${name}"
    397406    # Redhat-based systems
    398     if test -x "/sbin/chkconfig"
     407    elif test -x "/sbin/chkconfig"
    399408    then
    400409        /sbin/chkconfig --del "${name}" > /dev/null 2>&1
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