Ignore:
Timestamp:
Apr 25, 2007, 12:27:26 AM (17 years ago)
Author:
Bruno Cornec
Message:
  • Remove compare-me
  • Update Logfiles for mondo scripts
  • label-partitions-as-necessary is now correct
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/stable/mondo/src/restore-scripts/mondo/label-partitions-as-necessary

    r1297 r1341  
    77
    88read_partition_line() {
    9     local tmp label mountpt command format
     9    local label mountpt command format
    1010
    11     if [ "`echo "$1" | grep -E 'LABEL='`" != "" ] ; then
     11    label=`echo "$1" | awk '{print $1}' | cut -d'=' -f2`
     12    format=`echo "$1" | awk '{print $3}'`
     13
     14    if [ "`echo "$1" | grep -E 'LABEL='`" != "" ] ; then
    1215        opttun="-L"
    13     elif [ "`echo "$1" | grep -E 'UUID='`" != "" ] ; then
     16        mountpt=`awk '{print $1,$5}' $mountlist | grep " $label$" | awk '{print $1}'`
     17    elif [ "`echo "$1" | grep -E 'UUID='`" != "" ] ; then
    1418        opttun="-U"
     19        mountpt=`awk '{print $1,$6}' $mountlist | grep " $label$" | awk '{print $1}'`
    1520    else
    1621        # Nothing to do
    1722        return
    18     fi
     23    fi
    1924
    20     tmp=`echo "$1" | tr -s ' ' '\t' | cut -f1`
    21     label=`echo "$tmp" | cut -d'=' -f2`
    22     format=`echo "$1" | tr -s ' ' '\t' | cut -f3`
    23     mountpt=`grep -w " $label" $mountlist | cut -d' ' -f1`
    2425    if [ ! "$mountpt" ] ; then
    25         LogIt "Not labeling anything as $label because $mountpt is not a mountpoint"
     26        LogIt "Not labeling anything as ($label) because ($mountpt) is not a mountpoint"
    2627    elif [ ! "$label" ] ; then
    27         LogIt "Not labeling $mountpt as anything because $label is not a label"
     28        LogIt "Not labeling ($mountpt) as anything because ($label) is not a label"
    2829    else
    2930        if [ "$format" = "ext2" ] || [ "$format" = "ext3" ] ; then
Note: See TracChangeset for help on using the changeset viewer.