Ignore:
Timestamp:
Oct 31, 2007, 1:11:44 AM (16 years ago)
Author:
Bruno Cornec
Message:

Fix UUID support which was still broken.
Caveat: It can't work for swap partitions as there is no mksap -U option contrary to the -L option for LABEL
So at reboot you won't have swap activated and you'll have to run vol_id -u the_swap_partition to fix your /etc/fstab file

File:
1 edited

Legend:

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

    r1314 r1755  
    1111    label=`echo "$1" | awk '{print $1}' | cut -d'=' -f2`
    1212    format=`echo "$1" | awk '{print $3}'`
     13    mountpt=`awk '{print $1,$5}' $mountlist | grep " $label$" | awk '{print $1}'`
    1314
    1415    if [ "`echo "$1" | grep -E 'LABEL='`" != "" ] ; then
    1516        opttun="-L"
    16         mountpt=`awk '{print $1,$5}' $mountlist | grep " $label$" | awk '{print $1}'`
    1717    elif [ "`echo "$1" | grep -E 'UUID='`" != "" ] ; then
    1818        opttun="-U"
    19         mountpt=`awk '{print $1,$6}' $mountlist | grep " $label$" | awk '{print $1}'`
    2019    else
    2120        # Nothing to do
     
    3534            if [ "$opttun" = "-U" ]; then
    3635                echo "Unable yet to identify swap with UUID"
     36                echo "You'll have to modify your /etc/fstab after reboot"
     37                echo "Replace the UUID found on the swap line by the one"
     38                echo "given by the command vol_id -u $mountpt"
     39                echo "And ask Ubuntu guys to deliver a mswap command with"
     40                echo "a -U option to update the UUID to what we want !!!"
     41
     42                sleep 5
    3743            else
    3844                command="mkswap $opttun $label $mountpt"
Note: See TracChangeset for help on using the changeset viewer.