VirtualBox

vbox的更動 67054 路徑 trunk/src/VBox/Installer


忽略:
時間撮記:
2017-5-24 上午08:36:39 (7 年 以前)
作者:
vboxsync
訊息:

bugref:8834: Makeself installers/Linux: indicate problems better in the exit codes
Detect failure to build kernel modules, to load kernel modules or to replace running kernel modules in the base Makeself installer.

檔案:
修改 1 筆資料

圖例:

未更動
新增
刪除
  • trunk/src/VBox/Installer/linux/install.sh

    r63645 r67054  
    1515# hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
    1616#
     17
     18# Testing:
     19# * After successful installation, 0 is returned if the vboxdrv module version
     20#   built matches the one loaded.
     21# * If the kernel modules cannot be built (run the installer with KERN_DIR=/) or
     22#   loaded (run with KERN_DIR=/lib/modules/<installed non-current version>/build)
     23#   then 1 is returned.
    1724
    1825PATH=$PATH:/bin:/sbin:/usr/sbin
     
    5360VBOXUSB_GRP=$GROUPNAME
    5461
     62## Were we able to stop any previously running Additions kernel modules?
     63MODULES_STOPPED=1
     64
    5565
    5666##############################################################################
     
    381391    fi
    382392    "${INSTALLATION_DIR}/prerm-common.sh" >> "${LOG}"
     393
     394    # Now check whether the kernel modules were stopped.
     395    lsmod | grep -q vboxdrv && MODULES_STOPPED=
     396
    383397    "${INSTALLATION_DIR}/postinst-common.sh" ${START_SERVICES} >> "${LOG}"
    384398
     
    393407    info "We hope that you enjoy using VirtualBox."
    394408    info ""
     409
     410    # And do a final test as to whether the kernel modules were properly created
     411    # and loaded.  Return 0 if both are true, 1 if not.
     412    test -n "${MODULES_STOPPED}" &&
     413        modinfo vboxdrv >/dev/null 2>&1 &&
     414        lsmod | grep -q vboxdrv ||
     415        abort "The installation log file is at ${LOG}."
     416
    395417    log "Installation successful"
    396418elif [ "$ACTION" = "uninstall" ]; then
注意: 瀏覽 TracChangeset 來幫助您使用更動檢視器

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