Enable Ceph multinetwork

Ceph allows establishing multiple IP networks and subnet masks for clusters with configured L3 network rules. In Container Cloud, you can configure multinetwork through the network section of the KaaSCephCluster CR. Ceph Controller uses this section to specify the Ceph networks for external access and internal daemon communication. The parameters in the network section use the CIDR notation, for example, 10.0.0.0/24.

Before enabling multiple networks for a Ceph cluster, consider the following requirements:

  • Do not confuse the IP addresses you define with the public-facing IP addresses the network clients may use to access the services.

  • If you define more than one IP address and subnet mask for the public or cluster network, ensure that the subnets within the network can route to each other.

  • Include each IP address or subnet in the network section to IP tables and open ports for them as necessary.

  • The pods of the Ceph OSD and RadosGW daemons use cross-pods health checkers to verify that the entire Ceph cluster is healthy. Therefore, each CIDR must be accessible inside Ceph pods.

  • Avoid using the 0.0.0.0/0 CIDR in the network section. With a zero range in publicNet and/or clusterNet, the Ceph daemons behavior is unpredictable.

To enable multinetwork for Ceph:

  1. Select from the following options:

    • If the Ceph cluster is not deployed on a managed cluster yet, edit the deployment KaaSCephCluster YAML template.

    • If the Ceph cluster is already deployed on a managed cluster, open KaaSCephCluster for editing:

      kubectl -n <managedClusterProjectName> edit kaascephcluster
      

      Substitute <managedClusterProjectName> with a corresponding value.

    • Applies to management or regional clusters before Container Cloud 2.20.0. Open the KaasCephCluster CR for editing:

      kubectl edit kaascephcluster
      

      Ceph changes in Container Cloud 2.20

      • Since Container Cloud 2.20.0, the Ceph cluster does not deploy on management and regional clusters to reduce resource consumption.

      • Ceph cluster is automatically removed from existing management and regional clusters during the Container Cloud update to 2.20.0.

      • Managed clusters continue using Ceph as a distributed storage system.

  2. In the clusterNet and/or publicNet parameters of the cephClusterSpec.network section, define a comma-separated array of CIDRs. For example:

    network:
      publicNet:  10.12.0.0/24,10.13.0.0/24
      clusterNet: 10.10.0.0/24,10.11.0.0/24
    
  3. Select from the following options:

    • If you are creating a managed cluster, save the updated KaaSCephCluster template to the corresponding file and proceed with the managed cluster creation.

    • If you are configuring KaaSCephCluster of an existing managed cluster, exiting the text editor will apply the changes.

    • Applies to management or regional clusters before Container Cloud 2.20.0:

      • For bare metal, save the updated KaaSCephCluster CR:

        kubectl edit kaascephcluster
        
      • For Equinix Metal, Ceph nodes are added automatically

Once done, the specified network CIDRs will be passed to the Ceph daemons pods through the rook-config-override ConfigMap.