From: Sebastien Buisson Date: Tue, 20 Feb 2024 09:58:40 +0000 (+0100) Subject: LU-17175 tests: fix sanity-krb5 test_5 in interop mode X-Git-Tag: 2.15.5-RC1~31 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=01918803768c865c47776d5e38ee6eda64e95797;p=fs%2Flustre-release.git LU-17175 tests: fix sanity-krb5 test_5 in interop mode With newer servers, the lsvcgssd daemon is automatically restarted when the server needs to process a gss request. So do not error out if a file system access succeeds whereas the daemon was explicitly killed. Test-Parameters: trivial Signed-off-by: Sebastien Buisson Change-Id: I52ec49ca584f07100699274fe3a52ea28d227c17 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/54103 Reviewed-by: Andreas Dilger Reviewed-by: Aurelien Degremont Reviewed-by: Oleg Drokin Tested-by: jenkins Tested-by: Maloo --- diff --git a/lustre/tests/sanity-krb5.sh b/lustre/tests/sanity-krb5.sh index 9725e9a..234e0c7 100755 --- a/lustre/tests/sanity-krb5.sh +++ b/lustre/tests/sanity-krb5.sh @@ -304,9 +304,19 @@ test_5() { # flush context, and touch $RUNAS $LFS flushctx $MOUNT || error "can't flush context on $MOUNT" - $RUNAS touch $file2 && error 'should fail without lsvcgssd' + $RUNAS touch $file2 + if [ $? -eq 0 ]; then + # with newer servers, daemon is restarted automatically + if (( CLIENT_VERSION == MDS1_VERSION )); then + error '$RUNAS touch $file2 should fail without lsvcgssd' + else + echo "$RUNAS touch $file2 succeeded" + fi + else + echo "$RUNAS touch $file2 failed as expected" + fi - # restart lsvcgssd, expect touch suceed + # restart lsvcgssd, expect touch succeed echo "restart lsvcgssd and recovering" start_gss_daemons $(comma_list $(mdts_nodes)) "$LSVCGSSD -v" sleep 5