Whamcloud - gitweb
LU-18330 tests: add interop PCCRO check for sanity-pcc/test_35 75/56675/4
authorQian Yingjin <qian@ddn.com>
Mon, 14 Oct 2024 02:43:31 +0000 (10:43 +0800)
committerOleg Drokin <green@whamcloud.com>
Fri, 18 Oct 2024 18:44:47 +0000 (18:44 +0000)
Add interop PCCRO connection flag check for sanity-pcc/
test_{35,36}.
Fix the interop sanity-pcc tests with b2_15.

Test-Parameters: trivial serverversion=2.15.5 testlist=sanity-pcc
Test-Parameters: trivial testlist=sanity-pcc env=ONLY=36b,ONLY_REPEAT=100
Signed-off-by: Qian Yingjin <qian@ddn.com>
Change-Id: I9174752bf123abf608a2d3e1f72650cf08e7146e
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/56675
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/tests/sanity-pcc.sh

index e825cb6..eca79a1 100755 (executable)
@@ -2979,6 +2979,9 @@ test_35() {
        local file=$DIR/$tfile
        local -a lpcc_path
 
+       $LCTL get_param -n mdc.*.connect_flags | grep -q pcc_ro ||
+               skip "Server does not support PCC-RO"
+
        setup_loopdev $SINGLEAGT $loopfile $mntpt 50
        copytool setup -m "$MOUNT" -a "$HSM_ARCHIVE_NUMBER"
        setup_pcc_mapping
@@ -3014,6 +3017,9 @@ test_36_base() {
        local state="readonly"
        local rw="$1"
 
+       $LCTL get_param -n mdc.*.connect_flags | grep -q pcc_ro ||
+                skip "Server does not support PCC-RO"
+
        [[ -z $rw ]] || state="readwrite"
        setup_loopdev $SINGLEAGT $loopfile $mntpt 50
        copytool setup -m "$MOUNT" -a "$HSM_ARCHIVE_NUMBER"
@@ -3041,9 +3047,6 @@ test_36a() {
 run_test 36a "Stale RW-PCC copy should be deleted after remove the PCC backend"
 
 test_36b() {
-       $LCTL get_param -n mdc.*.connect_flags | grep -q pcc_ro ||
-               skip "Server does not support PCC-RO"
-
        test_36_base
 }
 run_test 36b "Stale RO-PCC copy should be deleted after remove the PCC backend"