xfstests: various fixes
cover xfstests: various fixes
Hi folks,
I figured that sending 77 patches to the list in one day wasn't enough, so here's another 6 for xfstests. These patches fix the suid tests in generic/193 to run on the target filesystem, test suid/sgid behaviour for truncate, stop the experimatal warnings from CRC enabled xfsprogs from making tests fail, fix a missing $seq to $seqres conversion, convert an ENOSPC test to work with arbitrary block sizes, avoid tests that currently won't run or are not relevant for CRC enabled filesystems, and add a multithreaded test mode to the bstat test program....
-Dave.
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
PATCH 1/6 xfstests: generic/193 runs tests in wrong location
From: Dave Chinner <[email protected]>
generic/193 runs the test in $here - the root of the xfstests source tree/installation. IOWs, it doesn't test the filesystem on either the TEST_DIR or SCRATCH_MNT, and so it not testing the filesystem we think it is testing. Bad. Fixing this is the majority of the change - introducing $test_root and $test_user for the files with different owners, and then redirecting error output and filtering the output appropriately.
And then add checks that truncate clears the suid/sgid bits appropriately, somethign that has never been tested on XFS (and likely other filesystems) so will cause kernels between 3.1 and 3.9 to assert fail as Dave Jones has recently reported.
--- tests/generic/193 | 135 ++++++++++++++++++++++++++++++++----------------- tests/generic/193.out | 17 ++++++- 2 files changed, 105 insertions(+), 47 deletions(-)
tests/generic/193 +90 -45
@@ -43,9 +43,9 @@ tag="added by qa $seq" # _create_files() { - touch test.root - touch test.${qa_user} - chown ${qa_user}:${qa_user} test.${qa_user} + touch $test_root + touch $test_user + chown ${qa_user}:${qa_user} $test_user } #
@@ -53,8 +53,13 @@ _create_files() # _cleanup_files() { - rm -f test.${qa_user} - rm -f test.root + rm -f $test_user + rm -f $test_root +} + +_filter_files() +{ + sed -e "s,$test_root,test.root,g" -e "s,$test_user,test.user,g" } # get standard environment, filters and checks
@@ -68,6 +73,9 @@ _supported_os Linux _require_user _need_to_be_root +test_root=$TEST_DIR/$seq.$$.root +test_user=$TEST_DIR/$seq.$$.user + # # make sure we have a normal umask set #
@@ -83,17 +91,17 @@ echo _create_files echo "user: chown root owned file to qa_user (should fail)" -su ${qa_user} -c "chown ${qa_user} test.root" +su ${qa_user} -c "chown ${qa_user} $test_root" 2>&1 | _filter_files echo "user: chown root owned file to root (should fail)" -su ${qa_user} -c "chown root test.root" +su ${qa_user} -c "chown root $test_root" 2>&1 | _filter_files echo "user: chown qa_user owned file to qa_user (should succeed)" -su ${qa_user} -c "chown ${qa_user} test.${qa_user}" +su ${qa_user} -c "chown ${qa_user} $test_user" # this would work without _POSIX_CHOWN_RESTRICTED echo "user: chown qa_user owned file to root (should fail)" -su ${qa_user} -c "chown root test.${qa_user}" +su ${qa_user} -c "chown root $test_user" 2>&1 | _filter_files _cleanup_files
@@ -107,19 +115,19 @@ echo _create_files echo "user: chgrp root owned file to root (should fail)" -su ${qa_user} -c "chgrp root test.root" +su ${qa_user} -c "chgrp root $test_root" 2>&1 | _filter_files echo "user: chgrp qa_user owned file to root (should fail)" -su ${qa_user} -c "chgrp root test.${qa_user}" +su ${qa_user} -c "chgrp root $test_user" 2>&1 | _filter_files echo "user: chgrp root owned file to qa_user (should fail)" -su ${qa_user} -c "chgrp ${qa_user} test.root" +su ${qa_user} -c "chgrp ${qa_user} $test_root" 2>&1 | _filter_files echo "user: chgrp qa_user owned file to qa_user (should succeed)" -su ${qa_user} -c "chgrp ${qa_user} test.${qa_user}" +su ${qa_user} -c "chgrp ${qa_user} $test_user" #echo "user: chgrp qa_user owned file to secondary group (should succeed)" -#su ${qa_user} -c "chgrp ${group2} test.${qa_user}" +#su ${qa_user} -c "chgrp ${group2} $test_user" _cleanup_files
@@ -133,10 +141,10 @@ echo _create_files echo "user: chmod a+r on qa_user owned file (should succeed)" -su ${qa_user} -c "chmod a+r test.${qa_user}" +su ${qa_user} -c "chmod a+r $test_user" echo "user: chmod a+r on root owned file (should fail)" -su ${qa_user} -c "chmod a+r test.root" +su ${qa_user} -c "chmod a+r $test_root" 2>&1 | _filter_files # # Setup a file owned by the qa_user, but with a group ID that
@@ -153,12 +161,12 @@ su ${qa_user} -c "chmod a+r test.root" # reg file + file's gid not in process' group set + no approp. privileges -> clear sgid # echo "check that the sgid bit is cleared" -chown ${qa_user}:root test.${qa_user} -chmod g+s test.${qa_user} +chown ${qa_user}:root $test_user +chmod g+s $test_user # and let the qa_user change permission bits -su ${qa_user} -c "chmod a+w test.${qa_user}" -stat -c '%A' test.${qa_user} +su ${qa_user} -c "chmod a+w $test_user" +stat -c '%A' $test_user # # Setup a file owned by the qa_user and with the suid bit set.
@@ -166,9 +174,9 @@ stat -c '%A' test.${qa_user} # There is nothing in Posix that says it should but just checking. # echo "check that suid bit is not cleared" -chmod u+s test.${qa_user} -chmod a+w test.${qa_user} -stat -c '%A' test.${qa_user} +chmod u+s $test_user +chmod a+w $test_user +stat -c '%A' $test_user _cleanup_files
@@ -196,35 +204,72 @@ _create_files echo "check that suid/sgid bits are cleared after successful chown..." echo "with no exec perm" -chmod ug+s test.${qa_user} -echo -n "before: "; stat -c '%A' test.${qa_user} -chown root test.${qa_user} -echo -n "after: "; stat -c '%A' test.${qa_user} +chmod ug+s $test_user +echo -n "before: "; stat -c '%A' $test_user +chown root $test_user +echo -n "after: "; stat -c '%A' $test_user echo "with user exec perm" -chmod ug+s test.${qa_user} -chmod u+x test.${qa_user} -echo -n "before: "; stat -c '%A' test.${qa_user} -chown root test.${qa_user} -echo -n "after: "; stat -c '%A' test.${qa_user} +chmod ug+s $test_user +chmod u+x $test_user +echo -n "before: "; stat -c '%A' $test_user +chown root $test_user +echo -n "after: "; stat -c '%A' $test_user echo "with group exec perm" -chmod ug+s test.${qa_user} -chmod g+x test.${qa_user} -chmod u-x test.${qa_user} -echo -n "before: "; stat -c '%A' test.${qa_user} -chown root test.${qa_user} -echo -n "after: "; stat -c '%A' test.${qa_user} +chmod ug+s $test_user +chmod g+x $test_user +chmod u-x $test_user +echo -n "before: "; stat -c '%A' $test_user +chown root $test_user +echo -n "after: "; stat -c '%A' $test_user echo "with user+group exec perm" -chmod ug+s test.${qa_user} -chmod ug+x test.${qa_user} -echo -n "before: "; stat -c '%A' test.${qa_user} -chown root test.${qa_user} -echo -n "after: "; stat -c '%A' test.${qa_user} +chmod ug+s $test_user +chmod ug+x $test_user +echo -n "before: "; stat -c '%A' $test_user +chown root $test_user +echo -n "after: "; stat -c '%A' $test_user _cleanup_files +_create_files +# Now test out the clear of suid/sgid for truncate +# +echo "check that suid/sgid bits are cleared after successful truncate..." + +echo "with no exec perm" +echo frobnozzle >> $test_user +chmod ug+s $test_user +echo -n "before: "; stat -c '%A' $test_user +su ${qa_user} -c "echo > $test_user" +echo -n "after: "; stat -c '%A' $test_user + +echo "with user exec perm" +echo frobnozzle >> $test_user +chmod ug+s $test_user +chmod u+x $test_user +echo -n "before: "; stat -c '%A' $test_user +su ${qa_user} -c "echo > $test_user" +echo -n "after: "; stat -c '%A' $test_user + +echo "with group exec perm" +echo frobnozzle >> $test_user +chmod ug+s $test_user +chmod g+x $test_user +chmod u-x $test_user +echo -n "before: "; stat -c '%A' $test_user +su ${qa_user} -c "echo > $test_user" +echo -n "after: "; stat -c '%A' $test_user + +echo "with user+group exec perm" +echo frobnozzle >> $test_user +chmod ug+s $test_user +chmod ug+x $test_user +echo -n "before: "; stat -c '%A' $test_user +su ${qa_user} -c "echo > $test_user" +echo -n "after: "; stat -c '%A' $test_user + # # Test ATTR_*TIMES_SET #
@@ -235,10 +280,10 @@ echo _create_files echo "user: touch qa_user file (should succeed)" -su ${qa_user} -c "touch test.${qa_user}" +su ${qa_user} -c "touch $test_user" echo "user: touch root file (should fail)" -su ${qa_user} -c "touch test.root" +su ${qa_user} -c "touch $test_root" 2>&1 | _filter_files _cleanup_files
tests/generic/193.out +15 -2
@@ -8,14 +8,14 @@ user: chown root owned file to root (should fail) chown: changing ownership of `test.root': Operation not permitted user: chown qa_user owned file to qa_user (should succeed) user: chown qa_user owned file to root (should fail) -chown: changing ownership of `test.fsgqa': Operation not permitted +chown: changing ownership of `test.user': Operation not permitted testing ATTR_GID user: chgrp root owned file to root (should fail) chgrp: changing group of `test.root': Operation not permitted user: chgrp qa_user owned file to root (should fail) -chgrp: changing group of `test.fsgqa': Operation not permitted +chgrp: changing group of `test.user': Operation not permitted user: chgrp root owned file to qa_user (should fail) chgrp: changing group of `test.root': Operation not permitted user: chgrp qa_user owned file to qa_user (should succeed)
@@ -42,6 +42,19 @@ after: -rw-r-xr-- with user+group exec perm before: -rwsr-sr-- after: -rwxr-xr-- +check that suid/sgid bits are cleared after successful truncate... +with no exec perm +before: -rwSr-Sr-- +after: -rw-r-Sr-- +with user exec perm +before: -rwsr-Sr-- +after: -rwxr-Sr-- +with group exec perm +before: -rwSr-sr-- +after: -rw-r-xr-- +with user+group exec perm +before: -rwsr-sr-- +after: -rwxr-xr-- testing ATTR_*TIMES_SET
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 1/6] xfstests: generic/193 runs tests in wrong location
Quoted 10 lines · Dave Chinner
From: Dave Chinner <[email protected]>
generic/193 runs the test in $here - the root of the xfstests source tree/installation. IOWs, it doesn't test the filesystem on either the
TEST_DIRorSCRATCH_MNT, and so it not testing the filesystem we think it is testing. Bad. Fixing this is the majority of the change - introducing $test_root and $test_user for the files with different owners, and then redirecting error output and filtering the output appropriately.
Quoted 6 lines
And then add checks that truncate clears the suid/sgid bits appropriately, somethign that has never been tested on XFS (and likely other filesystems) so will cause kernels between 3.1 and 3.9 to assert fail as Dave Jones has recently reported.
Signed-off-by Dave Chinner <[email protected]>
Looks good. The behavior you outlined regarding suid/sgid bits matches that of should_remove_suid().
Applied.
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
PATCH 2/6 xfstests: ensure all mkfs output is redirected properly
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
mkfs.xfs with experimental CRC support outputs extra warnings about being experimental on stderr, and so some tests do not redirect the output correctly. These tests fail with a golden output mismatch due to this. Fix these tests by redirecting stderr to either seqres.full or /dev/null.
--- common/dump | 4 ++-- common/rc | 2 +- common/repair | 2 ++ tests/xfs/004 | 3 ++- tests/xfs/021 | 2 +- tests/xfs/029 | 2 +- tests/xfs/030 | 5 +++-- tests/xfs/031 | 10 +++++++--- tests/xfs/033 | 6 ++++-- tests/xfs/041 | 5 +++-- tests/xfs/042 | 2 +- tests/xfs/050 | 3 ++- tests/xfs/052 | 3 ++- tests/xfs/067 | 4 ++-- tests/xfs/071 | 3 ++- tests/xfs/072 | 3 +-- tests/xfs/073 | 17 +++++++++++------ tests/xfs/092 | 2 +- tests/xfs/104 | 7 +++++-- tests/xfs/106 | 3 ++- tests/xfs/107 | 3 ++- tests/xfs/108 | 3 ++- tests/xfs/109 | 3 ++- tests/xfs/110 | 3 ++- tests/xfs/118 | 2 +- tests/xfs/178 | 2 +- tests/xfs/189 | 3 ++- tests/xfs/244 | 6 ++++-- tests/xfs/287 | 4 ++-- 29 files changed, 73 insertions(+), 44 deletions(-)
common/dump +2 -2
@@ -236,8 +236,8 @@ _wipe_fs() { _require_scratch - _scratch_mkfs_xfs >>$seqres.full || _fail "mkfs failed" - _scratch_mount >>$seqres.full || _fail "mount failed" + _scratch_mkfs_xfs >>$seqres.full 2>&1 || _fail "mkfs failed" + _scratch_mount >>$seqres.full 2>&1 || _fail "mount failed" } #
common/rc +1 -1
@@ -1078,7 +1078,7 @@ _require_dm_flakey() # _require_projid32bit() { - _scratch_mkfs_xfs -f -i projid32bit=0 2>&1 >/dev/null \ + _scratch_mkfs_xfs -f -i projid32bit=0 >/dev/null 2>&1 \ || _notrun "mkfs.xfs doesn't have projid32bit feature" }
common/repair +2 -0
@@ -80,6 +80,8 @@ s/\s+- \d+:\d\d:\d\d:.*\n//g; # crc enabled filesystem output /XFS_CORRUPTION_ERROR/ && next; /^bad uuid/ && next; +/^Version 5 superblock detected./ && next; +/^Use of these features/ && next; print;' }
tests/xfs/004 +2 -1
@@ -41,7 +41,8 @@ trap "_cleanup" 0 1 2 3 15 _populate_scratch() { echo "=== mkfs output ===" >>$seqres.full - _scratch_mkfs_xfs | tee -a $seqres.full | _filter_mkfs 2>$tmp.mkfs + _scratch_mkfs_xfs 2> /dev/null | tee -a $seqres.full \ + | _filter_mkfs 2>$tmp.mkfs || _fail "mkfs failed" . $tmp.mkfs _scratch_mount dd if=/dev/zero of=$SCRATCH_MNT/foo count=200 bs=4096 >/dev/null 2>&1 &
tests/xfs/021 +1 -1
@@ -83,7 +83,7 @@ rm -f $seqres.full umount $SCRATCH_DEV >/dev/null 2>&1 echo "*** mkfs" -_scratch_mkfs_xfs >/dev/null \ +_scratch_mkfs_xfs >/dev/null 2>&1 \ || _fail "mkfs failed" echo "*** mount FS"
tests/xfs/029 +1 -1
@@ -58,7 +58,7 @@ _supported_os Linux _require_scratch echo -_scratch_mkfs_xfs | _filter_mkfs 2>/dev/null +_scratch_mkfs_xfs > /dev/null 2>&1 || _fail "mkfs failed" echo _scratch_xfs_logprint | _filter_logprint
tests/xfs/030 +3 -2
@@ -74,7 +74,7 @@ DSIZE="-dsize=100m,agcount=6" # superblock (hanging around from earlier tests)... # -_scratch_mkfs_xfs $DSIZE >/dev/null 2>&1 +_scratch_mkfs_xfs $DSIZE >/dev/null 2>&1 || _fail "mkfs failed" if [ $? -ne 0 ] # probably don't have a big enough scratch then _notrun "SCRATCH_DEV too small, results would be non-deterministic"
@@ -98,7 +98,8 @@ src/devzero -v -1 -n "$clear" $SCRATCH_DEV >/dev/null # now kick off the real repair test... # -_scratch_mkfs_xfs $DSIZE | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs $DSIZE 2>/dev/null | _filter_mkfs 2>$tmp.mkfs\ + || _fail "mkfs failed" . $tmp.mkfs _check_ag 0 _check_ag -1
tests/xfs/031 +7 -3
@@ -56,6 +56,8 @@ _check_repair() fi # echo all interesting stuff... perl -ne ' + /EXPERIMENTAL/d; + /Use of these features/d; s/(rebuilding directory inode) (\d+)/\1 INO/g; s/internal log/<TYPEOF> log/g; s/external log on \S+/<TYPEOF> log/g;
@@ -104,7 +106,7 @@ _require_no_large_scratch_dev # Note: must do this proto/mkfs now for later inode size calcs _create_proto 0 echo "=== one entry (shortform)" -_scratch_mkfs_xfs -p $tmp.proto >$tmp.mkfs0 2>&1 +_scratch_mkfs_xfs -p $tmp.proto >$tmp.mkfs0 2>&1 || _fail "mkfs failed" _filter_mkfs <$tmp.mkfs0 >/dev/null 2>$tmp.mkfs . $tmp.mkfs _check_repair
@@ -112,13 +114,15 @@ _check_repair # block-form root directory & repeat _create_proto 20 echo "=== twenty entries (block form)" -_scratch_mkfs_xfs -p $tmp.proto | _filter_mkfs >/dev/null 2>&1 +_scratch_mkfs_xfs -p $tmp.proto 2> /dev/null | _filter_mkfs >/dev/null 2>&1 \ + || _fail "mkfs failed" _check_repair # leaf-form root directory & repeat _create_proto 1000 echo "=== thousand entries (leaf form)" -_scratch_mkfs_xfs -p $tmp.proto | _filter_mkfs >/dev/null 2>&1 +_scratch_mkfs_xfs -p $tmp.proto | _filter_mkfs >/dev/null 2>&1 \ + || _fail "mkfs failed" _check_repair # success, all done
tests/xfs/033 +4 -2
@@ -81,10 +81,12 @@ _require_scratch _require_no_large_scratch_dev # devzero blows away 512byte blocks, so make 512byte inodes (at least) -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" . $tmp.mkfs [ $isize -lt 512 ] && \ - _scratch_mkfs_xfs -isize=512 | _filter_mkfs >/dev/null 2>&1 + _scratch_mkfs_xfs -isize=512 2> /dev/null \ + | _filter_mkfs >/dev/null 2>&1 || _fail "mkfs failed" `xfs_db -r -c sb -c p $SCRATCH_DEV | grep 'ino = ' | \ sed -e 's/ //g' -e 's/^/export /'`
tests/xfs/041 +3 -2
@@ -63,8 +63,9 @@ _do_die_on_error=message_only rm -f $seqres.full agsize=32 echo -n "Make $agsize megabyte filesystem on SCRATCH_DEV and mount... " -_scratch_mkfs_xfs -dsize=${agsize}m,agcount=1 2>&1 >/dev/null || _fail "mkfs failed" -bsize=`_scratch_mkfs_xfs -dsize=${agsize}m,agcount=1 2>&1 | _filter_mkfs 2>&1 \ +_scratch_mkfs_xfs -dsize=${agsize}m,agcount=1 >/dev/null 2>&1 || _fail "mkfs failed" +bsize=`_scratch_mkfs_xfs -dsize=${agsize}m,agcount=1 2> /dev/null \ + |_filter_mkfs 2>&1 \ | perl -ne 'if (/dbsize=(\d+)/) {print $1;}'` onemeginblocks=`expr 1048576 / $bsize` _scratch_mount || _fail "mount failed"
tests/xfs/042 +1 -1
@@ -91,7 +91,7 @@ rm -f $seqres.full _do_die_on_error=message_only echo -n "Make a 48 megabyte filesystem on SCRATCH_DEV and mount... " -_scratch_mkfs_xfs -dsize=48m,agcount=3 2>&1 >/dev/null || _fail "mkfs failed" +_scratch_mkfs_xfs -dsize=48m,agcount=3 >/dev/null 2>&1 || _fail "mkfs failed" _scratch_mount || _fail "mount failed" echo "done"
tests/xfs/050 +2 -1
@@ -116,7 +116,8 @@ _qsetup() _exercise() { - _scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs + _scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" cat $tmp.mkfs >>$seqres.full # keep the blocksize and data size for dd later
tests/xfs/052 +2 -1
@@ -59,7 +59,8 @@ _require_nobody # setup a default run _qmount_option uquota -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" cat $tmp.mkfs >>$seqres.full chmod a+w $seqres.full # arbitrary users will write here
tests/xfs/067 +2 -2
@@ -47,10 +47,10 @@ _require_scratch # set up fs for 1K inodes isize=0 -_scratch_mkfs_xfs | _filter_mkfs >$seqres.full 2>$tmp.mkfs +_scratch_mkfs_xfs 2>&1 | _filter_mkfs >$seqres.full 2>$tmp.mkfs [ $? -eq 0 ] && source $tmp.mkfs if [ "$isize" -lt 1024 ]; then - _scratch_mkfs_xfs -i size=1024 >>$seqres.full \ + _scratch_mkfs_xfs -i size=1024 >>$seqres.full 2>&1 \ || _notrun "Cannot mkfs for this test using MKFS_OPTIONS specified" fi _scratch_mount >>$seqres.full || _fail "mount failed"
tests/xfs/071 +2 -1
@@ -105,7 +105,8 @@ _supported_os IRIX Linux [ -n "$XFS_IO_PROG" ] || _notrun "xfs_io executable not found" _require_scratch -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" . $tmp.mkfs echo _scratch_mount
tests/xfs/072 +1 -2
@@ -51,9 +51,8 @@ _supported_os IRIX Linux _require_scratch rm -f $seqres.full -umount $SCRATCH_DEV >/dev/null 2>&1 -_scratch_mkfs_xfs >/dev/null || _fail "mkfs failed" +_scratch_mkfs_xfs >/dev/null 2>&1 || _fail "mkfs failed" _scratch_mount >/dev/null || _fail "mount failed" # check there's enough freespace on $SCRATCH_MNT ... (1GiB + 1MiB)
tests/xfs/073 +11 -6
@@ -133,7 +133,8 @@ _supported_os Linux _require_scratch _require_loop -_scratch_mkfs_xfs -dsize=41m,agcount=2 | _filter_mkfs 2>/dev/null +_scratch_mkfs_xfs -dsize=41m,agcount=2 2> /dev/null | _filter_mkfs 2>/dev/null \ + || _fail "mkfs failed" _scratch_mount 2>/dev/null || _fail "initial scratch mount failed" echo
@@ -143,17 +144,20 @@ umount $SCRATCH_MNT 2>/dev/null echo echo === copying scratch device to single target -$XFS_COPY_PROG $SCRATCH_DEV $imgs.image | _filter_copy '#' $imgs.image '#' '#' +$XFS_COPY_PROG $SCRATCH_DEV $imgs.image 2> /dev/null \ + | _filter_copy '#' $imgs.image '#' '#' _verify_copy $imgs.image $SCRATCH_DEV $SCRATCH_MNT echo echo === copying scratch device to single target, duplicate UUID -$XFS_COPY_PROG -d $SCRATCH_DEV $imgs.image | _filter_copy '#' $imgs.image '#' '#' +$XFS_COPY_PROG -d $SCRATCH_DEV $imgs.image 2> /dev/null \ + | _filter_copy '#' $imgs.image '#' '#' _verify_copy $imgs.image $SCRATCH_DEV $SCRATCH_MNT echo echo === copying scratch device to single target, large ro device -${MKFS_PROG}.xfs -dfile,name=$imgs.source,size=100g | _filter_mkfs 2>/dev/null +${MKFS_PROG}.xfs -dfile,name=$imgs.source,size=100g 2> /dev/null \ + | _filter_mkfs 2>/dev/null rmdir $imgs.source_dir 2>/dev/null mkdir $imgs.source_dir
@@ -161,7 +165,8 @@ mount -t xfs -o loop $imgs.source $imgs.source_dir loop2=`mount | grep $imgs.source | grep -o -e 'loop=.*[^),]' | grep -o -e '/.*$'` cp -a $here $imgs.source_dir mount -t xfs -o remount,ro $imgs.source $imgs.source_dir -$XFS_COPY_PROG $imgs.source $imgs.image | _filter_copy '#' $imgs.image '#' '#' +$XFS_COPY_PROG $imgs.source $imgs.image 2> /dev/null \ + | _filter_copy '#' $imgs.image '#' '#' _verify_copy $imgs.image $imgs.source $imgs.source_dir # HACK WARNING:
@@ -173,7 +178,7 @@ losetup -d $loop2 > /dev/null 2>&1 echo echo === copying scratch device to multiple targets $XFS_COPY_PROG -L$imgs.log -b $SCRATCH_DEV $imgs.image1 $imgs.image2 \ - | _filter_copy '#' $imgs.image1 '#' $imgs.image2 + 2> /dev/null | _filter_copy '#' $imgs.image1 '#' $imgs.image2 _verify_copy $imgs.image1 $SCRATCH_DEV $SCRATCH_MNT _verify_copy $imgs.image2 $SCRATCH_DEV $SCRATCH_MNT
tests/xfs/092 +1 -1
@@ -50,7 +50,7 @@ _require_scratch _require_no_large_scratch_dev MOUNT_OPTIONS="$MOUNT_OPTIONS -o inode64" -_scratch_mkfs_xfs | _filter_mkfs 2>/dev/null +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>/dev/null || _fail "mkfs failed" echo Silence is golden _scratch_mount
tests/xfs/104 +5 -2
@@ -38,7 +38,8 @@ trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15 _create_scratch() { echo "*** mkfs" - _scratch_mkfs_xfs $@ | tee -a $seqres.full | _filter_mkfs 2>$tmp.mkfs + _scratch_mkfs_xfs $@ 2> /dev/null | tee -a $seqres.full \ + | _filter_mkfs 2>$tmp.mkfs || _fail "mkfs failed" . $tmp.mkfs echo "*** mount"
@@ -71,7 +72,9 @@ _stress_scratch() # real QA test starts here _supported_fs xfs _require_scratch -_scratch_mkfs_xfs | tee -a $seqres.full | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | tee -a $seqres.full \ + | _filter_mkfs 2>$tmp.mkfs || _fail "mkfs failed" + . $tmp.mkfs # extract blocksize and data size for scratch device endsize=`expr 550 \* 1048576` # stop after growing this big
tests/xfs/106 +2 -1
@@ -44,7 +44,8 @@ _require_scratch _require_xfs_quota # real QA test starts here -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" cat $tmp.mkfs >$seqres.full . $tmp.mkfs
tests/xfs/107 +2 -1
@@ -56,7 +56,8 @@ _require_scratch _require_xfs_quota # real QA test starts here -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" cat $tmp.mkfs >$seqres.full . $tmp.mkfs
tests/xfs/108 +2 -1
@@ -83,7 +83,8 @@ _require_prjquota $SCRATCH_DEV # real QA test starts here rm -f $tmp.projects $seqres.full umount $SCRATCH_DEV 2>/dev/null -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" cat $tmp.mkfs >>$seqres.full _scratch_mount
tests/xfs/109 +2 -1
@@ -102,7 +102,8 @@ if [ -n "$FASTSTART" -a -f $SCRATCH_MNT/f0 ]; then fi umount $SCRATCH_DEV -_scratch_mkfs_xfs -dsize=160m,agcount=4 $faststart | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs -dsize=160m,agcount=4 $faststart 2> /dev/null \ + | _filter_mkfs 2>$tmp.mkfs || _fail "mkfs failed" cat $tmp.mkfs >>$seqres.full _scratch_mount
tests/xfs/110 +2 -1
@@ -42,7 +42,8 @@ _require_scratch # real QA test starts here umount $SCRATCH_DEV 2>/dev/null -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ + || _fail "mkfs failed" STR1=AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA STR2=BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
tests/xfs/118 +1 -1
@@ -72,7 +72,7 @@ _chowning_file() } echo "mkfs on scratch" -_scratch_mkfs_xfs >$seqres.full +_scratch_mkfs_xfs >$seqres.full 2> /dev/null || _fail "mkfs failed" echo "mount with quotas" export MOUNT_OPTIONS="-o uquota"
tests/xfs/178 +1 -1
@@ -74,7 +74,7 @@ _supported_os Linux # fix filesystem, new mkfs.xfs will be fine. _require_scratch -_scratch_mkfs_xfs | _filter_mkfs 2>$tmp.mkfs \ +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>$tmp.mkfs \ || _fail "mkfs failed!" # By executing the followint tmp file, will get on the mkfs options stored in
tests/xfs/189 +2 -1
@@ -241,7 +241,8 @@ _require_scratch unset SCRATCH_RTDEV unset SCRATCH_LOGDEV -_scratch_mkfs_xfs | _filter_mkfs 2>/dev/null +_scratch_mkfs_xfs 2> /dev/null | _filter_mkfs 2>/dev/null \ + || _fail "mkfs failed" _add_scratch_fstab _test_remount_rw
tests/xfs/244 +4 -2
@@ -52,7 +52,8 @@ _require_projid32bit export MOUNT_OPTIONS="-opquota" # make fs with no projid32bit -_scratch_mkfs_xfs -i projid32bit=0 >> $seqres.full || _fail "mkfs failed" +_scratch_mkfs_xfs -i projid32bit=0 2> /dev/null >> $seqres.full \ + || _fail "mkfs failed" _qmount # make sure project quota is supported _require_prjquota ${SCRATCH_DEV}
@@ -96,7 +97,8 @@ fi # Do testing on filesystem with projid32bit feature enabled umount $SCRATCH_DEV 2>/dev/null -_scratch_mkfs_xfs -i projid32bit=1 >> $seqres.full || _fail "mkfs failed" +_scratch_mkfs_xfs -i projid32bit=1 >> $seqres.full 2> /dev/null \ + || _fail "mkfs failed" _qmount mkdir $dir
tests/xfs/287 +2 -2
@@ -58,8 +58,8 @@ _require_scratch _require_projid32bit # create xfs fs without projid32bit ability, will be gained by xfs_admin -_scratch_mkfs_xfs -i projid32bit=0 -d size=200m >> $seqres.full \ - || _fail "mkfs failed" +_scratch_mkfs_xfs -i projid32bit=0 -d size=200m 2> /dev/null >> $seqres.full \ + || _fail "mkfs failed" _qmount_option "pquota" _qmount # require project quotas
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
PATCH 3/6 xfstests: xfs/253 doesn't use seqres correctly
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
It was missed when converting all the tests as it was using ${seq}.full and none of the regexes matched it. Fix it up to direct the output to the correct place.
--- tests/xfs/253 | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-)
tests/xfs/253 +8 -6
@@ -71,6 +71,8 @@ function create_file() { echo "Disciplyne of silence is goed." +rm -f $seqres.full + _scratch_mkfs >/dev/null 2>&1 _scratch_mount
@@ -162,11 +164,11 @@ mv "${TEMP_ORPHAN}" "${ORPHAN}" touch "${NON_ORPHAN}" # Get a listing of all the files before obfuscation -ls -R >> "${seq}.full" -ls -R | od -c >> "${seq}.full" +ls -R >> $seqres.full +ls -R | od -c >> $seqres.full # Now unmount the filesystem and create a metadump file -cd /; sync; sync # Old school +cd $here _scratch_unmount
@@ -178,9 +180,9 @@ xfs_mdrestore "${METADUMP_FILE}" "${SCRATCH_DEV}" _scratch_mount # Get a listing of all the files after obfuscation -cd "${SCRATCH_MNT}" -ls -R >> "${seq}.full" -ls -R | od -c >> "${seq}.full" +cd ${SCRATCH_MNT} +ls -R >> $seqres.full +ls -R | od -c >> $seqres.full # Finally, re-make the filesystem since to ensure we don't # leave a directory with duplicate entries lying around.
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 3/6] xfstests: xfs/253 doesn't use seqres correctly
Quoted 7 lines · Dave Chinner
From: Dave Chinner <[email protected]>
It was missed when converting all the tests as it was using ${seq}.full and none of the regexes matched it. Fix it up to direct the output to the correct place.
Signed-off-by Dave Chinner <[email protected]>
Applied.
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
PATCH 4/6 xfstests: Make 204 work with different block and inode sizes.
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
Otherwise it fails with ENOSPC on CRC enabled filesystems because ofhte larger inode size.
--- common/filter | 10 +++++++++- tests/generic/204 | 37 ++++++++++++++++++++++++++++++++----- 2 files changed, 41 insertions(+), 6 deletions(-)
common/filter +9 -1
@@ -131,9 +131,17 @@ _filter_date() } # prints filtered output on stdout, values (use eval) on stderr -# +# Non XFS filesystems always return a 4k block size and a 256 byte inode. _filter_mkfs() { + case $FSTYP in + xfs) + ;; + *) + perl -e 'print STDERR "dbsize=4096\nisize=256\n"' + return ;; + esac + set - perl -ne ' if (/^meta-data=([\w,|\/.-]+)\s+isize=(\d+)\s+agcount=(\d+), agsize=(\d+) blks/) {
tests/generic/204 +32 -5
@@ -28,6 +28,12 @@ echo "QA output created by $seq" here=`pwd` tmp=/tmp/$$ status=1 # failure is the default! +trap "_cleanup; exit \$status" 0 1 2 3 15 + +_cleanup() +{ + rm -f $tmp.* +} # get standard environment, filters and checks . ./common/rc
@@ -39,20 +45,41 @@ _supported_os Linux _require_scratch +rm -f $seqres.full + +# get the block size first +_scratch_mkfs 2> /dev/null | _filter_mkfs 2> $tmp.mkfs > /dev/null +. $tmp.mkfs + SIZE=`expr 104 \* 1024 \* 1024` -_scratch_mkfs_sized $SIZE &> /dev/null +_scratch_mkfs_sized $SIZE $dbsize 2> /dev/null \ + | _filter_mkfs 2> $tmp.mkfs > /dev/null _scratch_mount +. $tmp.mkfs + # fix the reserve block pool to a known size so that the enospc calculations -# work out correctly. -_scratch_resvblks 1024 > $seqres.full 2>&1 +# work out correctly. Space usages is based 22500 files and 1024 reserved blocks +# on a 4k block size 256 byte inode size filesystem. +resv_blks=1024 +space=97920000 -for i in `seq 1 22500`; do +# decrease files for inode size. +# 22500 * (256 + 4k) = ~97MB +# files * (isize + bsize) = 97MB +# files = (97920000 / (isize + bsize)) + +files=$((space / (isize + dbsize))) +resv_blks=$((resv_blks * (4096 / dbsize))) + +echo files $files, resvblks $resv_blks >> $seqres.full +_scratch_resvblks $resv_blks >> $seqres.full 2>&1 + +for i in `seq 1 $files`; do echo -n > $SCRATCH_MNT/$i echo XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX > $SCRATCH_MNT/$i done # success, all done echo "*** done" -rm -f $seqres.full status=0
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
PATCH 5/6 xfstests: New _require_* tests for CRC enabled filesystems
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
CRCs always enabled 32 bit project inodes and attr2 formats, hence they cannot be turned off. Add new require rules for the tests that require attr and 16 bit project IDs so these tests are avoided on CRC enabled filesystems.
Also, add a xfs_db write check so that we can avoid tests that are dependent on xfs_db modifying filesystem structures as they will fail on CRC enabled filessystems right now. This is just temporary until full write xfs_db support is available.
--- common/attr | 6 ++++++ common/rc | 26 +++++++++++++++++++++++--- tests/shared/298 | 2 +- tests/xfs/044 | 1 + tests/xfs/045 | 1 + tests/xfs/186 | 2 ++ tests/xfs/187 | 13 +++++++------ tests/xfs/199 | 1 + tests/xfs/244 | 1 + tests/xfs/278 | 2 ++ tests/xfs/287 | 4 +++- tests/xfs/291 | 2 +- 12 files changed, 49 insertions(+), 12 deletions(-)
common/attr +6 -0
@@ -176,6 +176,12 @@ _require_attrs() rm -f $TEST_DIR/syscalltest.out } +_require_attr_v1() +{ + scratch_mkfs_xfs -f -i attr=1 > /dev/null 2>&1 \ + || _notrun "attr v1 not supported" +} + # getfattr -R returns info in readdir order which varies from fs to fs. # This sorts the output by filename _sort_getfattr_output()
common/rc +23 -3
@@ -1074,14 +1074,34 @@ _require_dm_flakey() } # this test requires the projid32bit feature to be available in -# mkfs.xfs -# +# mkfs.xfs. We need to open code the mkfs test because _scratch_mkfs_xfs +# will drop command line mkfs options to ensure that it succeeds, hence +# not actually testing the configuration we desire to be tested for support. _require_projid32bit() { - _scratch_mkfs_xfs -f -i projid32bit=0 >/dev/null 2>&1 \ + _scratch_options mkfs + + $MKFS_XFS_PROG $SCRATCH_OPTIONS $MKFS_OPTIONS \ + -f -i projid32bit=1 $SCRATCH_DEV >/dev/null 2>&1 \ || _notrun "mkfs.xfs doesn't have projid32bit feature" } +_require_projid16bit() +{ + _scratch_options mkfs + + $MKFS_XFS_PROG $SCRATCH_OPTIONS $MKFS_OPTIONS \ + -f -i projid32bit=0 $SCRATCH_DEV >/dev/null 2>&1 \ + || _notrun "16 bit project IDs not supported on $SCRATCH_DEV" +} + +# This test requires xfs_db write support +_require_xfs_db_write() +{ + $XFS_DB_PROG $TEST_DEV > /dev/null 2>&1 \ + || _notrun "xfs_db write support required." +} + # this test requires that external log/realtime devices are not in use # _require_nonexternal()
tests/shared/298 +1 -1
@@ -70,7 +70,7 @@ get_free_sectors() agsize=`xfs_info $loop_mnt | $SED_PROG -n 's/.*agsize=\(.*\) blks.*/\1/p'` # Convert free space (agno, block, length) to (start sector, end sector) $UMOUNT_PROG $loop_mnt - $XFS_DB_PROG -c "freesp -d" $img_file | $SED_PROG '/^.*from/,$d'| \ + $XFS_DB_PROG -r -c "freesp -d" $img_file | $SED_PROG '/^.*from/,$d'| \ $AWK_PROG -v spb=$sectors_per_block -v agsize=$agsize \ '{ print spb * ($1 * agsize + $2), spb * ($1 * agsize + $2 + $3) - 1 }' ;;
tests/xfs/044 +1 -0
@@ -44,6 +44,7 @@ _supported_fs xfs _supported_os Linux _require_logdev +_require_xfs_db_write _filter_logprint() {
tests/xfs/045 +1 -0
@@ -45,6 +45,7 @@ _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write echo "*** get uuid" uuid=`_get_existing_uuid`
tests/xfs/186 +2 -0
@@ -147,6 +147,8 @@ _supported_os Linux _require_scratch _require_attrs +_require_attr_v1 +_require_xfs_db_write rm -f $seqres.full
tests/xfs/187 +7 -6
@@ -58,6 +58,7 @@ _supported_os Linux _require_scratch _require_attrs +_require_attr_v1 rm -f $seqres.full
@@ -87,13 +88,13 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=0 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo "" _scratch_mount -o noattr2 $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version # adding an EA will ensure the ATTR1 flag is turned on echo ""
@@ -102,7 +103,7 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=0 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo ""
@@ -113,7 +114,7 @@ $SETFATTR_PROG -n user.test -v 0xbabe testfile $GETFATTR_PROG testfile cd $here $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "*** 3. test noattr2 mount and lazy sb ***"
@@ -122,7 +123,7 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=1 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo ""
@@ -131,7 +132,7 @@ cd $SCRATCH_MNT touch testfile cd $here $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version # success, all done status=0
tests/xfs/199 +1 -0
@@ -48,6 +48,7 @@ _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write _scratch_mkfs_xfs -l lazy-count=1 >/dev/null 2>&1
tests/xfs/244 +1 -0
@@ -48,6 +48,7 @@ _supported_fs xfs _require_xfs_quota _require_scratch _require_projid32bit +_require_projid16bit export MOUNT_OPTIONS="-opquota"
tests/xfs/278 +2 -0
@@ -46,6 +46,8 @@ _cleanup() _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write + _scratch_mkfs >/dev/null 2>&1 _scratch_mount
tests/xfs/287 +3 -1
@@ -45,7 +45,7 @@ _cleanup() _print_projid() { - $XFS_DB_PROG -c "inode $1" \ + $XFS_DB_PROG -r -c "inode $1" \ -c "print core.projid_lo" \ -c "print core.projid_hi" \ $SCRATCH_DEV
@@ -56,6 +56,8 @@ _supported_fs xfs _require_xfs_quota _require_scratch _require_projid32bit +_require_projid16bit +_require_xfs_db_write # for xfs_admin # create xfs fs without projid32bit ability, will be gained by xfs_admin _scratch_mkfs_xfs -i projid32bit=0 -d size=200m 2> /dev/null >> $seqres.full \
tests/xfs/291 +1 -1
@@ -70,7 +70,7 @@ xfs_io -f -c "pwrite 0 16m" -c "fsync" $SCRATCH_MNT/space_file.large >> $seqres. # Take a look at freespace for any post-mortem on the test _scratch_unmount -xfs_db -c freesp $SCRATCH_DEV >> $seqres.full 2>&1 +xfs_db -r -c freesp $SCRATCH_DEV >> $seqres.full 2>&1 _scratch_mount # Step 2: Make a bunch of (hopefully fragmented) multiblock
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 5/6] xfstests: New _require_* tests for CRC enabled filesystems
Quoted 7 lines · Dave Chinner
From: Dave Chinner <[email protected]>
CRCs always enabled 32 bit project inodes and attr2 formats, hence they cannot be turned off. Add new require rules for the tests that require attr and 16 bit project IDs so these tests are avoided on CRC enabled filesystems.
Quoted 6 lines
Also, add a
xfs_dbwrite check so that we can avoid tests that are dependent onxfs_dbmodifying filesystem structures as they will fail on CRC enabled filessystems right now. This is just temporary until full writexfs_dbsupport is available.Signed-off-by Dave Chinner <[email protected]>
small optimization question below
Quoted 20 lines
--- common/attr | 6 ++++++ common/rc | 26 +++++++++++++++++++++++--- tests/shared/298 | 2 +- tests/xfs/044 | 1 + tests/xfs/045 | 1 + tests/xfs/186 | 2 ++ tests/xfs/187 | 13 +++++++------ tests/xfs/199 | 1 + tests/xfs/244 | 1 + tests/xfs/278 | 2 ++ tests/xfs/287 | 4 +++- tests/xfs/291 | 2 +- 12 files changed, 49 insertions(+), 12 deletions(-)common/attr +0
-0
common/attr _require_attrs() · line 181
Quoted 6 lines
common/attr +3
-0@@ -176,6 +176,12 @@ _require_attrs() rm -f $TEST_DIR/syscalltest.out } +_require_attr_v1() +{ + scratch_mkfs_xfs -f -i attr=1 > /dev/null 2>&1 \
How about adding an "-N" to speed it up if the fs is large?
Quoted 18 lines
common/attr +3
-0+ || _notrun "attr v1 not supported" +} + # getfattr -R returns info in readdir order which varies from fs to fs. # This sorts the output by filename _sort_getfattr_output()common/rc +2
-2@@ -1074,14 +1074,34 @@ _require_dm_flakey() } # this test requires the projid32bit feature to be available in -# mkfs.xfs -# +# mkfs.xfs. We need to open code the mkfs test because _scratch_mkfs_xfs +# will drop command line mkfs options to ensure that it succeeds, hence
common/rc _require_dm_flakey() · line 1087
Quoted 10 lines
common/rc +5
-1+# not actually testing the configuration we desire to be tested for support. _require_projid32bit() { - _scratch_mkfs_xfs -f -i projid32bit=0 >/dev/null 2>&1 \ + _scratch_options mkfs + + $MKFS_XFS_PROG $SCRATCH_OPTIONS $MKFS_OPTIONS \ + -f -i projid32bit=1 $SCRATCH_DEV >/dev/null 2>&1 \ || _notrun "mkfs.xfs doesn't have projid32bit feature" }
Same here?
common/rc _require_dm_flakey() · line 1096
Quoted 8 lines
common/rc +8
-0+_require_projid16bit() +{ + _scratch_options mkfs + + $MKFS_XFS_PROG $SCRATCH_OPTIONS $MKFS_OPTIONS \ + -f -i projid32bit=0 $SCRATCH_DEV >/dev/null 2>&1 \ + || _notrun "16 bit project IDs not supported on $SCRATCH_DEV" +}
and here? Do we want the mkfs as a side effect? (that would seem odd...)
Quoted 190 lines
common/rc +8
-0+ +# This test requires xfs_db write support +_require_xfs_db_write() +{ + $XFS_DB_PROG $TEST_DEV > /dev/null 2>&1 \ + || _notrun "xfs_db write support required." +} + # this test requires that external log/realtime devices are not in use # _require_nonexternal()tests/shared/298 +1
-1@@ -70,7 +70,7 @@ get_free_sectors() agsize=`xfs_info $loop_mnt | $SED_PROG -n 's/.*agsize=\(.*\) blks.*/\1/p'` # Convert free space (agno, block, length) to (start sector, end sector) $UMOUNT_PROG $loop_mnt - $XFS_DB_PROG -c "freesp -d" $img_file | $SED_PROG '/^.*from/,$d'| \ + $XFS_DB_PROG -r -c "freesp -d" $img_file | $SED_PROG '/^.*from/,$d'| \ $AWK_PROG -v spb=$sectors_per_block -v agsize=$agsize \ '{ print spb * ($1 * agsize + $2), spb * ($1 * agsize + $2 + $3) - 1 }' ;;tests/xfs/044 +1
-0@@ -44,6 +44,7 @@ _supported_fs xfs _supported_os Linux _require_logdev +_require_xfs_db_write _filter_logprint() {tests/xfs/045 +1
-0@@ -45,6 +45,7 @@ _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write echo "*** get uuid" uuid=`_get_existing_uuid`tests/xfs/186 +2
-0@@ -147,6 +147,8 @@ _supported_os Linux _require_scratch _require_attrs +_require_attr_v1 +_require_xfs_db_write rm -f $seqres.fulltests/xfs/187 +7
-6@@ -58,6 +58,7 @@ _supported_os Linux _require_scratch _require_attrs +_require_attr_v1 rm -f $seqres.full@@ -87,13 +88,13 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=0 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo "" _scratch_mount -o noattr2 $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version # adding an EA will ensure the ATTR1 flag is turned on echo ""@@ -102,7 +103,7 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=0 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo ""@@ -113,7 +114,7 @@ $SETFATTR_PROG -n user.test -v 0xbabe testfile $GETFATTR_PROG testfile cd $here $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "*** 3. test noattr2 mount and lazy sb ***"@@ -122,7 +123,7 @@ echo "" echo "attr2 fs" echo "" _scratch_mkfs -i attr=2 -l lazy-count=1 >/dev/null 2>&1 -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version echo "" echo "noattr2 fs" echo ""@@ -131,7 +132,7 @@ cd $SCRATCH_MNT touch testfile cd $here $UMOUNT_PROG $SCRATCH_MNT -$XFS_DB_PROG -c version $SCRATCH_DEV 2>&1 | _filter_version +$XFS_DB_PROG -r -c version $SCRATCH_DEV 2>&1 | _filter_version # success, all done status=0tests/xfs/199 +1
-0@@ -48,6 +48,7 @@ _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write _scratch_mkfs_xfs -l lazy-count=1 >/dev/null 2>&1tests/xfs/244 +1
-0@@ -48,6 +48,7 @@ _supported_fs xfs _require_xfs_quota _require_scratch _require_projid32bit +_require_projid16bit export MOUNT_OPTIONS="-opquota"tests/xfs/278 +2
-0@@ -46,6 +46,8 @@ _cleanup() _supported_fs xfs _supported_os Linux _require_scratch +_require_xfs_db_write + _scratch_mkfs >/dev/null 2>&1 _scratch_mounttests/xfs/287 +3
-1@@ -45,7 +45,7 @@ _cleanup() _print_projid() { - $XFS_DB_PROG -c "inode $1" \ + $XFS_DB_PROG -r -c "inode $1" \ -c "print core.projid_lo" \ -c "print core.projid_hi" \ $SCRATCH_DEV@@ -56,6 +56,8 @@ _supported_fs xfs _require_xfs_quota _require_scratch _require_projid32bit +_require_projid16bit +_require_xfs_db_write # for xfs_admin # create xfs fs without projid32bit ability, will be gained by xfs_admin _scratch_mkfs_xfs -i projid32bit=0 -d size=200m 2> /dev/null >> $seqres.full \tests/xfs/291 +0
-0
tests/xfs/291 xfs_io -f -c "pwrite 0 16m" -c "fsync" $SCRATCH_MNT/space_file.large >> $seqres. · line 76
Quoted 8 lines
tests/xfs/291 +1
-1@@ -70,7 +70,7 @@ xfs_io -f -c "pwrite 0 16m" -c "fsync" $SCRATCH_MNT/space_file.large >> $seqres. # Take a look at freespace for any post-mortem on the test _scratch_unmount -xfs_db -c freesp $SCRATCH_DEV >> $seqres.full 2>&1 +xfs_db -r -c freesp $SCRATCH_DEV >> $seqres.full 2>&1 _scratch_mount # Step 2: Make a bunch of (hopefully fragmented) multiblock
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 5/6] xfstests: New _require_* tests for CRC enabled filesystems
Quoted 8 lines · Eric Sandeen
Quoted 7 lines · Dave Chinner
From: Dave Chinner <[email protected]>
CRCs always enabled 32 bit project inodes and attr2 formats, hence they cannot be turned off. Add new require rules for the tests that require attr and 16 bit project IDs so these tests are avoided on CRC enabled filesystems.
Quoted 8 lines
Quoted 6 lines
Also, add a
xfs_dbwrite check so that we can avoid tests that are dependent onxfs_dbmodifying filesystem structures as they will fail on CRC enabled filessystems right now. This is just temporary until full writexfs_dbsupport is available.Signed-off-by Dave Chinner <[email protected]>small optimization question below
Using -N makes sense. I forgot about that option :)
Cheers,
Dave.
Signature · 7 lines
Dave Chinner [email protected] _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
PATCH 6/6 xfstests: add a multithreaded mode to bstat
In reply to Dave ChinnerFrom: Dave Chinner <[email protected]>
For benchmarking of bulkstat, add a multithreaded mode that spawns a thread per AG and runs bulkstat on every AG in parallel. There is a small amount of overlap between each AG because of the way the interface works only on inode numbers, so some inodes are reported twice. A real implementation of this sort of parallelism would be greatly helped by adding an AG parameter to the bulkstat interface.
--- src/Makefile | 2 +- src/bstat.c | 388 +++++++++++++++++++++++++++++++++++++++++++++------------- 2 files changed, 302 insertions(+), 88 deletions(-)
src/Makefile +1 -1
@@ -22,7 +22,7 @@ LINUX_TARGETS = xfsctl bstat t_mtab getdevicesize preallo_rw_pattern_reader \ SUBDIRS = -LLDLIBS = $(LIBATTR) $(LIBHANDLE) $(LIBACL) +LLDLIBS = $(LIBATTR) $(LIBHANDLE) $(LIBACL) -lpthread ifeq ($(HAVE_XLOG_ASSIGN_LSN), true) LINUX_TARGETS += loggen
src/bstat.c +301 -87
443 lines not on this page · raw message
Signature · 6 lines
1.7.10.4 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 6/6] xfstests: add a multithreaded mode to bstat
Quoted 10 lines · Dave Chinner
From: Dave Chinner <[email protected]>
For benchmarking of bulkstat, add a multithreaded mode that spawns a thread per AG and runs bulkstat on every AG in parallel. There is a small amount of overlap between each AG because of the way the interface works only on inode numbers, so some inodes are reported twice. A real implementation of this sort of parallelism would be greatly helped by adding an AG parameter to the bulkstat interface.
Signed-off-by Dave Chinner <[email protected]>
At least w/ older xfsprogs[[qa]-devel] packages, I get:
bstat.c:41: error: redefinition of 'fls'/usr/include/xfs/bitops.h:8: note: previous definition of 'fls' was here bstat.c:70: error: redefinition of 'xfs_highbit32' /usr/include/xfs/xfs_bit.h:50: note: previous definition of 'xfs_highbit32' was here
w/ the new functions you've added here...
-Eric
Quoted 462 lines
--- src/Makefile | 2 +- src/bstat.c | 388 +++++++++++++++++++++++++++++++++++++++++++++------------- 2 files changed, 302 insertions(+), 88 deletions(-)src/Makefile +1
-1@@ -22,7 +22,7 @@ LINUX_TARGETS = xfsctl bstat t_mtab getdevicesize preallo_rw_pattern_reader \ SUBDIRS = -LLDLIBS = $(LIBATTR) $(LIBHANDLE) $(LIBACL) +LLDLIBS = $(LIBATTR) $(LIBHANDLE) $(LIBACL) -lpthread ifeq ($(HAVE_XLOG_ASSIGN_LSN), true) LINUX_TARGETS += loggensrc/bstat.c +300
-81@@ -18,6 +18,60 @@#include "global.h" #include <xfs/jdm.h> +#include <pthread.h> + + +int debug; +int quiet; +int statit; +int verbose; +int threaded; + +unsigned int +libxfs_log2_roundup (unsigned int i) +{ +unsigned int rval; + +for (rval =0 ; rval <NBBY *sizeof (i); rval++) { +if ((1 << rval) >= i) +break ; + } +return rval; +} +static inline int fls (int x) +{ +int r =32 ; + +if (!x) +return 0 ; +if (!(x &0xffff0000u )) { + x <<=16 ; + r -=16 ; + } +if (!(x &0xff000000u )) { + x <<=8 ; + r -=8 ; + } +if (!(x &0xf0000000u )) { + x <<=4 ; + r -=4 ; + } +if (!(x &0xc0000000u )) { + x <<=2 ; + r -=2 ; + } +if (!(x &0x80000000u )) { + x <<=1 ; + r -=1 ; + } +return r; +} + +static inline int xfs_highbit32 (__uint32_t v) +{ +return fls (v) -1 ; +} +void dotime (void *ti,char *s)@@ -62,87 +116,21 @@ printstat(struct stat64 *sp)dotime (&sp->st_ctime,"ctime" ); } -int -main (int argc,char **argv) +static int +do_bstat ( +int fsfd, +jdm_fshandle_t *fshandlep, +char *name, +int nent, +__u64 first, +__u64 last) {__s32 count;int total =0 ; -int fsfd; -int i; -__u64 last =0 ; -char *name; -int nent; -int debug =0 ; -int quiet =0 ; -int statit =0 ; -int verbose =0 ;xfs_bstat_t *t;int ret; -jdm_fshandle_t *fshandlep =NULL ; -int fd; -struct stat64 sb; -int nread; -char *cc_readlinkbufp; -int cc_readlinkbufsz; -int c;xfs_fsop_bulkreq_t bulkreq; - -while ((c =getopt (argc, argv,"cdl:qv" )) !=-1 ) { -switch (c) { -case 'q' : - quiet =1 ; -break ; -case 'v' : - verbose =1 ; -break ; -case 'c' : - statit =1 ; -break ; -case 'd' : - debug =1 ; -break ; -case 'l' : - last =atoi (optarg); -break ; -case '?' : -printf ("usage: xfs_bstat [-c] [-q] [-v] [ dir [ batch_size ]]\n" ); -printf (" -c Check the results against stat(3) output\n" ); -printf (" -q Quiet\n" ); -printf (" -l _num_ Inode to start with\n" ); -printf (" -v Verbose output\n" ); -exit (1 ); - } - } - argc -= optind; - argv += optind; - -if (argc <1 ) - name ="." ; -else - name = *argv; - - fsfd =open (name,O_RDONLY ); -if (fsfd <0 ) { -perror (name); -exit (1 ); - } -if (argc <2 ) - nent =4096 ; -else - nent =atoi (*++argv); - -if (verbose) -printf ("Bulkstat test on %s, batch size=%d statcheck=%d\n" , - name, nent, statit); - -if (statit) { - fshandlep =jdm_getfshandle ( name ); -if (! fshandlep) { -printf ("unable to construct sys handle for %s: %s\n" , - name,strerror (errno)); -return -1 ; - } - } +__u64 ino; t =malloc (nent *sizeof (*t));@@ -150,23 +138,27 @@ main(int argc, char **argv)printf ("XFS_IOC_FSBULKSTAT test: last=%lld nent=%d\n" , (long long )last, nent); - bulkreq.lastip = &last; + ino = first; + + bulkreq.lastip = &ino; bulkreq.icount = nent; bulkreq.ubuffer = t; bulkreq.ocount = &count;while ((ret =xfsctl (name, fsfd,XFS_IOC_FSBULKSTAT , &bulkreq)) ==0 ) { +int i; + total += count;if (verbose)printf ( -"XFS_IOC_FSBULKSTAT test: last=%lld ret=%d count=%d total=%d\n" , - (long long )last, ret, count, total); +"XFS_IOC_FSBULKSTAT test: first/last/ino=%lld/%lld/%lld ret=%d count=%d total=%d\n" , + (long long )first, (long long )last, (long long )ino, ret, count, total);if (count ==0 ) -exit (0 ); +break ;if ( quiet && ! statit ) -continue ; + goto next;for (i =0 ; i < count; i++) {if (! quiet) {@@ -174,6 +166,12 @@ main(int argc, char **argv) }if (statit) { +char *cc_readlinkbufp; +int cc_readlinkbufsz; +struct stat64 sb; +int nread; +int fd; +switch (t[i].bs_mode &S_IFMT ) {case S_IFLNK : cc_readlinkbufsz =MAXPATHLEN ;@@ -244,10 +242,231 @@ main(int argc, char **argv) } } } - +next:if (debug)break ; + +if (ino >= last) +break ; } +if (verbose) +printf ( +"XFS_IOC_FSBULKSTAT test: last=%lld nent=%d ret=%d count=%d\n" , + (long long )last, nent, ret, count); + +return total; +} + +struct thread_args { +pthread_t tid; +int fsfd; +jdm_fshandle_t *fshandlep; +char *name; +int nent; +__u64 first; +__u64 last; +int ret; +}; + +static void * +do_bstat_thread ( +void *args) +{ +struct thread_args *targs = args; + + targs->ret =do_bstat (targs->fsfd, targs->fshandlep, targs->name, + targs->nent, targs->first, targs->last); +return NULL ; +} + +/* +* XFS_AGINO_TO_INO(mp,a,i) \ +* (((xfs_ino_t)(a) << XFS_INO_AGINO_BITS(mp)) | (i)) +* +* i always zero, so: +* a << XFS_INO_AGINO_BITS(mp) +* +* XFS_INO_AGINO_BITS(mp) (mp)->m_agino_log +* +* mp->m_agino_log = sbp->sb_inopblog + sbp->sb_agblklog +* +* sb_inopblog = fsgeom.blocksize / fsgeom.inodesize +* sb_agblklog = (__uint8_t)libxfs_log2_roundup((unsigned int)fsgeom.agblocks); +* +* a << (libxfs_highbit32(fsgeom.blocksize /fsgeom.inodesize) + +* libxfs_log2_roundup(fsgeom.agblocks)); +*/ +#define FSGEOM_INOPBLOG (fsg) \ + (xfs_highbit32((fsg).blocksize / (fsg).inodesize)) +#define FSGEOM_AGINO_TO_INO (fsg, a, i) \ + (((__u64)(a) << (FSGEOM_INOPBLOG(fsg) + \ + libxfs_log2_roundup((fsg).agblocks))) | (i)) + +/* +* XFS_OFFBNO_TO_AGINO(mp,b,o) \ +* ((xfs_agino_t)(((b) << XFS_INO_OFFSET_BITS(mp)) | (o))) +* +* i always zero, so: +* b << XFS_INO_OFFSET_BITS(mp) +* +* XFS_INO_OFFSET_BITS(mp) (mp)->m_sb.sb_inopblog +*/ +#define FSGEOM_OFFBNO_TO_AGINO (fsg, b, o) \ + ((__u32)(((b) << FSGEOM_INOPBLOG(fsg)) | (o))) +static int +do_threads ( +int fsfd, +jdm_fshandle_t *fshandlep, +char *name, +int nent, +__u64 first) +{ +struct xfs_fsop_geom geom; +struct thread_args *targs; +int ret; +int i; +int numthreads; +int total =0 ; + + +/* get number of AGs */ + ret =ioctl (fsfd,XFS_IOC_FSGEOMETRY , &geom); +if (ret) { +perror ("XFS_IOC_FSGEOMETRY" ); +exit (1 ); + } + +/* allocate thread array */ + targs =malloc (geom.agcount *sizeof (*targs)); +if (ret) { +perror ("malloc(targs)" ); +exit (1 ); + } + +for (i =0 ; i < geom.agcount; i++) { +__u64 last; + + last =FSGEOM_AGINO_TO_INO (geom, i, +FSGEOM_OFFBNO_TO_AGINO (geom, + geom.agblocks -1 ,0 )); + +if (first > last) { + i--; +continue ; + } + first =MAX (first,FSGEOM_AGINO_TO_INO (geom, i,0 )); + + targs[i].fsfd = fsfd; + targs[i].fshandlep = fshandlep; + targs[i].name = name; + targs[i].nent = nent; + targs[i].first = first; + targs[i].last = last; + targs[i].ret =0 ; + } + numthreads = i; + +/* start threads */ +for (i =0 ; i< numthreads; i++) { + ret =pthread_create (&targs[i].tid,NULL , do_bstat_thread, &targs[i]); +if (ret) { +perror ("pthread-create" ); +exit (1 ); + } + } + + +/* join threads */ +for (i =0 ; i < numthreads; i++) { +if (targs[i].tid) { +pthread_join (targs[i].tid,NULL ); + total += targs[i].ret; + } + } + +/* die */ +return total; +} + + +int +main (int argc,char **argv) +{ +int fsfd; +__u64 first =0 ; +char *name; +int nent; +int ret; +jdm_fshandle_t *fshandlep =NULL ; +int c; + +while ((c =getopt (argc, argv,"cdl:qtv" )) !=-1 ) { +switch (c) { +case 'q' : + quiet =1 ; +break ; +case 'v' : + verbose =1 ; +break ; +case 'c' : + statit =1 ; +break ; +case 'd' : + debug =1 ; +break ; +case 'l' : + first =atoi (optarg); +break ; +case 't' : + threaded =1 ; +break ; +case '?' : +printf ("usage: xfs_bstat [-c] [-q] [-v] [ dir [ batch_size ]]\n" ); +printf (" -c Check the results against stat(3) output\n" ); +printf (" -q Quiet\n" ); +printf (" -l _num_ Inode to start with\n" ); +printf (" -v Verbose output\n" ); +exit (1 ); + } + } + argc -= optind; + argv += optind; + +if (argc <1 ) + name ="." ; +else + name = *argv; + + fsfd =open (name,O_RDONLY ); +if (fsfd <0 ) { +perror (name); +exit (1 ); + } +if (argc <2 ) + nent =4096 ; +else + nent =atoi (*++argv); + +if (verbose) +printf ("Bulkstat test on %s, batch size=%d statcheck=%d\n" , + name, nent, statit); + +if (statit) { + fshandlep =jdm_getfshandle ( name ); +if (! fshandlep) { +printf ("unable to construct sys handle for %s: %s\n" , + name,strerror (errno)); +return -1 ; + } + } + +if (threaded) + ret =do_threads (fsfd, fshandlep, name, nent, first); +else + ret =do_bstat (fsfd, fshandlep, name, nent, first,-1LL ); + +if (verbose) +printf ("Bulkstat found %d inodes\n" , ret);if (fsfd)close (fsfd);@@ -255,10 +474,5 @@ main(int argc, char **argv)if (ret <0 )
src/bstat.c main(int argc, char **argv) · line 478
Quoted 10 lines
src/bstat.c +1
-6perror ("xfsctl(XFS_IOC_FSBULKSTAT)" ); -if (verbose) -printf ( -"XFS_IOC_FSBULKSTAT test: last=%lld nent=%d ret=%d count=%d\n" , - (long long )last, nent, ret, count); - -return 1 ; +return 0 ; }
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 6/6] xfstests: add a multithreaded mode to bstat
Quoted 12 lines · Eric Sandeen
Quoted 10 lines · Dave Chinner
From: Dave Chinner <[email protected]>
For benchmarking of bulkstat, add a multithreaded mode that spawns a thread per AG and runs bulkstat on every AG in parallel. There is a small amount of overlap between each AG because of the way the interface works only on inode numbers, so some inodes are reported twice. A real implementation of this sort of parallelism would be greatly helped by adding an AG parameter to the bulkstat interface.
Signed-off-by Dave Chinner <[email protected]>
Quoted 8 lines
At least w/ older xfsprogs[[qa]-devel] packages, I get:
bstat.c:41: error: redefinition of 'fls'
/usr/include/xfs/bitops.h:8: note: previous definition of 'fls' was here bstat.c:70: error: redefinition of 'xfs_highbit32'/usr/include/xfs/xfs_bit.h:50: note: previous definition of 'xfs_highbit32' was herew/ the new functions you've added here...
Ok, so I need autoconf magic here to detect this?
Cheers,
Dave.
Signature · 7 lines
Dave Chinner [email protected] _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 6/6] xfstests: add a multithreaded mode to bstat
Quoted 15 lines · Dave Chinner
Quoted 14 lines · Eric Sandeen
Quoted 10 lines · Dave Chinner
From: Dave Chinner <[email protected]>
For benchmarking of bulkstat, add a multithreaded mode that spawns a thread per AG and runs bulkstat on every AG in parallel. There is a small amount of overlap between each AG because of the way the interface works only on inode numbers, so some inodes are reported twice. A real implementation of this sort of parallelism would be greatly helped by adding an AG parameter to the bulkstat interface.
Signed-off-by Dave Chinner <[email protected]>At least w/ older xfsprogs[[qa]-devel] packages, I get:
Quoted 8 lines
Quoted 6 lines
bstat.c:41: error: redefinition of 'fls'
/usr/include/xfs/bitops.h:8: note: previous definition of 'fls' was here bstat.c:70: error: redefinition of 'xfs_highbit32'/usr/include/xfs/xfs_bit.h:50: note: previous definition of 'xfs_highbit32' was herew/ the new functions you've added here...
Ok, so I need autoconf magic here to detect this?
seems that way. TBH I don't *cough* have a box w/ latests xfsprogs headers installed currently, so didn't see exactly what changed...
-Eric
Quoted 4 lines
Cheers,
Dave.
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs