From: Sage Weil Date: Tue, 15 Jan 2019 17:29:34 +0000 (-0600) Subject: mon/AuthMonitor: be more careful with max_global_id X-Git-Tag: v14.1.0~183^2~59 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=91dd0c9787d1f5394f1926078ee98d50a5c1ae02;p=ceph-ci.git mon/AuthMonitor: be more careful with max_global_id We're potentially handing out ids that haven't committed by increasing max_global_id before it commits. Signed-off-by: Sage Weil --- diff --git a/src/mon/AuthMonitor.cc b/src/mon/AuthMonitor.cc index f160eb852b5..852530a73a5 100644 --- a/src/mon/AuthMonitor.cc +++ b/src/mon/AuthMonitor.cc @@ -293,11 +293,10 @@ void AuthMonitor::increase_max_global_id() { ceph_assert(mon->is_leader()); - max_global_id += g_conf()->mon_globalid_prealloc; dout(10) << "increasing max_global_id to " << max_global_id << dendl; Incremental inc; inc.inc_type = GLOBAL_ID; - inc.max_global_id = max_global_id; + inc.max_global_id = max_global_id + g_conf()->mon_globalid_prealloc; pending_auth.push_back(inc); }