From ac9a7565ddf801121f22476cf3f66668f311833e Mon Sep 17 00:00:00 2001 From: Orit Wasserman Date: Sun, 22 Jan 2017 14:42:14 +0200 Subject: [PATCH] rgw: we need to reinit the zonegroup after assignment to avoid invalid cct and store Fixes: http://tracker.ceph.com/issues/18631 Signed-off-by: Orit Wasserman --- src/rgw/rgw_rados.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc index 8757baf1c5786..ff7f0ad56e6ee 100644 --- a/src/rgw/rgw_rados.cc +++ b/src/rgw/rgw_rados.cc @@ -3680,6 +3680,11 @@ int RGWRados::init_zg_from_period(bool *initialized) if (iter != current_period.get_map().zonegroups.end()) { ldout(cct, 20) << "using current period zonegroup " << zonegroup.get_name() << dendl; zonegroup = iter->second; + ret = zonegroup.init(cct, this, false); + if (ret < 0) { + ldout(cct, 0) << "failed init zonegroup: " << " " << cpp_strerror(-ret) << dendl; + return ret; + } ret = zone_params.init(cct, this); if (ret < 0 && ret != -ENOENT) { ldout(cct, 0) << "failed reading zone params info: " << " " << cpp_strerror(-ret) << dendl; -- 2.39.5