From: Alexander Boyko Date: Thu, 7 Jun 2018 13:54:41 +0000 (-0400) Subject: LU-10893 tests: allow to disable dm-flakey layer X-Git-Tag: 2.11.53~25 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=f4618338643441970131f957f2a346ae3a455197;ds=sidebyside LU-10893 tests: allow to disable dm-flakey layer The patch 54b9e3f789358bd9dfb94b77fe33a4faa1e28ab2 adds flakey layer to test framework. But it also adds a regression, you can`t run tests separately from a setup. Before the dm-flakey, it was easy to create a configuration at ncli, setup a cluster, and start a test. But now it is impossible. For example sudo MDSDEV=/dev/sdb MDSDEV1=/dev/sdb sh lustre/tests/llmount.sh sudo MDSDEV=/dev/sdb MDSDEV1=/dev/sdb ONLY=0 sh lustre/tests/conf-sanity.sh Format mds1: /dev/sdb mkfs.lustre FATAL: Unable to build fs /dev/sdb (256) mkfs.lustre FATAL: mkfs failed 256 The fix disables dm-flakey layer with option FLAKEY=false. Test-Parameters: envdefinitions=FLAKEY=false Signed-off-by: Alexander Boyko Cray-bug-id: LUS-5851 Change-Id: I248be2307cff5fe6b4b2524478ca8e4cd96a77d2 Reviewed-on: https://review.whamcloud.com/32658 Reviewed-by: Elena Gryaznova Reviewed-by: Andreas Dilger Tested-by: Jenkins Reviewed-by: James Simmons Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh index 834d243..73994c5 100755 --- a/lustre/tests/test-framework.sh +++ b/lustre/tests/test-framework.sh @@ -24,6 +24,7 @@ export SK_S2SNM=${SK_S2SNM:-TestFrameNM} export SK_S2SNMCLI=${SK_S2SNMCLI:-TestFrameNMCli} export IDENTITY_UPCALL=default export QUOTA_AUTO=1 +export FLAKEY=${FLAKEY:-true} # specify environment variable containing batch job name for server statistics export JOBID_VAR=${JOBID_VAR:-"procname_uid"} # or "existing" or "disable" @@ -1582,6 +1583,7 @@ is_dm_flakey_dev() { dm_flakey_supported() { local facet=$1 + $FLAKEY || return 1 do_facet $facet "modprobe dm-flakey; $DMSETUP targets | grep -q flakey" &> /dev/null }