]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
OSD: write_if_dirty during get_or_create_pg after handle_create
authorSamuel Just <sam.just@inktank.com>
Wed, 18 Jul 2012 19:48:09 +0000 (12:48 -0700)
committerSamuel Just <sam.just@inktank.com>
Wed, 18 Jul 2012 21:26:16 +0000 (14:26 -0700)
In the case that the pg is newly created, we will activate during
that call, so the info and log will be dirty.

Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osd/OSD.cc

index 2e71ea62f032d68d3da70efd68cdc5989b8dda32..8452a9fbaccdcb47a0ebed36a8a99c8aed76bf21 100644 (file)
@@ -1440,6 +1440,7 @@ PG *OSD::get_or_create_pg(const pg_info_t& info, pg_interval_map_t& pi,
       info.pgid, create, false, role, up, acting, history, pi,
       *rctx.transaction);
     pg->handle_create(&rctx);
+    pg->write_if_dirty(*rctx.transaction);
     dispatch_context(rctx, pg, osdmap);
       
     created++;