]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/ReplicatedPG: do not complain about missing clones when INCOMPLETE_CLONES is set
authorSage Weil <sage@redhat.com>
Thu, 24 Jul 2014 01:23:56 +0000 (18:23 -0700)
committerSage Weil <sage@redhat.com>
Sat, 2 Aug 2014 00:00:17 +0000 (17:00 -0700)
When scrubbing, do not complain about missing cloens when we are in a
caching mode *or* when the INCOMPLETE_CLONES flag is set.  Both are
indicators that we may be missing clones and that that is okay.

Fixes: #8882
Signed-off-by: Sage Weil <sage@redhat.com>
(cherry picked from commit 956f28721dd98c5fb9eb410f4fe9e320b3f3eed3)

src/osd/ReplicatedPG.cc

index b198b4d6f27eb517e25909abf71903f941352492..8652fd3c5339b17b69795db1471b070b243fce8a 100644 (file)
@@ -11668,7 +11668,7 @@ void ReplicatedPG::_scrub(ScrubMap& scrubmap)
 
       // did we finish the last oid?
       if (head != hobject_t() &&
-         pool.info.cache_mode == pg_pool_t::CACHEMODE_NONE) {
+         !pool.info.allow_incomplete_clones()) {
        osd->clog.error() << mode << " " << info.pgid << " " << head
                          << " missing clones";
         ++scrubber.shallow_errors;
@@ -11729,7 +11729,7 @@ void ReplicatedPG::_scrub(ScrubMap& scrubmap)
     //
 
     if (!next_clone.is_min() && next_clone != soid &&
-       pool.info.cache_mode != pg_pool_t::CACHEMODE_NONE) {
+       pool.info.allow_incomplete_clones()) {
       // it is okay to be missing one or more clones in a cache tier.
       // skip higher-numbered clones in the list.
       while (curclone != snapset.clones.rend() &&
@@ -11817,7 +11817,7 @@ void ReplicatedPG::_scrub(ScrubMap& scrubmap)
   }
 
   if (!next_clone.is_min() &&
-      pool.info.cache_mode == pg_pool_t::CACHEMODE_NONE) {
+      !pool.info.allow_incomplete_clones()) {
     osd->clog.error() << mode << " " << info.pgid
                      << " expected clone " << next_clone;
     ++scrubber.shallow_errors;