Changeset 2809
Legend:
- Unmodified
- Added
- Removed
-
pcbsd/branches/7.0/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.FormatPartition.sh
r2560 r2809 16 16 rawslice="`echo ${2} | cut -d '/' -f 3`" 17 17 18 # Get the number of the slice we are working on 19 slicenum="`echo ${2} | awk '{print substr($0,length,1)}'`" 20 21 18 22 # Check if we need to shutdown any journals on this partition 19 23 ls ${slice}*.journal* >/dev/null 2>/dev/null … … 31 35 32 36 # Make sure we have disabled swap on this drive 33 swapoff ${slice}b 37 if [ -e "${slice}b" ] 38 then 39 swapoff ${slice}b 40 fi 41 42 # Get the fdisk -s output of this device 43 fdisk -s /dev/${device} | grep -v "${device}:" | grep "${slicenum}:" | tr -s " " > /tmp/fdiskblk 44 startblock="`cat /tmp/fdiskblk | cut -d ' ' -f 3`" 45 endblock="`cat /tmp/fdiskblk | cut -d ' ' -f 4`" 46 47 # Create the new fdiskconfig file now to set this partition to type 165 48 echo "p ${slicenum} 165 ${startblock} ${endblock}" > /tmp/fdiskconfig 34 49 35 50 sleep 4 -
pcbsd/trunk/installcd-overlay/usr/local/pcbsd/scripts/PCBSD.FormatPartition.sh
r2560 r2809 16 16 rawslice="`echo ${2} | cut -d '/' -f 3`" 17 17 18 # Get the number of the slice we are working on 19 slicenum="`echo ${2} | awk '{print substr($0,length,1)}'`" 20 21 18 22 # Check if we need to shutdown any journals on this partition 19 23 ls ${slice}*.journal* >/dev/null 2>/dev/null … … 31 35 32 36 # Make sure we have disabled swap on this drive 33 swapoff ${slice}b 37 if [ -e "${slice}b" ] 38 then 39 swapoff ${slice}b 40 fi 41 42 # Get the fdisk -s output of this device 43 fdisk -s /dev/${device} | grep -v "${device}:" | grep "${slicenum}:" | tr -s " " > /tmp/fdiskblk 44 startblock="`cat /tmp/fdiskblk | cut -d ' ' -f 3`" 45 endblock="`cat /tmp/fdiskblk | cut -d ' ' -f 4`" 46 47 # Create the new fdiskconfig file now to set this partition to type 165 48 echo "p ${slicenum} 165 ${startblock} ${endblock}" > /tmp/fdiskconfig 34 49 35 50 sleep 4
