Whamcloud - gitweb
LU-16904 tests: Fix sanity test 56a and 65a when PFL layout is used
[fs/lustre-release.git] / lustre / tests / sanity.sh
index 9b64b2b..c035a66 100755 (executable)
@@ -6529,7 +6529,7 @@ test_56a() {
 
        #test lfs getstripe with -v prints lmm_fid
        filenum=$($LFS getstripe -v $dir | grep -c lmm_fid)
-       local countfids=$((numdirs + numfiles * numcomp))
+       local countfids=$(((numdirs + numfiles) * numcomp))
        [[ $filenum -eq $countfids ]] ||
                error "$LFS getstripe -v $dir: "\
                      "got $filenum want $countfids lmm_fid"
@@ -10033,6 +10033,10 @@ run_test 64i "shrink on reconnect"
 test_65a() {
        [ $PARALLEL == "yes" ] && skip "skip parallel run"
 
+       # LU-16904 check if the root is set as PFL layout
+       local numcomp=$($LFS getstripe --component-count $MOUNT)
+       [ $numcomp -eq 0 ] || skip "Skip test_65a for PFL layout"
+
        test_mkdir $DIR/$tdir
        touch $DIR/$tdir/f1
        $LVERIFY $DIR/$tdir $DIR/$tdir/f1 || error "lverify failed"