Whamcloud - gitweb
LU-2192 tests: enable large xattr testing on zfs
authorYu Jian <yujian@whamcloud.com>
Thu, 8 Nov 2012 04:16:14 +0000 (12:16 +0800)
committerOleg Drokin <green@whamcloud.com>
Tue, 13 Nov 2012 14:21:15 +0000 (09:21 -0500)
Since zfs supports large xattr by default and dumpe2fs does not
work on zfs, we need improve large_xattr_enabled() to check the
backend fs type on MDS.

Test-Parameters:mdsfilesystemtype=zfs mdtfilesystemtype=zfs ostfilesystemtype=zfs testlist=sanity,conf-sanity,replay-single,lustre-rsync-test
Signed-off-by: Yu Jian <yujian@whamcloud.com>
Change-Id: I27bdad38d8a40e3858d96ee29f44a6abb5365fef
Reviewed-on: http://review.whamcloud.com/4493
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Li Wei <wei.g.li@intel.com>
lustre/tests/test-framework.sh

index f4f5838..7baca91 100644 (file)
@@ -5683,10 +5683,12 @@ get_block_size() {
 
 # Check whether the "large_xattr" feature is enabled or not.
 large_xattr_enabled() {
 
 # Check whether the "large_xattr" feature is enabled or not.
 large_xattr_enabled() {
-    local mds_dev=$(mdsdevname ${SINGLEMDS//mds/})
+       [[ $(facet_fstype $SINGLEMDS) == zfs ]] && return 0
 
 
-    do_facet $SINGLEMDS "$DUMPE2FS -h $mds_dev 2>&1 | grep -q large_xattr"
-    return ${PIPESTATUS[0]}
+       local mds_dev=$(mdsdevname ${SINGLEMDS//mds/})
+
+       do_facet $SINGLEMDS "$DUMPE2FS -h $mds_dev 2>&1 | grep -q large_xattr"
+       return ${PIPESTATUS[0]}
 }
 
 # Get the maximum xattr size supported by the filesystem.
 }
 
 # Get the maximum xattr size supported by the filesystem.