xfs/206: filter/fix for minor geometry reporting changes
authorEric Sandeen <sandeen@sandeen.net>
Fri, 25 May 2018 14:00:59 +0000 (09:00 -0500)
committerEryu Guan <guaneryu@gmail.com>
Sat, 26 May 2018 15:39:59 +0000 (23:39 +0800)
The pending common geometry printing function has removed the fiddly
little differences between the various utilities, so now we'll need
to accommodate that in xfs/206, which looks at mkfs & growfs output.

all now print "internal log" vs. just "internal"
ascii-ci now always has a "," after it

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Bill O'Donnell <billodo@redhat.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
tests/xfs/206
tests/xfs/206.out

index 01782b7b93a92c16e1c7330340aec8926012a78b..d5edf1ae1653962a4d91daee1e0307392904f429 100755 (executable)
@@ -73,13 +73,16 @@ echo "=== truncate file ==="
 dd if=/dev/zero of=$tmpfile bs=1 seek=19998630180864 count=1 >/dev/null 2>&1 \
        || _fail "!!! failed to truncate loopback file to correct size"
 
+# mkfs/growfs output has changed slightly over the years, this distills
+# it down to a common set of output parameters we care about
 mkfs_filter()
 {
        sed -e 's/meta-data=[^ ]*/meta-data=FILE/' \
            -e 's/ *isize=[0-9]* / isize=N /' \
            -e "s/\(^log.*blocks=\)\([0-9]*,\)/\1XXXXX,/" \
+           -e "s/internal log/internal    /" \
            -e "s/, projid32bit=[0-9]//" \
-           -e "s/ ftype=[0-9]//" \
+           -e "s/,\? ftype=[0-9]//" \
            -e "/.*reflink=/d" \
            -e "s/\(sectsz\)\(=[0-9]* *\)/\1=512   /" \
            -e "s/\(sunit=\)\([0-9]* blks,\)/\10 blks,/" \
index 2db839d0856ce1f24274266249aa5c57919ca325..be335600a8f9536ffaa48e682a1b16dc2ed66c18 100644 (file)
@@ -6,7 +6,7 @@ meta-data=FILE isize=N    agcount=52, agsize=76288719 blks
 data     =                       bsize=4096   blocks=3905982455, imaxpct=5
          =                       sunit=0      swidth=0 blks
 naming   =version 2              bsize=4096   ascii-ci=0
-log      =internal log           bsize=4096   blocks=XXXXX, version=2
+log      =internal               bsize=4096   blocks=XXXXX, version=2
          =                       sectsz=512   sunit=0 blks
 realtime =none                   extsz=4096   blocks=0, rtextents=0
 === xfs_growfs ===