Configuring GlusterFS during IBM Cloud Private installation

Configure GlusterFS when you install your IBM® Cloud Private cluster.

Complete these steps to configure GlusterFS:

  1. Configure a host group with nodes that you are using to configure GlusterFS. You can either use dedicated nodes for GlusterFS, or you can configure GlusterFS on nodes that are also used as worker nodes.

    • If you are using dedicated nodes to configure GlusterFS, complete these steps. These nodes are not used as worker nodes.

      • Configure a custom host group with the dedicated GlusterFS storage nodes. For more information about how to add a host group, see Defining custom host groups.

        Following is an example configuration of a host group with dedicated GlusterFS storage nodes. You add this configuration in the /<installation_directory>/cluster/hosts file.

        Note: The worker nodes and the GlusterFS nodes are not the same.

        [worker]
        2.2.2.2
        ...
        2.2.2.9
        .
        .
        [hostgroup-glusterfs]
        6.6.6.6
        ...
        6.6.6.9
        
    • If you are configuring GlusterFS on nodes that are also used as worker nodes, complete these steps.

      • In the /<installation_directory>/cluster/hosts file, add the same nodes as worker nodes and as a custom host group.
      • In the /<installation_directory>/cluster/config.yaml file, configure no_taint_group parameter with the custom host group name.
        Following is an example configuration of shared storage nodes. You add this configuration in the /<installation_directory>/cluster/hosts file.

        [worker]
        2.2.2.2
        ...
        2.2.2.9
        .
        .
        [hostgroup-glusterfs]
        2.2.2.2
        ...
        2.2.2.9
        

        Following is an example configuration of adding the no_taint_group parameter. You add this configuration in the /<installation_directory>/cluster/config.yaml file.

        no_taint_group: ["hostgroup-glusterfs"]
        
  2. If firewall is enabled, add the list of required ports to the /<installation_directory>/cluster/config.yaml file. Locate the section firewall_enabled: true. Add the following ports for the custom host group that you created with dedicated GlusterFS storage nodes.
    Following is an example configuration of the custom host group hostgroup-glusterfs:

    firewall_open_ports:
      hostgroup-glusterfs:
        - 24007/tcp
        - 24008/tcp
        - 2222/tcp
        - 49152-49251/tcp
    

    Note: If you use existing worker nodes to deploy GlusterFS, you must manually open all the ports on all the nodes.

  3. Enable GlusterFS Storage. Set storage-glusterfs: enabled under the management services list in the /<installation_directory>/cluster/config.yaml file.

    management_services:
      istio: disabled
      vulnerability-advisor: disabled
      storage-glusterfs: enabled
      storage-minio: disabled
    
  4. Add the following piece of code to the config.yaml file:

## GlusterFS Storage Settings
storage-glusterfs:
  nodes:
    - ip: <worker_node_m_IP_address>
      devices:
        - <link path>/<symlink of device aaa>
        - <link path>/<symlink of device bbb>
    - ip: <worker_node_n_IP_address>
      devices:
        - <link path>/<symlink of device ccc>
    - ip: <worker_node_o_IP_address>
      devices:
        - <link path>/<symlink of device ddd>
  storageClass:
    create: true
    name: glusterfs
    isDefault: false
    volumeType: replicate:3
    reclaimPolicy: Delete
    volumeBindingMode: Immediate
    volumeNamePrefix: icp
    additionalProvisionerParams: {}
    allowVolumeExpansion: true
  gluster:
    resources:
      requests:
        cpu: 500m
        memory: 512Mi
      limits:
        cpu: 1000m
        memory: 1Gi
  heketi:
    backupDbSecret: heketi-db-backup
    authSecret: "heketi-secret"
    maxInFlightOperations: "20"
    dbSyncupDelay: "10"
    tls:
      generate: true
      issuer: "icp-ca-issuer"
      issuerKind: "ClusterIssuer"
      secretName: ""
    resources:
      requests:
        cpu: 500m
        memory: 512Mi
      limits:
        cpu: 1000m
        memory: 1Gi
  nodeSelector:
    key: hostgroup
    value: glusterfs    
  prometheus:
    enabled: true
    path: "/metrics"
    port: 8080
  tolerations: []  
  podPriorityClass: "system-cluster-critical"

Following are the parameter descriptions. For a list of available parameters, see Configuration Opens in a new tab.
Note: If you are configuring the default storage class and volume type parameters, ensure that you use the correct syntax. Use isDefault: <true or false> and volumeType: <volume type>.