Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 15 additions & 14 deletions content/operate/kubernetes/active-active/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ linkTitle: Active-Active databases
weight: 40
---

Redis Enterprise [Active-Active]({{< relref "/operate/rs/databases/active-active/" >}}) databases on Kubernetes provide read and write access to the same dataset from different Kubernetes clusters. This enables globally distributed applications with local read and write access, automatic conflict resolution, and seamless failover capabilities.
Redis Enterprise [Active-Active](/content/operate/rs/databases/active-active/_index.md) databases on Kubernetes provide read and write access to the same dataset from different Kubernetes clusters. This enables globally distributed applications with local read and write access, automatic conflict resolution, and seamless failover capabilities.

Active-Active databases use multi-master replication to keep data synchronized across participating clusters, allowing applications to read and write data locally while maintaining global consistency.

Expand All @@ -31,9 +31,9 @@ Versions 6.4.2-6 or later fully support the Active-Active controller. Some of th

This setup method includes the following steps:

1. Gather REC credentials and [prepare participating clusters]({{< relref "/operate/kubernetes/active-active/prepare-clusters" >}}).
2. Create [`RedisEnterpriseRemoteCluster` (RERC)]({{< relref "/operate/kubernetes/active-active/create-reaadb#create-rerc" >}}) resources.
3. Create [`RedisEnterpriseActiveActiveDatabase` (REAADB)]({{< relref "/operate/kubernetes/active-active/create-reaadb#create-reaadb" >}}) resource.
1. Gather REC credentials and [prepare participating clusters](/content/operate/kubernetes/active-active/prepare-clusters.md).
2. Create [`RedisEnterpriseRemoteCluster` (RERC)](/content/operate/kubernetes/active-active/create-reaadb.md#create-rerc) resources.
3. Create [`RedisEnterpriseActiveActiveDatabase` (REAADB)](/content/operate/kubernetes/active-active/create-reaadb.md#create-reaadb) resource.

### `crdb-cli` method

Expand All @@ -46,33 +46,34 @@ For versions 6.4.2 or earlier, this Active-Active setup method includes the foll

## Redis Enterprise Active-Active controller for Kubernetes

{{<note>}}These features are supported for general availability in releases 6.4.2-6 and later.{{</note>}}
> [!NOTE]
> These features are supported for general availability in releases 6.4.2-6 and later.

[Active-Active]({{< relref "/operate/rs/databases/active-active/" >}}) databases give you read-and-write access to Redis Enterprise clusters (REC) in different Kubernetes clusters or namespaces. Active-Active deployments managed by the Redis Enterprise operator require two additional custom resources: Redis Enterprise Active-Active database (REAADB) and Redis Enterprise remote cluster (RERC).
[Active-Active](/content/operate/rs/databases/active-active/_index.md) databases give you read-and-write access to Redis Enterprise clusters (REC) in different Kubernetes clusters or namespaces. Active-Active deployments managed by the Redis Enterprise operator require two additional custom resources: Redis Enterprise Active-Active database (REAADB) and Redis Enterprise remote cluster (RERC).

To create an Active-Active Redis Enterprise deployment for Kubernetes with these new features, first [prepare participating clusters]({{< relref "/operate/kubernetes/active-active/prepare-clusters" >}}) then [create an Active-Active database]({{< relref "/operate/kubernetes/active-active/create-reaadb" >}}).
To create an Active-Active Redis Enterprise deployment for Kubernetes with these new features, first [prepare participating clusters](/content/operate/kubernetes/active-active/prepare-clusters.md) then [create an Active-Active database](/content/operate/kubernetes/active-active/create-reaadb.md).

### REAADB custom resource

Redis Enterprise Active-Active database (REAADB) contains a link to the RERC for each participating cluster, and provides configuration and status to the management plane.

For a full list of fields and options, see the [REAADB API reference]({{<relref "/operate/kubernetes/reference/api/redis_enterprise_active_active_database_api">}}).
For a full list of fields and options, see the [REAADB API reference](/content/operate/kubernetes/reference/api/redis_enterprise_active_active_database_api.md).

For examples, see the [YAML examples]({{< relref "/operate/kubernetes/reference/yaml/active-active" >}}) section.
For examples, see the [YAML examples](/content/operate/kubernetes/reference/yaml/active-active.md) section.

### RERC custom resource

Redis Enterprise remote cluster (RERC) custom resource contains configuration details for all the participating clusters.

For a full list of fields and options, see the [RERC API reference]({{<relref "/operate/kubernetes/reference/api/redis_enterprise_remote_cluster_api">}}).
For a full list of fields and options, see the [RERC API reference](/content/operate/kubernetes/reference/api/redis_enterprise_remote_cluster_api.md).

For examples, see the [YAML examples]({{< relref "/operate/kubernetes/reference/yaml/active-active" >}}) section.
For examples, see the [YAML examples](/content/operate/kubernetes/reference/yaml/active-active.md) section.

### Manage certificates

The operator automates Active-Active certificate updates. When you update the proxy or syncer certificate secret on a participating cluster's REC, the operator detects the change and propagates the new certificate to the other participating clusters.

For details, see [Manage REC certificates]({{< relref "/operate/kubernetes/security/certificates/manage-rec-certificates" >}}) and [cert-manager integration]({{< relref "/operate/kubernetes/security/certificates/cert-manager" >}}).
For details, see [Manage REC certificates](/content/operate/kubernetes/security/certificates/manage-rec-certificates.md) and [cert-manager integration](/content/operate/kubernetes/security/certificates/cert-manager.md).

### Limitations

Expand All @@ -83,8 +84,8 @@ For details, see [Manage REC certificates]({{< relref "/operate/kubernetes/secur
* Only global database options are supported, no support for specifying configuration per location.
* No support for migration from old (`crdb-cli`) Active-Active database method to new Active-Active controller.
* No support for REAADB with participating clusters co-located within the same Kubernetes cluster, except for a single designated local participating cluster.
* Active-Active databases cannot be configured as [Redis Flex]({{< relref "/operate/kubernetes/flex" >}}) deployments.
* Active-Active databases cannot be configured as [Redis Flex](/content/operate/kubernetes/flex/_index.md) deployments.

## More info

For more general information about Active-Active, see the [Redis Enterprise Software docs]({{< relref "/operate/rs/databases/active-active/" >}}).
For more general information about Active-Active, see the [Redis Enterprise Software docs](/content/operate/rs/databases/active-active/_index.md).
40 changes: 20 additions & 20 deletions content/operate/kubernetes/active-active/create-aa-crdb-cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,12 @@ description: This section shows how to set up an Active-Active Redis Enterprise
linkTitle: Create Active-Active with crdb-cli
weight: 99
---
{{<note>}} Versions 6.4.2 and later support the Active-Active database controller. This controller allows you to create Redis Enterprise Active-Active databases (REAADB) and Redis Enterprise remote clusters (RERC) with custom resources. We recommend using the [REAADB method for creating Active-Active databases]({{< relref "/operate/kubernetes/active-active/create-reaadb" >}}).{{</note>}}
> [!NOTE]
> Versions 6.4.2 and later support the Active-Active database controller. This controller allows you to create Redis Enterprise Active-Active databases (REAADB) and Redis Enterprise remote clusters (RERC) with custom resources. We recommend using the [REAADB method for creating Active-Active databases](/content/operate/kubernetes/active-active/create-reaadb.md).

On Kubernetes, Redis Enterprise [Active-Active]({{< relref "/operate/rs/databases/active-active/" >}}) databases provide read-and-write access to the same dataset from different Kubernetes clusters. For more general information about Active-Active, see the [Redis Enterprise Software docs]({{< relref "/operate/rs/databases/active-active/" >}}).
On Kubernetes, Redis Enterprise [Active-Active](/content/operate/rs/databases/active-active/_index.md) databases provide read-and-write access to the same dataset from different Kubernetes clusters. For more general information about Active-Active, see the [Redis Enterprise Software docs](/content/operate/rs/databases/active-active/_index.md).

Creating an Active-Active database requires routing [network access]({{< relref "/operate/kubernetes/networking/" >}}) between two Redis Enterprise clusters residing in different Kubernetes clusters. Without the proper access configured for each cluster, syncing between the databases instances will fail.
Creating an Active-Active database requires routing [network access](/content/operate/kubernetes/networking/_index.md) between two Redis Enterprise clusters residing in different Kubernetes clusters. Without the proper access configured for each cluster, syncing between the databases instances will fail.

This process consists of:

Expand All @@ -26,11 +27,12 @@ This process consists of:

Before creating Active-Active databases, you'll need admin access to two or more working Kubernetes clusters that each have:

- Routing for external access with an [ingress resources]({{< relref "/operate/kubernetes/networking/ingress" >}}) (or [route resources]({{< relref "/operate/kubernetes/networking/routes" >}}) on OpenShift).
- A working [Redis Enterprise cluster (REC)]({{< relref "/operate/kubernetes/reference/api/redis_enterprise_cluster_api" >}}) with a unique name.
- Enough memory resources available for the database (see [hardware requirements]({{< relref "/operate/rs/installing-upgrading/install/plan-deployment/hardware-requirements" >}})).
- Routing for external access with an [ingress resources](/content/operate/kubernetes/networking/ingress.md) (or [route resources](/content/operate/kubernetes/networking/routes.md) on OpenShift).
- A working [Redis Enterprise cluster (REC)](/content/operate/kubernetes/reference/api/redis_enterprise_cluster_api.md) with a unique name.
- Enough memory resources available for the database (see [hardware requirements](/content/operate/rs/installing-upgrading/install/plan-deployment/hardware-requirements.md)).

{{<note>}} The `activeActive` field and the `ingressOrRouteSpec` field cannot coexist in the same REC. If you configured your ingress via the `ingressOrRouteSpec` field in the REC, create your Active-Active database with the RedisEnterpriseActiveActiveDatabase (REAADB) custom resource.{{</note>}}
> [!NOTE]
> The `activeActive` field and the `ingressOrRouteSpec` field cannot coexist in the same REC. If you configured your ingress via the `ingressOrRouteSpec` field in the REC, create your Active-Active database with the RedisEnterpriseActiveActiveDatabase (REAADB) custom resource.

## Document required parameters

Expand All @@ -49,9 +51,8 @@ The most common mistake when setting up Active-Active databases is incorrect or

You'll need the following information for each participating Redis Enterprise cluster (REC):

{{<note>}}
You'll need to create DNS aliases to resolve your API hostname `<api-hostname>`,`<ingress-suffix>`, `<replication-hostname>` to the IP address for the ingress controller’s LoadBalancer (or routes in Openshift) for each database. To avoid entering multiple DNS records, you can use a wildcard in your alias (such as *.ijk.example.com).
{{</note>}}
> [!NOTE]
> You'll need to create DNS aliases to resolve your API hostname `<api-hostname>`,`<ingress-suffix>`, `<replication-hostname>` to the IP address for the ingress controller’s LoadBalancer (or routes in Openshift) for each database. To avoid entering multiple DNS records, you can use a wildcard in your alias (such as *.ijk.example.com).

- **REC hostname** `<rec-hostname>`:
- Description: Hostname used to identify your Redis Enterprise cluster in the `crdb-cli` command. This MUST be different from other participating clusters.
Expand All @@ -69,7 +70,7 @@ You'll need to create DNS aliases to resolve your API hostname `<api-hostname>`,
- Description: Combined with database name to create the Active-Active database hostname
- Format: string
- Example value: `-cluster.ijk.example.com`
- [**REC admin credentials**]({{< relref "/operate/kubernetes/security/authentication/manage-rec-credentials" >}}) `<username> <password>`:
- [**REC admin credentials**](/content/operate/kubernetes/security/authentication/manage-rec-credentials.md) `<username> <password>`:
- Description: Admin username and password for the REC stored in a secret
- Format: string
- Example value: username: `user@example.com`, password: `something`
Expand Down Expand Up @@ -99,7 +100,7 @@ From inside your K8s cluster, edit your Redis Enterprise cluster (REC) resource

### Using ingress controller

1. If your cluster uses an [ingress controller]({{< relref "/operate/kubernetes/networking/ingress" >}}), add the following to the `spec` section of your REC resource file.
1. If your cluster uses an [ingress controller](/content/operate/kubernetes/networking/ingress.md), add the following to the `spec` section of your REC resource file.

Nginx:

Expand Down Expand Up @@ -146,11 +147,10 @@ HAproxy:

#### If using Istio Gateway and VirtualService

No changes are required to the REC spec if you are using [Istio]({{< relref "/operate/kubernetes/networking/istio-ingress" >}}) in place of an ingress controller. The `activeActive` section added above creates ingress resources. The two custom resources used to configure Istio (Gateway and VirtualService) replace the need for ingress resources.
No changes are required to the REC spec if you are using [Istio](/content/operate/kubernetes/networking/istio-ingress.md) in place of an ingress controller. The `activeActive` section added above creates ingress resources. The two custom resources used to configure Istio (Gateway and VirtualService) replace the need for ingress resources.

{{<warning>}}
These custom resources are not controlled by the operator and will need to be configured and maintained manually.
{{</warning>}}
> [!WARNING]
> These custom resources are not controlled by the operator and will need to be configured and maintained manually.

For each cluster, verify the VirtualService resource has two `- match:` blocks in the `tls` section. The hostname under `sniHosts:` should match your `<replication-hostname>`.

Expand All @@ -173,7 +173,7 @@ For each cluster, verify the VirtualService resource has two `- match:` blocks i

1. Make sure you have DNS aliases for each database that resolve your API hostname `<api-hostname>`,`<ingress-suffix>`, `<replication-hostname>` to the route IP address. To avoid entering multiple DNS records, you can use a wildcard in your alias (such as `*.ijk.example.com`).

1. If your cluster uses [OpenShift routes]({{< relref "/operate/kubernetes/networking/routes" >}}), add the following to the `spec` section of your Redis Enterprise cluster (REC) resource file.
1. If your cluster uses [OpenShift routes](/content/operate/kubernetes/networking/routes.md), add the following to the `spec` section of your Redis Enterprise cluster (REC) resource file.

```sh
activeActive:
Expand All @@ -194,7 +194,7 @@ For each cluster, verify the VirtualService resource has two `- match:` blocks i

## Create an Active-Active database with `crdb-cli`

The `crdb-cli` command can be run from any Redis Enterprise pod hosted on any participating K8s cluster. You'll need the values for the [required parameters]({{< relref "/operate/kubernetes/active-active/create-aa-crdb-cli#document-required-parameters" >}}) for each Redis Enterprise cluster.
The `crdb-cli` command can be run from any Redis Enterprise pod hosted on any participating K8s cluster. You'll need the values for the [required parameters](/content/operate/kubernetes/active-active/create-aa-crdb-cli.md#document-required-parameters) for each Redis Enterprise cluster.

```sh
crdb-cli crdb create \
Expand All @@ -207,10 +207,10 @@ crdb-cli crdb create \

To create a database that syncs between more than two instances, add additional `--instance` arguments.

See the [`crdb-cli` reference]({{< relref "/operate/rs/references/cli-utilities/crdb-cli" >}}) for more options.
See the [`crdb-cli` reference](/content/operate/rs/references/cli-utilities/crdb-cli/_index.md) for more options.

## Test your database

The easiest way to test your Active-Active database is to set a key-value pair in one database and retrieve it from the other.

You can connect to your databases with the instructions in [Manage databases]({{< relref "/operate/kubernetes/re-databases/db-controller#connect-to-a-database" >}}). Set a test key with `SET foo bar` in the first database. If your Active-Active deployment is working properly, when connected to your second database, `GET foo` should output `bar`.
You can connect to your databases with the instructions in [Manage databases](/content/operate/kubernetes/re-databases/db-controller.md#connect-to-a-database). Set a test key with `SET foo bar` in the first database. If your Active-Active deployment is working properly, when connected to your second database, `GET foo` should output `bar`.
Loading
Loading