]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr: add mon metada using type of "mon" 40358/head
authorKefu Chai <kchai@redhat.com>
Tue, 9 Mar 2021 04:51:55 +0000 (12:51 +0800)
committerKefu Chai <kchai@redhat.com>
Wed, 24 Mar 2021 07:23:03 +0000 (15:23 +0800)
this change addresses a regression introduced by
c037f4cb5d7436879d58c34748ef516b5269781f

also remove the "P" before the json command.

see also: https://tracker.ceph.com/issues/48905

Fixes: https://tracker.ceph.com/issues/49661
Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 8fc290bfba4d71a60d30c2374ce4bcba37e649de)

src/mgr/Mgr.cc

index 7f52588b9bfa32e13ff4591b09cac74a98450851..4b2cdf7c53685b506356802a06f1a2dcc4b95e12 100644 (file)
@@ -554,12 +554,12 @@ void Mgr::handle_mon_map()
     }
   });
   for (const auto& name : names_exist) {
-    const auto k = DaemonKey{"osd", name};
+    const auto k = DaemonKey{"mon", name};
     if (daemon_state.is_updating(k)) {
       continue;
     }
     auto c = new MetadataUpdate(daemon_state, k);
-    const char* cmd = R"(P{{"prefix": "mon metadata", "id": "{}"}})";
+    const char* cmd = R"({{"prefix": "mon metadata", "id": "{}"}})";
     monc->start_mon_command({fmt::format(cmd, name)}, {},
                            &c->outbl, &c->outs, c);
   }