Project

General

Profile

Actions

Bug #37328

closed

rgw: master zone deletion without a zonegroup rm would break rgw rados init

Added by Abhishek Lekshmanan over 5 years ago. Updated about 5 years ago.

Status:
Resolved
Priority:
Normal
Category:
-
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
luminous, mimic
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

currently we validate the existance of master zone for all zonegroups in a period, which will trigger an impossible scenario when the master zone in a non-master zonegroup is deleted before removing it already, as the master_zone field would exist and point to a now non existant zone. Since this is a part of RGWRados init check, any subsequent operations cannot be done in the cluster.

A simple script to simulate this would be:

The following creates 2 zgs with a zone each

radosgw-admin realm create --rgw-realm=test --default
radosgw-admin zonegroup create --rgw-zonegroup=zg1 --endpoints=http://localhost:8001 --master --default
radosgw-admin zone create --rgw-zonegroup=zg1 --rgw-zone=z1 --endpoints=http://localhost:8001 --access-key=zaccess1 --secret=zsecret1 --master --default
radosgw-admin user create --rgw-zone=z1 --rgw-zonegroup=zg1 --uid=sysuser --display-name=sysuser --access-key=zaccess1 --secret=zsecret1
radosgw -n client.rgw --rgw_frontends="civetweb port=8001" --rgw-zone=z1 --rgw-zonegroup=zg1
echo "sleeping to wait rgw to startup" && sleep 5
radosgw-admin period update --commit

radosgw-admin zonegroup create --rgw-zonegroup=zg2 --endpoints=http://localhost:8002
radosgw-admin zone create --rgw-zone=z2 --rgw-zonegroup=zg2 --endpoints=http://localhost:8002 --access-key=zaccess1 --secret=zsecret1 --master
radosgw-admin period update --commit

After the above setup, a simple

$ radosgw-admin zone delete --rgw-zone=z2 
$ radosgw-admin period update --commit 

will render any further rados activities useless as rados init_complete will not succeed from this point on.


Related issues 2 (0 open2 closed)

Copied to Ceph - Backport #37465: mimic: rgw: master zone deletion without a zonegroup rm would break rgw rados initResolvedNathan CutlerActions
Copied to Ceph - Backport #37466: luminous: rgw: master zone deletion without a zonegroup rm would break rgw rados initResolvedAbhishek LekshmananActions
Actions #1

Updated by Abhishek Lekshmanan over 5 years ago

  • Description updated (diff)
  • Backport set to luminous, mimic
Actions #2

Updated by Abhishek Lekshmanan over 5 years ago

  • Status changed from New to In Progress
  • Assignee set to Abhishek Lekshmanan
Actions #3

Updated by Abhishek Lekshmanan over 5 years ago

  • Status changed from In Progress to 17
Actions #4

Updated by Abhishek Lekshmanan over 5 years ago

  • Status changed from 17 to Pending Backport
Actions #5

Updated by Abhishek Lekshmanan over 5 years ago

  • Copied to Backport #37465: mimic: rgw: master zone deletion without a zonegroup rm would break rgw rados init added
Actions #6

Updated by Abhishek Lekshmanan over 5 years ago

  • Copied to Backport #37466: luminous: rgw: master zone deletion without a zonegroup rm would break rgw rados init added
Actions #7

Updated by Nathan Cutler about 5 years ago

  • Status changed from Pending Backport to Resolved
Actions

Also available in: Atom PDF