]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ReplicatedPG: ensure clones are readable after find_object_context 1386/head
authorSamuel Just <sam.just@inktank.com>
Thu, 6 Mar 2014 01:39:42 +0000 (17:39 -0800)
committerSamuel Just <sam.just@inktank.com>
Thu, 6 Mar 2014 16:48:32 +0000 (08:48 -0800)
We only get EAGAIN if the object is missing.  We also need the
clone to be readable if we are reading it.

The other find_object_context callers already require !degraded.

Fixes: #7624
Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osd/ReplicatedPG.cc

index d031256261a57623e5b3028a6c5eefcfcbd106b0..4e38c2ce7adc97a609e5e2674eaaf67243ad3eb3 100644 (file)
@@ -1251,6 +1251,11 @@ void ReplicatedPG::do_op(OpRequestRef op)
       wait_for_unreadable_object(missing_oid, op);
       return;
     }
+  } else if (r == 0 && is_unreadable_object(obc->obs.oi.soid)) {
+    dout(10) << __func__ << ": clone " << obc->obs.oi.soid
+            << " is unreadable, waiting" << dendl;
+    wait_for_unreadable_object(obc->obs.oi.soid, op);
+    return;
   }
 
   if (hit_set) {