From: Xiubo Li Date: Wed, 7 Apr 2021 03:08:03 +0000 (+0800) Subject: mds: do not show the default auth if it's unambiguous X-Git-Tag: v17.1.0~2314^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F40638%2Fhead;p=ceph.git mds: do not show the default auth if it's unambiguous Signed-off-by: Xiubo Li --- diff --git a/src/mds/CDentry.cc b/src/mds/CDentry.cc index 7d8170f7316..70d33a00165 100644 --- a/src/mds/CDentry.cc +++ b/src/mds/CDentry.cc @@ -63,7 +63,10 @@ ostream& operator<<(ostream& out, const CDentry& dn) if (dn.is_replicated()) out << dn.get_replicas(); } else { - out << " rep@" << dn.authority(); + mds_authority_t a = dn.authority(); + out << " rep@" << a.first; + if (a.second != CDIR_AUTH_UNKNOWN) + out << "," << a.second; out << "." << dn.get_replica_nonce(); }