From: wangshaohui.0512 Date: Fri, 8 Aug 2025 10:23:47 +0000 (+0800) Subject: cephfs: make sure mon authenticate before objecter start X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=b617c9b3259e461ace5cd7e6c50aa3cebfd1f104;p=ceph.git cephfs: make sure mon authenticate before objecter start Signed-off-by: Shaohui Wang (cherry picked from commit 1de46f335ea21c7369c67a021da79f3c7e929e66) --- diff --git a/src/client/Client.cc b/src/client/Client.cc index 56a07af9577..11003c4bca8 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -17608,6 +17608,22 @@ int StandaloneClient::init() monclient->shutdown(); return r; } + + r = authenticate(); + if (r < 0) { + // need to do cleanup because we're in an intermediate init state + { + std::scoped_lock l(timer_lock); + timer.shutdown(); + } + + client_lock.unlock(); + objecter->shutdown(); + objectcacher->stop(); + monclient->shutdown(); + return r; + } + objecter->start(); client_lock.unlock();