From: Sage Weil Date: Tue, 3 Aug 2010 18:07:58 +0000 (-0700) Subject: osd: fix replies to dup/already-committed requests X-Git-Tag: v0.21.1~10 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4ea24d785b64c1ce10ab524c6e3bb03d4be7bf0a;p=ceph.git osd: fix replies to dup/already-committed requests We can safely reply if oldv is _older_ than what's on disk. Otherwise the request ends up on the list and never gets removed again. Signed-off-by: Sage Weil --- diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index fe416b31bcc..c7c299cfe99 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -570,7 +570,7 @@ void ReplicatedPG::do_op(MOSDOp *op) dout(3) << "do_op dup " << ctx->reqid << " was " << oldv << dendl; delete ctx; put_object_context(obc); - if (oldv >= last_update_ondisk) { + if (oldv <= last_update_ondisk) { osd->reply_op_error(op, 0); } else { dout(10) << " waiting for " << oldv << " to commit" << dendl;