Whamcloud - gitweb
LU-4442 test: add version check for replay-vbr.sh test_7g 90/9290/3
authorEmoly Liu <emoly.liu@intel.com>
Tue, 18 Feb 2014 11:53:20 +0000 (19:53 +0800)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 19 Feb 2014 01:45:55 +0000 (01:45 +0000)
In replay-vbr.sh test_7g.3, because mdt_object_exists() was added
in http://review.whamcloud.com/#/c/8371, client will not be evicted
without object version check.

The patch also fixes the wrong usage of wait_mds_ost_sync() in
replay_vbr.sh test_7_cycle(). The first parameter should be a timeout
in seconds, not a facet.

Test-Parameters: envdefinitions=SLOW=yes,ONLY=7 testlist=replay-vbr

Signed-off-by: Emoly Liu <emoly.liu@intel.com>
Signed-off-by: Jian Yu <jian.yu@intel.com>
Change-Id: I4a960fc53451fc717370bc96f926f067bbb2946a
Reviewed-on: http://review.whamcloud.com/9290
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/tests/replay-vbr.sh

index 2b1f031..4018a9b 100644 (file)
@@ -728,7 +728,7 @@ test_7_cycle() {
     client_evicted $CLIENT1 || rc=1
 
     wait_recovery_complete $SINGLEMDS
-    wait_mds_ost_sync $SINGLEMDS
+       wait_mds_ost_sync || error "wait_mds_ost_sync failed"
 
     rm -rf $DIR/$tdir
     return $rc
@@ -887,7 +887,14 @@ test_7g() {
     first="createmany -o $DIR/$tdir/$tfile- 1; mv $DIR/$tdir/$tfile-0 $DIR/$tdir/$tfile"
     lost="createmany -o $MOUNT2/$tdir/$tfile- 1"
     last="link $DIR/$tdir/$tfile-0 $DIR/$tdir/$tfile-1"
-    test_7_cycle "$first" "$lost" "$last" || error "Test 7g.3 failed"
+       if [ $(lustre_version_code $SINGLEMDS) -lt $(version_code 2.5.1) ]
+       then
+               test_7_cycle "$first" "$lost" "$last" ||
+                       error "Test 7g.3 failed"
+       else #LU-4442 LU-3528
+               test_7_cycle "$first" "$lost" "$last" &&
+                       error "Test 7g.3 failed"
+       fi
     return 0
 }
 run_test 7g "rename, {lost}, create"