Deleting a zone

Learn how to delete a zone.

Procedure

To delete a zone, start by removing it from the zonegroup.
  1. Remove the zone from the zonegroup.
    Important: Do not delete a zone without removing it from a zone group first. Otherwise, updating the period fails.
    radosgw-admin zonegroup remove --rgw-zonegroup=ZONE_GROUP_NAME
                                     --rgw-zone=ZONE_NAME
  2. Update the period.
    radosgw-admin period update --commit
    For example,
    [ceph: root@host01 /]# radosgw-admin period update --commit
  3. Delete the zone.
    Important: This procedure must be used on a host within the zone.
    radosgw-admin zone delete --rgw-zone=ZONE_NAME
  4. Update the period.
    radosgw-admin period update --commit
    For example,
    [ceph: root@host01 /]# radosgw-admin period update --commit
  5. Delete the pools.
    If the pools for the deleted zone will not be used anywhere else, consider deleting the pools. Replace DELETED_ZONE_NAME in the following example with the deleted zone’s name.
    Important:
    • Once Ceph deletes the zone pools, it deletes all of the data within them in an unrecoverable manner. Only delete the zone pools if Ceph clients no longer need the pool contents.
    • In a multi-realm cluster, deleting the .rgw.root pool along with the zone pools removes ALL the realm information for the cluster. Ensure that .rgw.root does not contain other active realms before deleting the .rgw.root pool.
    ceph osd pool delete DELETED_ZONE_NAME.rgw.control DELETED_ZONE_NAME.rgw.control --yes-i-really-really-mean-it
    ceph osd pool delete DELETED_ZONE_NAME.rgw.data.root DELETED_ZONE_NAME.rgw.data.root --yes-i-really-really-mean-it
    ceph osd pool delete DELETED_ZONE_NAME.rgw.log DELETED_ZONE_NAME.rgw.log --yes-i-really-really-mean-it
    ceph osd pool delete DELETED_ZONE_NAME.rgw.users.uid DELETED_ZONE_NAME.rgw.users.uid --yes-i-really-really-mean-it
  6. Required: Restart the Ceph Object Gateway process.