-
Bug
-
Resolution: Unresolved
-
Medium
-
None
-
None
-
None
-
3
-
9223372036854775807
When a lock is cancelled, pages still covered by another lock on the client should stay cached. Since LU-11290 ("ldlm: page discard speedup"), the lookup for this uses LDLM_MATCH_RIGHT, which returns the nearest lock at or after a page, and a lock starting past the page is taken to mean nothing covers it. search_itree() returns the first match in lock mode order (PW before PR), not the lowest start, so a PW lock further along the object hides a PR lock covering the page. That page, and every page up to the PW lock's start, is discarded.
Today this costs only cache, since the discard holds invalidate_lock. Discarding without it (LU-20157) relies on these pages being kept, and there the result is the LU-16651 -EIO or short read.
LDLM_MATCH_RIGHT is also the only match flag that can return a lock not covering the requested extent. Negative-result caching needs an offset, not a lock.
Reproducer, one client, one object: take PR [0, 1M), PR [512K, 2M) and PW [4M, 5M), then revoke the first; [512K, 1M) is dropped from cache.
- is related to
-
LU-20157 deadlock between recovery and IO
-
- Open
-