ceph

Configure a cluster network with Cephadm?


I configured a simple Ceph cluster with cephadm, like this:

cephadm bootstrap --mon-ip 192.168.0.4
ssh-copy-id -f -i /etc/ceph/ceph.pub root@host2
ssh-copy-id -f -i /etc/ceph/ceph.pub root@host3
ceph orch host add host2
ceph orch host add host3
ceph orch apply osd --all-available-devices

And it works fine. Now I would like to set up a cluster network on 192.168.1.0/24.

I tried ceph config set global cluster_network 192.168.1.0/24 but it doesn't have any effect. I am not seeing any traffic on the secondary NICs.

How can I troubleshoot this? What is the recommended way to make cephadm notice the change?


Solution

  • It turns out this is easy. You set the new configs:

    ceph config set global cluster_network 192.168.1.0/24
    

    Then have the orchestrator reconfigure the daemons:

    ceph orch daemon reconfig mon.host1
    ceph orch daemon reconfig mon.host2
    ceph orch daemon reconfig mon.host3
    ceph orch daemon reconfig osd.1
    ceph orch daemon reconfig osd.2
    ceph orch daemon reconfig osd.3
    ...