How to restore /var/lib/ceph/osd directory
Environment
Red Hat Ceph Storage 4.x
Issue
The /var/lib/ceph/osd directory was removed unintentionally.
Resolution
If the osd is filestore, it cannot be restored. The only solution is to zap and redeploy the OSD
If the osd is bluestore, it can be restored using the following steps:
1. $ ceph-volume lvm list |grep -A15 "osd\.<id>"|grep "osd fsid"
2. $ ceph-volume lvm activate --bluestore <id> <fsid>
3. Restart the osd service using System Control, (systemctl)
These steps must be done for each osd.
Root Cause
The /var/lib/ceph/osd directory was deleted by mistake.
Diagnostic Steps
Check to see if the /var/lib/ceph/osd directory is present and has any contents.
This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.
Comments