client: renew/submit subs on startup

This fixes a delay in getting the initial MDSMap during startup (we wait
for the MonClient tick()).

Reported-by: Noah Watkins <jayhawk@cs.ucsc.edu>
Signed-off-by: Sage Weil <sage@inktank.com>
This commit is contained in:
Sage Weil 2012-08-30 14:03:11 -07:00
parent a23351efda
commit 1b27a7cd4d

View File

@ -294,6 +294,7 @@ int Client::init()
monclient->set_want_keys(CEPH_ENTITY_TYPE_MDS | CEPH_ENTITY_TYPE_OSD);
monclient->sub_want("mdsmap", 0, 0);
monclient->sub_want("osdmap", 0, CEPH_SUBSCRIBE_ONETIME);
monclient->renew_subs();
// logger
PerfCountersBuilder plb(cct, "client", l_c_first, l_c_last);