Documentation | |
---|---|
Name: | [HOWTO] Completely remove OSD from cluster |
Description: | HOW TO Completely remove OSD from cluster (hardcore edition) |
Modification date : | 07/06/2018 |
Owner: | dodger |
Notify changes to: | Owner |
Tags: | ceph, object storage |
Scalate to: | The_fucking_bofh |
Instructions are copy/paste
There can be various reasons to remove an OSD from an RHCS cluster, and the following steps show how to do it:
sudo /etc/init.d/ceph stop osd.{X} # where {X} is the OSD number
or:
sudo systemctl stop ceph-osd@{X} # where {X} is the OSD number
ceph osd out {X} # where {X} is the OSD number
ceph -w
Important: Wait for data rebalance to complete and all the PG's to come back active+clean, before moving to next steps.
Step 4 is only needed if OSD is getting permanently removed from the cluster and will not be redeployed
ceph osd crush remove osd.{X}
If OSD is being redeployed and because of that need removal then skip step 4 it will keep OSD in the CRUSH map as DNE and will not cause data rebalance because of CRUSH map update. Only addition of OSD will cause data movement.
ceph auth del osd.{X}
ceph auth list
ceph osd rm {X}
umount /var/lib/ceph/osd/ceph-{x}