From: Sebastien Buisson Date: Wed, 10 May 2023 12:13:54 +0000 (+0200) Subject: LU-16804 tests: load CONFIG at beginning of init_test_env X-Git-Tag: 2.15.56~38 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=fdbb2bc8495064e1d9e61f02bcfd13b1e6aec8da;p=fs%2Flustre-release.git LU-16804 tests: load CONFIG at beginning of init_test_env In order to have all environment variables properly loaded, make CONFIG loaded at the beginning of init_test_env(). Signed-off-by: Sebastien Buisson Change-Id: I1c3caa3d582c4b317ff3d0d10fc0103e046ddf17 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/50914 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Sarah Liu Reviewed-by: Andreas Dilger Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/test-framework.sh b/lustre/tests/test-framework.sh index ceefa3f..1f92dc2 100755 --- a/lustre/tests/test-framework.sh +++ b/lustre/tests/test-framework.sh @@ -187,6 +187,9 @@ init_test_env() { export KEEP_ZPOOL=${KEEP_ZPOOL:-false} export CLEANUP_DM_DEV=false export PAGE_SIZE=$(get_page_size client) + export NAME=${NAME:-local} + + . ${CONFIG:=$LUSTRE/tests/cfg/$NAME.sh} export MKE2FS=$MKE2FS if [ -z "$MKE2FS" ]; then @@ -349,7 +352,6 @@ init_test_env() { [ ! -f "$LSOM_SYNC" ] && export LSOM_SYNC=$(which llsom_sync 2> /dev/null) [ -z "$LSOM_SYNC" ] && export LSOM_SYNC="/usr/sbin/llsom_sync" - export NAME=${NAME:-local} export LGSSD=${LGSSD:-"$LUSTRE/utils/gss/lgssd"} [ "$GSS_PIPEFS" = "true" ] && [ ! -f "$LGSSD" ] && export LGSSD=$(which lgssd) @@ -447,7 +449,6 @@ init_test_env() { export BLCKSIZE=${BLCKSIZE:-4096} export MACHINEFILE=${MACHINEFILE:-$TMP/$(basename $0 .sh).machines} - . ${CONFIG:=$LUSTRE/tests/cfg/$NAME.sh} get_lustre_env # use localrecov to enable recovery for local clients, LU-12722