On Fri, Jul 26, 2024 at 04:18:05PM +0200, Iztok Gregori wrote:
On 26/07/24 12:35, Kai Stian Olstad wrote:
On Tue, Jul 23, 2024 at 08:24:21AM +0200, Iztok Gregori wrote:
Am I missing something obvious or with Ceph orchestrator there are non way to specify an id during the OSD creation?
You can use osd_id_claims.
I tried the osd_id_claims in a yaml file like this:
service_type: osd placement: hosts: - <hostname> data_devices: paths: - /dev/<device> osd_id_claims: <hostname>: ['<osd_id>']
An then applied it, but the created OSD didn't have the id I specified. It could be that the syntax of my yaml is wrong, but I gave me no errors when I applied it. I didn't try to directly specify the osd_id_claims on the command line. The command should be something like this:
# ceph orch daemon add osd <hosname>:<device>,osd_id_claims=<osd_id>
According to the documentation[1] you can use osd_id_claim. I use: ceph orch daemon add osd <hosname>:data_devices=<device>,osd_id_claims=<osd_id> The difference is "data_devices=", if you need it or not I don't know.
I don't know if it matters, but I've deleted/removed (not replaced) the OSD (the OSD id wasn't present in the crush map anymore, not even as "destroyed").
It might, I don't think I have tried without --replace since I use a script to replace devices in Ceph so I never forget to add the --replace. [1] https://docs.ceph.com/en/reef/cephadm/services/osd/?highlight=osd_id_claims#... -- Kai Stian