{
  "id": "edit-clusters",
  "title": "Edit participating clusters for Active-Active database",
  "url": "https://redis.io/docs/latest/operate/kubernetes/7.8.4/active-active/edit-clusters/",
  "summary": "Steps to add or remove a participating cluster to an existing Active-Active database with Redis Enterprise for Kubernetes.",
  "content": "This feature is supported for general availability in releases 6.4.2-6 and later. Some of these features were available as a preview in 6.4.2-4 and 6.4.2-5. Please upgrade to 6.4.2-6 for the full set of general availability features and bug fixes. and later.\n\n## Add a participating cluster\n\nUse the following steps to add a participating cluster to an existing Redis Enterprise Active-Active database (REAADB) for Kubernetes.\n\n### Prerequisites\n\nTo prepare the Redis Enterprise cluster (REC) to participate in an Active-Active database, perform the following tasks from [Prepare participating clusters]():\n\n- Make sure the cluster meets the hardware and naming requirements.\n- Enable the Active-Active controllers.\n- Configure external routing.\n- Configure `ValidatingWebhookConfiguration`.\n\n### Collect REC credentials\n\nTo communicate with other clusters, all participating clusters need access to the admin credentials for all other clusters.\n\n1. Get the REC credentials secret for the new participating cluster.\n\n    ```sh\n    kubectl get secret -o yaml \u003crec-name\u003e\n    ```\n\n    This example shows an admin credentials secret for an REC named `rec-boston`:\n\n    ```yaml\n    apiVersion: v1\n    data:\n      password: ABcdef12345\n      username: GHij56789\n    kind: Secret\n    metadata:\n      name: rec-boston\n    type: Opaque\n    ```\n\n1. Create a secret for the new participating cluster named `redis-enterprise-\u003crerc\u003e` and add the username and password.\n\n    The example below shows a secret file for a remote cluster named `rerc-logan` .\n\n    ```yaml\n    apiVersion: v1\n    data:\n      password: ABcdef12345\n      username: GHij56789\n    kind: Secret\n    metadata:\n      name: redis-enterprise-rerc-logan\n    type: Opaque\n    ```\n\n1. Apply the file of collected secrets to every participating REC.\n\n    ```sh\n    kubectl apply -f \u003crec-secret-file\u003e\n    ```\n\n If the admin credentials for any of the clusters change, update and reapply the file to all clusters.\n\n### Create RERC\n\n1. From one of the existing participating clusters, create a `RedisEnterpriseRemoteCluster` (RERC) custom resource for the new participating cluster.\n\n    This example shows an RERC custom resource for an REC named `rec-boston` in the namespace `ns-massachusetts`. \n\n    ```yaml\n    apiVersion: app.redislabs.com/v1alpha1\n    kind: RedisEnterpriseRemoteCluster\n    metadata:\n      name: rerc-logan\n    spec:\n      recName: rec-boston\n      recNamespace: ns-massachusetts\n      apiFqdnUrl: test-example-api-rec-boston-ns-massachusetts.example.com\n      dbFqdnSuffix: -example-cluster-rec-boston-ns-massachusetts.example.com\n      secretName: redis-enterprise-rerc-logan\n    ```\n\n1. Create the RERC custom resource.\n\n    ```sh\n    kubectl create -f \u003cnew-RERC-file\u003e\n    ```\n\n1. Check the status of the newly created RERC custom resource.\n\n    ```sh\n    kubectl get rerc \u003cRERC-name\u003e\n    ```\n\n    The output should look like this:\n\n    ```sh\n    NAME        STATUS   SPEC STATUS   LOCAL\n    rerc-logan   Active   Valid         true\n    ```\n\n### Edit REAADB spec\n\n1. Patch the REAADB spec to add the new RERC name to the `participatingClusters`, replacing `\u003creaadb-name\u003e` and `\u003crerc-name\u003e` with your own values.\n\n    ```sh\n    kubectl patch reaadb \u003creaadb-name\u003e \u003c --type merge --patch '{\"spec\": {\"participatingClusters\": [{\"name\": \"\u003crerc-name\u003e\"}]}}'\n    ```\n\n1. View the REAADB `participatingClusters` status to verify the cluster was added.\n\n    ```sh\n    kubectl get reaadb \u003creaadb-name\u003e -o=jsonpath='{.status.participatingClusters}'\n    ```\n\n    The output should look like this:\n\n    ```sh\n    [{\"id\":1,\"name\":\"rerc-ohare\"},{\"id\":2,\"name\":\"rerc-reagan\"},{\"id\":3,\"name\":\"rerc-logan\"}]\n    ```\n\n## Remove a participating cluster\n\n1. On an existing participating cluster,remove the desired cluster from the `participatingCluster` section of the REAADB spec.\n\n    ```sh\n    kubectl edit reaadb \u003creaadb-name\u003e\n    ```\n\n1. On each of the other participating clusters, verify the status is `active` and the spec status is `Valid` and the cluster was removed.\n\n   ```sh\n   kubectl get reaadb \u003creaadb-name -o=jasonpath=`{.status}`\n   ```\n   \n    The output should look like this:\n    \n    ```sh\n    {... ,\"participatingClusters\":[{\"id\":1,\"name\":\"rerc1\"},{\"id\":2,\"name\":\"rerc2\"}],\"redisEnterpriseCluster\":\"rec1\",\"specStatus\":\"Valid\",\"status\":\"active\"}\n    ```\n\n1. On the removed participating cluster, list all REAADB resources on the cluster to verify they were deleted.\n\n\n    ```sh\n    kubectl get reaadb -o+jasonpath=`{range.items[*]}{.metadata.name}`\n    ```\n",
  "tags": ["docs","operate","kubernetes"],
  "last_updated": "2026-04-08T12:21:52-07:00"
}

