mirror of
https://github.com/ceph/ceph
synced 2025-01-18 09:02:08 +00:00
client: move monc->set_want_keys() before monc->init()
if monc's tick connect to the mon before monc.set_want_keys() is called, monc won't ask for the key for MDS service, and hence will fail to build_authorizer() for MDS service. this change ready us for the feature of monc-connect-to-mon-in-parallel. Signed-off-by: Kefu Chai <kchai@redhat.com>
This commit is contained in:
parent
5871a6f403
commit
79f3f30112
@ -476,6 +476,7 @@ int Client::init()
|
||||
messenger->add_dispatcher_tail(objecter);
|
||||
messenger->add_dispatcher_tail(this);
|
||||
|
||||
monclient->set_want_keys(CEPH_ENTITY_TYPE_MDS | CEPH_ENTITY_TYPE_OSD);
|
||||
int r = monclient->init();
|
||||
if (r < 0) {
|
||||
// need to do cleanup because we're in an intermediate init state
|
||||
@ -488,8 +489,6 @@ int Client::init()
|
||||
}
|
||||
objecter->start();
|
||||
|
||||
monclient->set_want_keys(CEPH_ENTITY_TYPE_MDS | CEPH_ENTITY_TYPE_OSD);
|
||||
|
||||
// logger
|
||||
PerfCountersBuilder plb(cct, "client", l_c_first, l_c_last);
|
||||
plb.add_time_avg(l_c_reply, "reply", "Latency of receiving a reply on metadata request");
|
||||
|
Loading…
Reference in New Issue
Block a user