]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: Don't evict after a flush if intersecting scrub range 27209/head
authorDavid Zafman <dzafman@redhat.com>
Tue, 26 Mar 2019 22:53:10 +0000 (15:53 -0700)
committerDavid Zafman <dzafman@redhat.com>
Wed, 27 Mar 2019 02:20:06 +0000 (19:20 -0700)
Fixes: http://tracker.ceph.com/issues/38840
Signed-off-by: David Zafman <dzafman@redhat.com>
src/osd/PrimaryLogPG.cc

index 66017e9b7f5edff0d35bf7e497dd54bf2ab7eef2..17cd29e8e9849ef429e82589298421877d2ea2ba 100644 (file)
@@ -14243,6 +14243,11 @@ bool PrimaryLogPG::agent_maybe_evict(ObjectContextRef& obc, bool after_flush)
     dout(20) << __func__ << " skip (dirty) " << obc->obs.oi << dendl;
     return false;
   }
+  // This is already checked by agent_work() which passes after_flush = false
+  if (after_flush && range_intersects_scrub(soid, soid.get_head())) {
+      dout(20) << __func__ << " skip (scrubbing) " << obc->obs.oi << dendl;
+      return false;
+  }
   if (!obc->obs.oi.watchers.empty()) {
     dout(20) << __func__ << " skip (watchers) " << obc->obs.oi << dendl;
     return false;