Created
August 21, 2020 19:52
-
-
Save troeger/72f17112a9190701dbbe20018be155d6 to your computer and use it in GitHub Desktop.
Deleting an OSD in Rook
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Lets assume you want to get rid of OSD.2, and none of the "nice" ways worked. | |
- Determine the node where the OSD daemon is running (`kubectl -n rook-ceph get pods -o wide|grep osd.2`) | |
- Enter the toolbox pod, run `ceph osd out 2` | |
- Wait for the cluster to migrate the data away (`ceph status -w`) | |
- Delete the Rook deployment for OSD 2. | |
- Enter the toolbox pod, run: | |
- ceph osd crush remove osd.2 | |
- ceph auth del osd.2 | |
- ceph osd rm 2 | |
- Enter any pod running on the node where the OSD is situated, there: | |
- `ceph-volume lvm list`, find device name for this OSD | |
- `ceph-volume lvm zap /dev/xxx --destroy` (if this does not work, use `wipefs /dev/xxx -a -f` before) | |
- Remove the device from the CephCluster CRD | |
- For more OSDs, repeat from the beginning | |
- Restart the Rook operator |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment