From: Andreas Dilger Date: Fri, 3 Apr 2020 00:54:11 +0000 (-0600) Subject: LU-13321 tests: force even DNE file distribution X-Git-Tag: 2.13.53~4 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=489afbe69d5b;p=fs%2Flustre-release.git LU-13321 tests: force even DNE file distribution Force even file creation across DNE-striped directories in sanity test_160f to avoid random test failures (about 15%) when no files are created on a specific MDT. Fixes: 0a1cf8da8069 ("LU-11025 dne: introduce new directory hash type: 'crush'") Test-Parameters: trivial testlist=sanity env=ONLY=160f,ONLY_REPEAT=50 Signed-off-by: Andreas Dilger Change-Id: I8bead0c20efeda90b9b89f933a022cc18e3ebbe5 Reviewed-on: https://review.whamcloud.com/38129 Tested-by: jenkins Reviewed-by: Lai Siyao Tested-by: Maloo Reviewed-by: James Nunez Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/sanity.sh b/lustre/tests/sanity.sh index 55a68843..3ff0118 100755 --- a/lustre/tests/sanity.sh +++ b/lustre/tests/sanity.sh @@ -13992,7 +13992,9 @@ test_160f() { local i # generate some changelog records to accumulate on each MDT - test_mkdir -c $MDSCOUNT $DIR/$tdir || error "test_mkdir $tdir failed" + # use fnv1a because created files should be evenly distributed + test_mkdir -c $MDSCOUNT -H fnv_1a_64 $DIR/$tdir || + error "test_mkdir $tdir failed" log "$(date +%s): creating first files" createmany -m $DIR/$tdir/$tfile $((MDSCOUNT * 2)) || error "create $DIR/$tdir/$tfile failed" @@ -14118,6 +14120,7 @@ test_160g() { local i # generate some changelog records to accumulate on each MDT + # use fnv1a because created files should be evenly distributed test_mkdir -c $MDSCOUNT -H fnv_1a_64 $DIR/$tdir || error "mkdir $tdir failed" createmany -m $DIR/$tdir/$tfile $((MDSCOUNT * 2)) || @@ -14233,6 +14236,7 @@ test_160h() { local i # generate some changelog records to accumulate on each MDT + # use fnv1a because created files should be evenly distributed test_mkdir -c $MDSCOUNT -H fnv_1a_64 $DIR/$tdir || error "test_mkdir $tdir failed" createmany -m $DIR/$tdir/$tfile $((MDSCOUNT * 2)) || @@ -14383,6 +14387,7 @@ test_160i() { changelog_register || error "first changelog_register failed" # generate some changelog records to accumulate on each MDT + # use fnv1a because created files should be evenly distributed test_mkdir -c $MDSCOUNT -H fnv_1a_64 $DIR/$tdir || error "mkdir $tdir failed" createmany -m $DIR/$tdir/$tfile $((MDSCOUNT * 2)) || @@ -14449,7 +14454,9 @@ test_160j() { stack_trap "changelog_deregister" EXIT # generate some changelog - test_mkdir -c $MDSCOUNT $DIR/$tdir || error "mkdir $tdir failed" + # use fnv1a because created files should be evenly distributed + test_mkdir -c $MDSCOUNT -H fnv_1a_64 $DIR/$tdir || + error "mkdir $tdir failed" createmany -m $DIR/$tdir/${tfile}bis $((MDSCOUNT * 2)) || error "create $DIR/$tdir/${tfile}bis failed" @@ -14472,7 +14479,6 @@ test_160j() { error "User $cl_user not found in changelog_users" printf 'clear:'$cl_user':0' >&3 - } run_test 160j "client can be umounted while its chanangelog is being used"