Changeset 1531


Ignore:
Timestamp:
Jul 6, 2007, 4:37:54 PM (12 years ago)
Author:
bruno
Message:

Support for swap with UUID on VMWare ESX 3 at least with dumpuuid

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.4/mindi/mindi

    r1526 r1531  
    13331333            fi
    13341334   
    1335             # 2nd try : blkid, the good way for all LABEL except swap
     1335            # 2nd try : blkid, the good way for all UUID except swap
    13361336            if [ "x$actual_dev" = "x" -a -x "/sbin/blkid" ]; then
    13371337                actual_dev=`/sbin/blkid | /bin/grep "$uuid" | grep UUID= | cut -d':' -f1`
     
    13561356                for dev in $list_dev ; do
    13571357                    dev_exists=`/sbin/vol_id $dev | /bin/grep "$uuid"`
     1358                    if [ "x$dev_exists" != "x" ]; then
     1359                        actual_dev=$dev
     1360                        break;
     1361                    fi
     1362                done
     1363            fi
     1364
     1365            # 4th try, with dumpuuid (VMWare only ?) for swap
     1366            if [ "x$actual_dev" = "x" -a -x "/sbin/dumpuuid" ]; then
     1367                list_dev=`cat /proc/swaps | /bin/grep -E '^/' | $AWK '{ print $1 }' `
     1368                for dev in $list_dev ; do
     1369                    dev_exists=`/sbin/dumpuuid $dev | /bin/grep "$uuid"`
    13581370                    if [ "x$dev_exists" != "x" ]; then
    13591371                        actual_dev=$dev
     
    29152927lsmod >> $LOGFILE
    29162928MODULES="`cat /proc/modules | awk '{print $1}'`"
    2917 if [ -e /usr/sbin/esxcfg-module ]; then
     2929if [ -x /usr/sbin/esxcfg-module ]; then
    29182930    echo "VMWare ESX server detected - Enabling dedicated support" >> $LOGFILE
    29192931    echo "-------------" >> $LOGFILE
    29202932    echo "VMWare modules" >> $LOGFILE
    29212933    echo "-------------" >> $LOGFILE
    2922     esxcfg-module -l >> $LOGFILE
     2934    /usr/sbin/esxcfg-module -l >> $LOGFILE
    29232935    MODULES="$MODULES `esxcfg-module -l | awk '{print $1}'`"
    29242936fi
Note: See TracChangeset for help on using the changeset viewer.