]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mon/PGMonitor: do not create/encode pending if luminous
authorKefu Chai <kchai@redhat.com>
Fri, 19 May 2017 09:53:27 +0000 (17:53 +0800)
committerSage Weil <sage@redhat.com>
Fri, 2 Jun 2017 17:02:47 +0000 (13:02 -0400)
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/mon/PGMonitor.cc

index fd586b4d3697db75128d63d22ad221f95c1248c6..4cdc81aa2c828da34868a446138d3c558fb7622c 100644 (file)
@@ -280,6 +280,8 @@ void PGMonitor::handle_osd_timeouts()
 
 void PGMonitor::create_pending()
 {
+  if (did_delete)
+    return;
   do_delete = false;
   pending_inc = PGMap::Incremental();
   pending_inc.version = pg_map.version + 1;
@@ -446,6 +448,9 @@ void PGMonitor::apply_pgmap_delta(bufferlist& bl)
 
 void PGMonitor::encode_pending(MonitorDBStore::TransactionRef t)
 {
+  if (did_delete)
+    return;
+
   string prefix = pgmap_meta_prefix;
   if (do_delete) {
     dout(1) << __func__ << " clearing pgmap data at v" << pending_inc.version