Whamcloud - gitweb
LU-10786 tests: add stripe size to lfs setstripe 69/31569/3
authorJames Nunez <james.a.nunez@intel.com>
Wed, 7 Mar 2018 16:27:59 +0000 (09:27 -0700)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 7 Mar 2018 18:54:26 +0000 (18:54 +0000)
Since the default stripe size increased from one to four
MB, we need to add the stripe size parameter to calls
to 'lfs setstripe' for composite files when the component
size is less than the file system stripe size. Thus, add
the stripe size parameter to calls to 'lfs setstripe' for
sanity-flr tests 45 and 46 and sanity-pfl test 16.

Test-Parameters: trivial testlist=sanity-flr,sanity-pfl

Signed-off-by: James Nunez <james.a.nunez@intel.com>
Change-Id: Ic169eaebd922175467f010b159a2b065fb91b3fb
Reviewed-on: https://review.whamcloud.com/31569
Reviewed-by: Jian Yu <jian.yu@intel.com>
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/sanity-flr.sh
lustre/tests/sanity-pfl.sh

index 19e2b9b..f5faf02 100644 (file)
@@ -1782,8 +1782,9 @@ test_45() {
        rm -rf $DIR/$tdir
        test_mkdir $DIR/$tdir
 
-       $LFS setstripe -N -E1m -c2 -o0,1 -E2m -Eeof -N -E4m -Eeof \
-               -N -E3m -Eeof -N -E8m -Eeof $file || error "Create $file failed"
+       $LFS setstripe -N -E1m -S1m -c2 -o0,1 -E2m -Eeof -N -E4m -Eeof \
+               -N -E3m -S1m -Eeof -N -E8m -Eeof $file ||
+                       error "Create $file failed"
 
        echo "getstripe --yaml $file"
        $LFS getstripe --yaml $file > $temp || error "getstripe $file failed"
@@ -1821,8 +1822,8 @@ test_46() {
        ########################### 1. PFL file #############################
        echo "  ** 1. PFL file"
        rm -f $file
-       $LFS setstripe -E1m -c2 -o0,1 -E2m -c2 -E3m -o1,0 -E4m -c1 -E-1 $file ||
-               error "1. Create PFL $file failed"
+       $LFS setstripe -E1m -S 1M -c2 -o0,1 -E2m -c2 -E3m -o1,0 -E4m -c1 -E-1 \
+               $file || error "1. Create PFL $file failed"
 
        rm -f $file.copy
        verify_46 $file $file.copy "1. PFL file"
@@ -1838,9 +1839,8 @@ test_46() {
 
        ########################### 3. FLR file #############################
        echo "  ** 3. FLR file"
-       rm -f $file
-       $LFS setstripe -N -E1m -c2 -o0,1 -E4m -c1 -Eeof -N -E16m -Eeof $file ||
-               error "3. Create FLR $file failed"
+       $LFS setstripe -N -E1m -S 1M -c2 -o0,1 -E4m -c1 -Eeof -N -E16m -Eeof \
+               $file || error "3. Create FLR $file failed"
 
        rm -f $file.copy
        verify_46 $file $file.copy "3. FLR file"
@@ -1849,21 +1849,21 @@ test_46() {
        ########################### 4. PFL dir ##############################
        echo "  ** 4. PFL dir"
        test_mkdir $dir
-       $LFS setstripe -E1m -c2 -E2m -c1 -E-1 $dir ||
+       $LFS setstripe -E1m -S 1M -c2 -E2m -c1 -E-1 $dir ||
                error "4. setstripe PFL $dir failed"
 
        test_mkdir $dir.copy
-       verify_46 $dir $dir.copy "3. PFL dir"
+       verify_46 $dir $dir.copy "4. PFL dir"
 
        ########################### 5. plain dir ############################
        echo "  ** 5. plain dir"
-       $LFS setstripe -c2 -i-1 $dir || error "4. setstripe plain $dir failed"
+       $LFS setstripe -c2 -i-1 $dir || error "5. setstripe plain $dir failed"
 
        verify_46 $dir $dir.copy "5. plain dir"
 
        ########################### 6. FLR dir ##############################
        echo "  ** 6. FLR dir"
-       $LFS setstripe -N -E1m -c2 -E2m -c1 -Eeof -N -E4m -Eeof $dir ||
+       $LFS setstripe -N -E1m -S 1M -c2 -E2m -c1 -Eeof -N -E4m -Eeof $dir ||
                error "6. setstripe FLR $dir failed"
 
        verify_46 $dir $dir.copy "6. FLR dir"
index 8cc5226..b652210 100644 (file)
@@ -670,8 +670,8 @@ test_16() {
        #####################################################################
        #                           1. PFL file
        # set stripe for source file
-       $LFS setstripe -E1m -c2 -o0,1 -E2m -c2 -E3m -o1,0 -E4m -c1 -E-1 $file ||
-               error "Create $file failed"
+       $LFS setstripe -E1m -S 1M -c2 -o0,1 -E2m -c2 -E3m -o1,0 -E4m -c1 -E-1 \
+               $file || error "Create $file failed"
 
        echo "1. PFL file"
        verify_16 $file $file.copy $temp "1. PFL file"
@@ -690,7 +690,7 @@ test_16() {
        #                           3. PFL dir
        # set stripe for source dir
        test_mkdir $dir
-       $LFS setstripe -E1m -c2 -E2m -c1 -E-1 $dir ||
+       $LFS setstripe -E1m -S 1M -c2 -E2m -c1 -E-1 $dir ||
                error "setstripe $dir failed"
 
        test_mkdir $dir.copy