From: Jing Wenjun Date: Fri, 25 Nov 2016 13:31:22 +0000 (+0800) Subject: rgw: metadata sync info should be shown at master zone of slave zonegroup X-Git-Tag: v10.2.8~94^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=6add2a457e2826b71c0e9e82c6f6686cecbc4584;p=ceph.git rgw: metadata sync info should be shown at master zone of slave zonegroup When executing 'radosgw-admin sync status', the metadata sync info should be shown on the srceen at master zone of slave zonegroup. Using the function store->is_meta_master() instead of 'zonegroup.is_master && zone.id == zonegroup.master_zone' Fixes: http://tracker.ceph.com/issues/18091 Signed-off-by: Jing Wenjun (cherry picked from commit c12d0af2f98b246a73cc3ee027449a22192795b3) --- diff --git a/src/rgw/rgw_admin.cc b/src/rgw/rgw_admin.cc index 05c05620cbb..c32bb43c5c6 100644 --- a/src/rgw/rgw_admin.cc +++ b/src/rgw/rgw_admin.cc @@ -1977,7 +1977,7 @@ static void sync_status(Formatter *formatter) list md_status; - if (zone.id == zonegroup.master_zone) { + if (store->is_meta_master()) { md_status.push_back("no sync (zone is master)"); } else { get_md_sync_status(md_status);