The CSM Replication module for supported Dell CSI Drivers can be installed via the Dell CSM Operator. Dell CSM Operator will deploy the CSM Replication sidecar and the CSM Replication Controller Manager.
To configure Replication prior to installation via CSM Operator, you need:
- a source cluster which is the main cluster
- a target cluster which will serve as the disaster recovery cluster
NOTE: If using a single Kubernetes cluster in a stretched configuration, there will be only one cluster. The source cluster is also the target cluster.
Cloning the GitHub Repository and Building repctl
The csm-replication GitHub repository is cloned to your source cluster as part of the installation. On your source cluster run the following to clone and build the repctl tool:
git clone -b v1.4.0 https://github.com/dell/csm-replication.git cd csm-replication/repctl make build
The rest of the instructions will assume that your current working directory is the csm-replication/repctl directory.
To configure Replication perform the following steps:
- On your main cluster collect the cluster admin configurations for each of the clusters. In the following example the source cluster,
/root/.kube/config-1and the target cluster,
cluster-2uses the configuration
/root/.config/config-2. Use repctl to add the clusters:
./repctl cluster add -f "/root/.kube/config-1","/root/.kube/config-2" -n "cluster-1","cluster-2"
NOTE: If using a single Kubernetes cluster in a stretched configuration there will be only one cluster.
Install the replication controller CRDs:
./repctl create -f ../deploy/replicationcrds.all.yaml
Inject the service account’s configuration into the clusters.
./repctl cluster inject
examples/<storage>_example_values.yamlsample config. Set the values for sourceClusterID and targetClusterID to the same names used in step 1. For a stretched cluster set both fields to
Create the replication storage classes using the modified configuration from step 4:
./repctl create sc --from-config ./examples/<storage>_example_values.yaml
On the target cluster, configure the prerequisites for deploying the driver via Dell CSM Operator.
Install the CSI driver for your chosen storage platform on the source cluster according to the instructions for installing the drivers using CSM Operator.