]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/ReplicatedPG: add omap write bytes to delta_stats 18471/head
authorHaomai Wang <haomai@xsky.com>
Mon, 23 Oct 2017 05:29:15 +0000 (13:29 +0800)
committerHaomai Wang <haomai@xsky.com>
Mon, 23 Oct 2017 05:29:15 +0000 (13:29 +0800)
under rgw case, it will consume lots of omap read/write but we can't see the
statistics.

Signed-off-by: Haomai Wang <haomai@xsky.com>
src/osd/PrimaryLogPG.cc

index 99a4230da78950aca6ca5d91d09fb4c67951be8a..42bcde048ac3cdae375440c5bebba7d9720242e8 100644 (file)
@@ -6513,6 +6513,7 @@ int PrimaryLogPG::do_osd_ops(OpContext *ctx, vector<OSDOp>& ops)
        }
        t->omap_setkeys(soid, to_set_bl);
        ctx->delta_stats.num_wr++;
+        ctx->delta_stats.num_wr_kb += SHIFT_ROUND_UP(to_set_bl.length(), 10);
       }
       obs.oi.set_flag(object_info_t::FLAG_OMAP);
       obs.oi.clear_omap_digest();