Removing buckets in ceph

If you need to remove some buckets in ceph you can also do this via radosgw-admin

# List your buckets
radosgw-admin bucket list 

# Remove them
radosgw-admin bucket rm --bucket=BUCKET_TO_DELETE

#if you get error: 
ERROR: could not remove non-empty bucket

radosgw-admin bucket rm --bucket=BUCKET_TO_DELETE --purge-objects --bypass-gc


Option –purge-objects option will purge these objects and when you add option –bypass-gc this will trigger removal of objects without the garbage collector and that will make operation more efficient.