Whamcloud - gitweb
EX-9875 test: limit dir restripe overstripe count
authorLai Siyao <lai.siyao@whamcloud.com>
Sun, 19 May 2024 00:38:33 +0000 (20:38 -0400)
committerAndreas Dilger <adilger@whamcloud.com>
Tue, 11 Jun 2024 06:59:41 +0000 (06:59 +0000)
Lack of LU-15527 code, the distributed transactions are slow. To
avoid test timeout, limit overstripe count and increase timeout for
sanity test_300ud and test_300ue.

Test-Parameters: trivial
Test-Parameters: mdtcount=4 testlist=sanity env=ONLY="300ud 300ue"
Test-Parameters: mdtcount=4 testlist=sanity env=ONLY="300ud 300ue"
Test-Parameters: mdtcount=4 testlist=sanity env=ONLY="300ud 300ue"
Test-Parameters: mdtcount=4 testlist=sanity env=ONLY="300ud 300ue"
Test-Parameters: mdtcount=4 testlist=sanity env=ONLY="300ud 300ue"
Signed-off-by: Lai Siyao <lai.siyao@whamcloud.com>
Change-Id: I830ac27e446f3841147be4777ba06cdb8e1a7f59
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/55347
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
lustre/tests/sanity.sh

index 7bdbc4e..6c0cf1a 100644 (file)
@@ -25270,7 +25270,7 @@ test_300ud() {
        stack_trap "do_nodes $mdts $LCTL set_param \
                    mdt.*.enable_dir_restripe=$restripe_status"
 
-       mkdir $DIR/$tdir
+       test_mkdir -c $MDSCOUNT -H crush $DIR/$tdir
        createmany -m $DIR/$tdir/f $((50 * MDSCOUNT)) ||
                error "create files under remote dir failed $i"
        createmany -d $DIR/$tdir/d $((50 * MDSCOUNT)) ||
@@ -25279,7 +25279,12 @@ test_300ud() {
        local setcount=$((MDSCOUNT * $LMV_MAX_STRIPES_PER_MDT))
 
        (( setcount < 13 )) || setcount=12
-       for i in $(seq 2 $setcount); do
+       # lack of LU-15527, distributed txns are slow on lower versions
+       if (( MDS1_VERSION < $(version_code 2.15.0) )); then
+               setcount=$((MDSCOUNT + 1))
+               timeout=300
+       fi
+       for i in $(seq $((MDSCOUNT + 1)) $setcount); do
                do_nodes $mdts "$LCTL set_param mdt.*.md_stats=clear >/dev/null"
                $LFS setdirstripe -C $i $DIR/$tdir ||
                        error "split -C $i $tdir failed"
@@ -25321,13 +25326,18 @@ test_300ue() {
        local setcount=$((MDSCOUNT * $LMV_MAX_STRIPES_PER_MDT))
 
        (( setcount < 13 )) || setcount=12
+       # lack of LU-15527, distributed txns are slow on lower versions
+       if (( MDS1_VERSION < $(version_code 2.15.0) )); then
+               setcount=$((MDSCOUNT + 1))
+               timeout=300
+       fi
        test_mkdir -C $setcount -H crush $DIR/$tdir
        createmany -m $DIR/$tdir/f $((50 * MDSCOUNT)) ||
                error "create files under remote dir failed"
        createmany -d $DIR/$tdir/d $((50 * MDSCOUNT)) ||
                error "create dirs under remote dir failed"
 
-       for c in $(seq $((setcount - 1)) -1 1); do
+       for c in $(seq $((setcount - 1)) -1 $MDSCOUNT); do
                do_nodes $mdts "$LCTL set_param mdt.*.md_stats=clear >/dev/null"
                $LFS setdirstripe -C $c $DIR/$tdir ||
                        error "split -C $c $tdir failed"