Whamcloud - gitweb
LU-2194 test: avoid wrong eviction in recovery_small
[fs/lustre-release.git] / lustre / tests / recovery-small.sh
index c2cbac1..9641565 100755 (executable)
@@ -415,6 +415,9 @@ test_19a() {
 
        mount_client $DIR2 || error "failed to mount $DIR2"
 
+       # cancel cached locks from OST to avoid eviction from it
+       cancel_lru_locks osc
+
        do_facet client "stat $DIR > /dev/null"  ||
                error "failed to stat $DIR: $?"
        drop_ldlm_cancel "chmod 0777 $DIR2" ||
@@ -439,6 +442,9 @@ test_19b() {
 
        mount_client $DIR2 || error "failed to mount $DIR2: $?"
 
+       # cancel cached locks from MDT to avoid eviction from it
+       cancel_lru_locks mdc
+
        do_facet client $MULTIOP $DIR/$tfile Ow ||
                error "failed to run multiop: $?"
        drop_ldlm_cancel $MULTIOP $DIR2/$tfile Ow ||