Changeset 3008 for branches/3.0/mindi


Ignore:
Timestamp:
May 15, 2012, 6:13:10 PM (7 years ago)
Author:
bruno
Message:
  • Fix #618 by adding support for new command tune4fs for labelling ext4 FS (needed on RHEL 5.6 at least)
Location:
branches/3.0/mindi
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/3.0/mindi/deplist.d/fs.conf

    r2943 r3008  
    3737/sbin/btrfsck
    3838
    39 # ext2/3
     39# ext2/3/4
    4040#
    4141/sbin/e2label
     42/sbin/e4label
    4243/sbin/tune2fs
     44/sbin/tune4fs
    4345/etc/mke2fs.conf
    4446
  • branches/3.0/mindi/mindi

    r3007 r3008  
    27242724    gvFileSystem=`GetInitrdFilesystemToUse ${kernelpath}`
    27252725    [ -z  gvFileSystem ] && Die "GetFilesystemToUse() failed. Terminating."
    2726     if [ "$gvFileSystem" = "ext2fs" ] || [ "$gvFileSystem" = "ext3fs" ]; then
     2726    if [ "$gvFileSystem" = "ext2fs" ] || [ "$gvFileSystem" = "ext3fs" ] || [ "$gvFileSystem" = "ext4fs" ]; then
    27272727        # say what will be used
    27282728        LogFile "INFO: Creating an $gvFileSystem initrd image..."
     
    27322732        umount $mountpoint || Die "Cannot unmount $tempfile"
    27332733        dd if=$tempfile bs=1k 2> /dev/null > ${rdz_fname}.tmp 2> /dev/null
    2734         bs=`tune2fs -l ${rdz_fname}.tmp | grep -E '^Block size:' | cut -d: -f2 | sed 's/^ *//'`
     2734        if [ "$gvFileSystem" = "ext4fs" ] && [ -x "/sbin/tune4fs" ]; then
     2735            bs=`/sbin/tune4fs -l ${rdz_fname}.tmp | grep -E '^Block size:' | cut -d: -f2 | sed 's/^ *//'`
     2736        else
     2737            bs=`tune2fs -l ${rdz_fname}.tmp | grep -E '^Block size:' | cut -d: -f2 | sed 's/^ *//'`
     2738        fi
    27352739        MINDI_ADDITIONAL_BOOT_PARAMS="$MINDI_ADDITIONAL_BOOT_PARAMS ramdisk_blocksize=$bs"
    27362740        gzip -c9 ${rdz_fname}.tmp > $rdz_fname
Note: See TracChangeset for help on using the changeset viewer.