Skip to content

Commit

Permalink
RS: Auto tiering - manage storage engine (#2701)
Browse files Browse the repository at this point in the history
* manage storage engine DOC-2521

* correct relref

* edits

* add warning to k8s

* Update content/rs/databases/auto-tiering/storage-engine.md

Co-authored-by: Alon Magrafta <[email protected]>

---------

Co-authored-by: Alon Magrafta <[email protected]>
  • Loading branch information
kaitlynmichael and AlonMagrafta authored Aug 1, 2023
1 parent 2a3cce5 commit e4bf327
Show file tree
Hide file tree
Showing 2 changed files with 66 additions and 3 deletions.
5 changes: 2 additions & 3 deletions content/kubernetes/re-clusters/auto-tiering.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ Before creating your Redis clusters or databases, these SSDs must be:

For more information on node storage, see [Node persistent and ephemeral storage]({{<relref "/rs/installing-upgrading/install/plan-deployment/persistent-ephemeral-storage">}}).


## Create a Redis Enterprise cluster

To deploy a Redis Enterprise cluster (REC) with flash storage, you'll need to specify the following in the `redisOnFlashSpec` section of your [REC custom resource]({{<relref "/kubernetes/reference/cluster-options.md">}}):
Expand All @@ -43,6 +42,8 @@ To deploy a Redis Enterprise cluster (REC) with flash storage, you'll need to sp
- storage class name (`storageClassName`)
- minimal flash disk size (`flashDiskSize`)

{{<warning>}}Switching between storage engines requires guidance by Redis Support or your Account Manager.{{</warning>}}

Here is an example of an REC custom resource with these attributes:

```YAML
Expand Down Expand Up @@ -85,5 +86,3 @@ spec:
{{< note >}}
This example defines both `memorySize` and `rofRamSize`. When using Auto Tiering, `memorySize` refers to the total combined memory size (RAM + flash) allocated for the database. `rofRamSize` specifies only the RAM capacity for the database. `rofRamSize` must be at least 10% of `memorySize`.
{{< /note >}}


64 changes: 64 additions & 0 deletions content/rs/databases/auto-tiering/storage-engine.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
---
Title: Manage Auto Tiering storage engine
linkTitle: Manage storage engine
description: Manage the storage engine used for your database with auto tiering enabled.
weight: 100
alwaysopen: false
categories: ["RS"]
aliases: /rs/databases/auto-tiering/storage-engine.md
---

## Manage the storage engine

Redis Enterprise Auto Tiering supports two storage engines:

* [Speedb](https://www.speedb.io/) (default, recommended)
* [RocksDB](https://rocksdb.org/)

{{<warning>}}Switching between storage engines requires guidance by Redis Support or your Account Manager.{{</warning>}}

### Change the storage engine

1. Change the cluster level configuration for default storage engine.

* API:

``` sh
curl -k -u <username>:<password> -X PUT -H "Content-Type: application/json" -d '{"bigstore_driver":"speedb"}' https://localhost:9443/v1/cluster
```
* CLI:
```sh
rladmin cluster config bigstore_driver {speedb | rocksdb}
```
2. Restart the each database on the cluster one by one.
```sh
rladmin restart db { db:<id> | <name> }
```
{{<note>}} We recommend restarting your database at times with low usage and avoiding peak hours. For databases without persistence enabled, we also recommend using export to backup your database first.{{</note>}}
## Monitor the storage engine
To get the current cluster level default storage engine run:
* Use the `rladmin info cluster` command look for ‘bigstore_driver’.
* Use the REST API:
```sh
curl -k -u <username>:<password> -X GET -H "Content-Type: application/json" https://localhost:9443/v1/cluster
```
Versions of Redis Enterprise 7.2 and later provide a metric called `bdb_bigstore_shard_count` to help track the shard count per database, filtered by `bdb_id` and by storage engine as shown below:
```sh
bdb_bigstore_shard_count{bdb="1",cluster="mycluster.local",driver="rocksdb"} 1.0
bdb_bigstore_shard_count{bdb="1",cluster="mycluster.local",driver="speedb"} 2.0
```

For more about metrics for Redis Enterprise’s integration with Prometheus, see [Prometheus integration]({{<relref "/rs/clusters/monitoring/prometheus-metrics-definitions">}}).

0 comments on commit e4bf327

Please sign in to comment.