Whamcloud - gitweb
LU-18328 tests: fix old MDS version for sanity-sec/51 24/56624/3
authorJian Yu <yujian@whamcloud.com>
Fri, 11 Oct 2024 03:00:51 +0000 (20:00 -0700)
committerOleg Drokin <green@whamcloud.com>
Fri, 11 Oct 2024 20:39:49 +0000 (20:39 +0000)
Fix the old MDS version for sanity-sec test 51 to skip the test
for symbolic capability names.

The patch also reverts the NODEMAP_TESTS change from commit
v2_16_0-RC1-11-g2a5e8e355498, which casued the following failure:
  EXCEPT_7=true: command not found

Test-Parameters: trivial testlist=sanity-sec env=ONLY=51 serverversion=2.15.5

Change-Id: Idf458ad5df7a7d6105b1f4da3e06280cf66919c1
Fixes: 0b0e9162e2 ("LU-13791 mdt: allow using symbolic capability names")
Fixes: 2a5e8e3554 ("LU-18247 nodemap: initialize unused fields on disk")
Signed-off-by: Jian Yu <yujian@whamcloud.com>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/56624
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Sebastien Buisson <sbuisson@ddn.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/tests/sanity-sec.sh

index c56addf..c8a6fbc 100755 (executable)
@@ -18,7 +18,7 @@ ALWAYS_EXCEPT="$SANITY_SEC_EXCEPT "
 
 [[ "$SLOW" == "no" ]] && EXCEPT_SLOW="26"
 
-NODEMAP_TESTS={7..26}
+NODEMAP_TESTS=$(seq 7 26)
 
 if ! check_versions; then
        echo "It is NOT necessary to test nodemap under interoperation mode"
@@ -4488,7 +4488,11 @@ test_51() {
        old_cap=($(do_nodes $mdts $LCTL get_param -n $cap_param 2>/dev/null))
        if [[ -n "$old_cap" ]]; then
                local new_cap="+cap_chown+cap_fowner+cap_dac_override+cap_dac_read_search"
-               (( $MDS1_VERSION > $(version_code 2.14.0.135) )) || new_cap=0xf
+
+               (( MDS1_VERSION >= $(version_code 2.15.63.14) )) ||
+               (( MDS1_VERSION < $(version_code 2.15.0) &&
+                  MDS1_VERSION > $(version_code 2.14.0.135) )) ||
+                       new_cap=0xf
                echo "old_cap: $old_cap new_cap: $new_cap"
                do_nodes $mdts $LCTL set_param $cap_param=$new_cap
                stack_trap "do_nodes $mdts $LCTL set_param $cap_param=$old_cap"