Ceph Nautilus - Required devices (block and data) not present for bluestore
When using the new ceph-volume scan and activate commands on ceph Nautilus after an upgrade from Luminous I was getting the following message
1root@ceph2 ~]# ceph-volume simple activate --all
2--> activating OSD specified in /etc/ceph/osd/37-11af5440-dadf-40e3-8924-2bbad3ee5b58.json
3Running command: /bin/ln -snf /dev/sdh2 /var/lib/ceph/osd/ceph-37/block
4Running command: /bin/chown -R ceph:ceph /dev/sdh2
5Running command: /bin/systemctl enable ceph-volume@simple-37-11af5440-dadf-40e3-8924-2bbad3ee5b58
6Running command: /bin/ln -sf /dev/null /etc/systemd/system/ceph-disk@.service
7--> All ceph-disk systemd units have been disabled to prevent OSDs getting triggered by UDEV events
8Running command: /bin/systemctl enable --runtime ceph-osd@37
9Running command: /bin/systemctl start ceph-osd@37
10--> Successfully activated OSD 37 with FSID 11af5440-dadf-40e3-8924-2bbad3ee5b58
11--> activating OSD specified in /etc/ceph/osd/11-8c5b0218-4d32-404f-b06b-f6e90906ab7d.json
12--> Required devices (block and data) not present for bluestore
13--> bluestore devices found: [u'data']
14--> RuntimeError: Unable to activate bluestore OSD due to missing devices
You can see one volume activated while the other didn't.
It turns out this is because one volume was configure for bluestore and the other wasn't and there is some sort of a bug in the ceph-volume
command and when it writes out the /etc/ceph/osd/{OSDID}-GUID.json
files it omits the "type": "filestore"
line for any non-bluestore disks, but the ceph-volume activate command assumes it's a bluestore volume unless otherwise specified in the json file.
The quick and easy fix was to add the line "type": "filestore",
to the json files for any non-bluestore disks and run ceph-volume simple activate --all
again.
Time permitting I'll hunt down the bug in the scan command and submit a pull request if it's not already been done