Share the steps to remove purged OSDs.
This article provides step-by-step instructions to safely remove a purged OSD (Object Storage Daemon) from a Ceph cluster using rook-ceph-tools and Ceph CLI.
Prerequisites
- kubectl CLI configured to interact with the cluster.
- Ensure that the OSD to be removed is no longer required or has failed permanently.
Steps
Follow these steps to remove a purged OSD (osd.{number}):
- Mark the OSD as Out - This step ensures that the Placement Groups (PGs) are moved off the OSD.
ceph osd out osd.{number}
- Monitor PG Remapping - Verify that PGs have been successfully remapped and no data remains on the OSD.
kubectl -n rook-ceph exec deploy/rook-ceph-tools -- ceph osd df
💡 Wait until osd.{number} shows no data and its PG count is 0.
- Purge the OSD
ceph osd purge {number} --yes-i-really-mean-it
This command removes the OSD and its metadata from the cluster.
- Remove from CRUSH Map
ceph osd crush remove osd.{number}
- Delete OSD from OSD Map
ceph osd rm osd.{number}
- Remove OSD Authentication
ceph auth del osd.{number}
Notes
- Replace {number} with the actual OSD ID (e.g., 0, 1, 2, etc.).
- Always ensure PGs are fully rebalanced before purging an OSD to avoid data loss.