Commit 152608e
committed
Fix Ceph OSD not starting after reboot with loop device
The ceph-osd-losetup service sets up the loop device backing
the Ceph OSD, but after a reboot two things can go wrong:
1. LVM scans run before the loop device is ready, so the
vg_ceph logical volumes (data, db) are never activated.
The OSD fails with: 'failed to open /dev/vg_ceph/data:
No such file or directory'
2. Ceph services can start before the losetup service
completes, racing against the loop device setup.
Fix both by adding:
- ExecStartPost=vgchange -ay vg_ceph to activate the LVs
after the loop device is attached
- Before=ceph.target to ensure correct ordering with all
Ceph daemons1 parent fd34fab commit 152608e
1 file changed
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
249 | 249 | | |
250 | 250 | | |
251 | 251 | | |
| 252 | + | |
252 | 253 | | |
253 | 254 | | |
254 | 255 | | |
| 256 | + | |
255 | 257 | | |
256 | 258 | | |
257 | 259 | | |
| |||
0 commit comments