Fine-tune your Tair (Redis OSS-compatible) instance parameters to optimize performance and security. Supported parameters vary by engine version and architecture.
This topic covers parameters for Redis Open-Source Edition instances only. For Tair Enterprise Edition instances — including memory-optimized, persistent memory-optimized, and disk-based instances — see Configuration parameter list for Tair Enterprise Edition.
Usage notes
Only the parameters listed in this topic can be configured. Parameters not listed here cannot be changed.
Some parameter changes trigger an automatic instance restart, causing a few seconds of transient connection interruption. The Restart and Take Effect column on the parameter modification page indicates whether a restart is required. For more information, see Set parameters.
If you receive a
Parameter is not supported for current versionerror when configuring a parameter, upgrade the minor version of your instance.
How to read the support matrix
Each parameter table includes columns for the major version and architecture. The following annotations apply:
✔️ — the parameter is supported in the specified version or architecture.
❌ — the parameter is not supported in the specified version or architecture.
For architecture details, see Standard architecture, Cluster architecture, and Read/write splitting architecture.
Database kernel parameters
Access control
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
#no_loose_check-whitelist-always | Controls whether client IP addresses are checked against the instance whitelist when password-free access over a VPC is enabled. Default: no. Valid values: yes — IP whitelist check is enforced even after enabling password-free access. Clients not on the whitelist receive (error) ERR illegal address. no — IP whitelist check is skipped; any client in the same VPC can connect without being on the whitelist. Note This parameter applies to classic architecture instances only. Cloud-native architecture instances always enforce the IP whitelist, regardless of this setting. | ❌ | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
#no_loose_disabled-commands | Disables high-risk or expensive commands. Default: empty (no commands disabled). Specify command names in lowercase, separated by commas. Examples: flushall,flushdb,keys,hgetall,eval,evalsha,script. Note Disabling | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
#no_loose_tls-min-version | Sets the minimum TLS version the instance accepts. Default: TLSv1. Valid values: TLSv1, TLSv1.1, TLSv1.2. | Standard ❌ Cluster ✔️ Read/write splitting ✔️ | Standard ❌ Cluster ✔️ Read/write splitting ✔️ | Standard ❌ Cluster ✔️ Read/write splitting ✔️ | Standard ❌ Cluster ✔️ Read/write splitting ✔️ | Standard ❌ Cluster ✔️ Read/write splitting ✔️ |
Sentinel mode
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
#no_loose_sentinel-enabled | Enables Sentinel-compatible mode for Standard or Cluster instances in direct connection mode. Default: no. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ❌ | ❌ |
#no_loose_sentinel-password-free-access | When Sentinel mode is enabled, allows Sentinel-related commands to run without a password. Default: no. Valid values: yes — Sentinel commands can be executed without a password on any connection; the SENTINEL command can subscribe to the +switch-master channel. no — password is required. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ |
#no_loose_sentinel-password-free-commands | When Sentinel mode and #no_loose_sentinel-password-free-access are both enabled, specifies additional commands that can run without a password. Default: empty. Specify command names in lowercase, separated by commas. Important Commands listed here are executable without authentication on any connection. Configure this parameter with caution. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ |
Persistence
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
appendonly | Enables or disables AOF (Append Only File) persistence on the primary node. Default: yes. Valid values: yes — AOF persistence is enabled. no — AOF persistence is disabled; RDB (Redis Database) persistence runs once per day by default. See Automatic or manual backup. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
appendfsync | fsync frequency for AOF persistence. Default: everysec (cannot be changed). Takes effect only when appendonly is set to yes. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
Memory management and eviction
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
maxmemory-policy | Data eviction policy. When the instance reaches its memory limit (maxmemory), this policy determines which keys to remove. Note
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
maxmemory-eviction-tenacity | Controls how aggressively the instance evicts keys per eviction cycle. Default: 10. Range: 0–100. Lower values reduce per-cycle latency but may leave more evictable keys in memory. Higher values evict more keys per cycle at the cost of higher latency; a value of 100 ignores latency and evicts continuously until memory drops below maxmemory or no evictable keys remain. During high write traffic, increase this value — but expect higher latency. Note Available in Redis 7.0 only. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
active-expire-effort | Controls how much effort the instance spends per cycle deleting expired keys. Default: 1. Range: 1–10. Higher values delete expired keys faster but consume more CPU. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ |
client-output-buffer-limit pubsub | Output buffer limit for Pub/Sub clients. Default: 33554432 8388608 60. Format: <hard-limit> <soft-limit> <soft-seconds>. hard-limit: disconnects the client immediately when the buffer reaches this size (bytes). soft-limit and soft-seconds: disconnects the client if its buffer stays at or above the soft limit for the specified number of seconds. Important Large output buffers consume memory. Excessive command accumulation may cause data eviction or out-of-memory crashes. Verify your instance's memory specifications before adjusting this parameter. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
client-output-buffer-limit normal | Output buffer limit for regular clients. Default: 524288000 0 0. Format: <hard-limit> <soft-limit> <soft-seconds>. See client-output-buffer-limit pubsub for format details. Important Supported on Redis 6.0 or later only. Large output buffers consume memory. Excessive command accumulation may cause data eviction or out-of-memory crashes. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ |
Asynchronous deletion (lazyfree)
Lazyfree-based deletion offloads key deletion to a background thread, reducing latency spikes caused by large key deletions.
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
lazyfree-lazy-eviction | Uses asynchronous deletion when evicting keys. Default: no. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
lazyfree-lazy-expire | Uses asynchronous deletion when removing expired keys. Default: yes. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
lazyfree-lazy-server-del | Uses asynchronous deletion for implicit DEL operations (for example, when SET overwrites an existing key). Default: yes. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
lazyfree-lazy-user-del | Uses asynchronous deletion for explicit DEL commands. Default: yes. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ |
lazyfree-lazy-user-flush | Converts FLUSHDB, FLUSHALL, SCRIPT FLUSH, and FUNCTION FLUSH to asynchronous deletion mode. Default: no. Valid values: yes, no. Note Available in Redis 7.0 only. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
Background tasks and performance
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
hz | Frequency of background task execution, including expired key cleanup. Default: 10 (10 times per second). Range: 1–500. Higher values increase expired-key cleanup frequency and timeout precision but consume more CPU. Keep this value at or below 100. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
dynamic-hz | Enables dynamic adjustment of the background task frequency based on client activity. Default: yes. Valid values: yes, no. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ |
timeout | Idle timeout for client connections, in seconds. When a client is idle for this duration, the instance closes the connection. Default: 0 (connections are never closed). Range: 0–100000. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
latency-tracking | Enables per-command latency tracking. Default: yes. Valid values: yes, no. Note Available in Redis 7.0 only. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
tracking-table-max-keys | Maximum number of keys stored in the client-side caching tracking table. Default: 1000000. Range: 0–1000000000. Note Available in Redis 7.0 only. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
Slow query log
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
slowlog-log-slower-than | Threshold for the slow query log, in microseconds (μs). Commands that take longer than this value are logged. Default: 20000 (20 ms). Range: 10000–10000000. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
slowlog-max-len | Maximum number of entries stored in the slow query log. Default: 1024. Range: 100–10000. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
Keyspace notifications
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
notify-keyspace-events | Event types that the server publishes to clients as keyspace notifications. The value is a combination of the following character flags. Applies to all databases in the instance. Enabling notifications consumes CPU resources. For details, see Redis keyspace notifications. Default: empty (notifications disabled). Important The value must include at least | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
Top key statistics
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
bigkey-threshold | Element count threshold for identifying big keys in Top Key statistics. Default: 2000. Range: 500–100000. Note If this parameter is not visible in your settings, upgrade the minor version and try again. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ |
hotkey-threshold | QPS threshold for identifying hot keys in Top Key statistics. Default: 5000. Range: 100–100000. Note Requires minor version 7.0.1.8, 6.0.2.9, 5.5.2.9, or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ |
Data encoding
The parameters below control the internal encoding Redis uses for each data type. Compact encodings (ziplist, listpack, intset) reduce memory usage but switch to more flexible encodings as data grows past the configured thresholds.
Hash encoding
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
hash-max-listpack-entries | Maximum number of key-value pairs in a hash before switching from listpack to hashtable encoding. For Redis 7.0, listpack is the default hash encoding. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
hash-max-listpack-value | Maximum string length (bytes) for keys or values in a hash before switching from listpack to hashtable encoding. For Redis 7.0, listpack is the default hash encoding. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
hash-max-ziplist-entries | Maximum number of key-value pairs in a hash before switching from ziplist to hashtable encoding. For Redis 6.0 and earlier, ziplist is the default hash encoding. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
hash-max-ziplist-value | Maximum string length (bytes) for keys or values in a hash before switching from ziplist to hashtable encoding. For Redis 6.0 and earlier, ziplist is the default hash encoding. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
Sorted set encoding
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
zset-max-listpack-entries | Maximum number of elements in a sorted set before switching from listpack to skiplist encoding. For Redis 7.0, listpack is the default sorted set encoding. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
zset-max-listpack-value | Maximum string length (bytes) for elements in a sorted set before switching from listpack to skiplist encoding. For Redis 7.0, listpack is the default sorted set encoding. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
zset-max-ziplist-entries | Maximum number of elements in a sorted set before switching from ziplist to skiplist encoding. For Redis 6.0 and earlier, ziplist is the default sorted set encoding. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
zset-max-ziplist-value | Maximum string length (bytes) for elements in a sorted set before switching from ziplist to skiplist encoding. For Redis 6.0 and earlier, ziplist is the default sorted set encoding. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
List encoding
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
list-max-listpack-size | Controls the size of each quicklist node for list values, using listpack encoding (Redis 7.0). Positive values limit the node by element count. Negative values limit by byte size: -5 (≤ 64 KB), -4 (≤ 32 KB), -3 (≤ 16 KB), -2 (≤ 8 KB, default), -1 (≤ 4 KB). | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ | ❌ | ❌ |
list-max-ziplist-size | Controls the size of each quicklist node for list values, using ziplist encoding (Redis 6.0 and earlier). Positive values limit the node by element count. Negative values limit by byte size: -5 (≤ 64 KB), -4 (≤ 32 KB), -3 (≤ 16 KB), -2 (≤ 8 KB, default), -1 (≤ 4 KB). | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
list-max-ziplist-entries | Maximum number of elements in a list node before switching from ziplist encoding. Applies to Redis 2.8 only. | ❌ | ❌ | ❌ | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
list-max-ziplist-value | Maximum byte length per element in a list node before switching from ziplist encoding. Applies to Redis 2.8 only. | ❌ | ❌ | ❌ | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
list-compress-depth | Number of quicklist nodes at each end of a list that are exempt from compression. Default: 0 (no compression). Range: 0–65535. A value of 1, for example, keeps the first and last node uncompressed; all middle nodes are compressed. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
Set encoding
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
set-max-intset-entries | Maximum number of elements in a set before switching from intset to hashtable encoding. intset encoding applies when all elements are base-10 integers within the 64-bit signed integer range. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
Stream encoding
| Parameter | Description | Version 7.0 | Version 6.0 | Version 5.0 | Version 4.0 | Version 2.8 |
|---|---|---|---|---|---|---|
stream-node-max-bytes | Maximum memory per stream macro node, in bytes. Default: 0 (no limit). Range: 0–999,999,999,999,999. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ |
stream-node-max-entries | Maximum number of entries per stream macro node. Default: 0 (no limit). Range: 0–999,999,999,999,999. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ | ❌ |
Proxy node parameters
Proxy node parameters apply only to Cluster instances in proxy mode and Read/write splitting instances.
Compatibility
| Parameter | Description |
|---|---|
cluster_compat_enable | Enables compatibility with native Redis cluster syntax. Default: 1. Valid values: 1 — enables compatibility; READONLY, READWRITE, and CLUSTER series commands are supported. See List of commands supported in proxy mode. 0 — disables compatibility. |
hello_enabled | Enables switching between RESP2 and RESP3 protocols using the HELLO command. Default: 0. Valid values: 1 — enabled; 0 — disabled. Note Requires Proxy 7.0.9 or later. |
sentinel_compat_enable | Enables Sentinel-compatible mode for Cluster instances in proxy mode or Read/write splitting instances. Default: 0. Valid values: 1 — enabled; 0 — disabled. |
Connection management
| Parameter | Description |
|---|---|
max_session_processing | Maximum number of in-flight requests per connection. Default: 1000. Range: 10–10000000. A request is in-flight from the moment the proxy forwards it to a data node until the proxy receives the response. This limit prevents memory growth caused by processing speed differences between the proxy's frontend and backend. |
rt_threshold_ms | Slow query log threshold for the proxy node, in milliseconds (ms). Default: 500. Range: 30–2000. A slow query log entry is generated when the round-trip time from the proxy to a data node exceeds this threshold. |
ptod_enabled | Controls whether the proxy passes the client's original IP address to data nodes. Default: 1. Valid values: 1 — passes through the client IP; 0 — data nodes see the proxy's IP address instead. |
Request routing
| Parameter | Description |
|---|---|
read_request_only_ronode_whenrwsplit_enable | Controls how requests from read-only accounts are routed. Default: 0. Valid values: 1 — routes read-only account requests directly to read replicas, never to the primary node. 0 — distributes requests from read-only accounts across all nodes (including the primary node) based on weight. |
readonly_lua_route_ronode_enable | Controls how Lua scripts are routed when read replicas are available. Default: 0. Valid values: 1 — Lua scripts containing only read operations are forwarded to read replicas. 0 — all Lua scripts are processed by the primary node. |
Lua script handling
| Parameter | Description |
|---|---|
script_check_enable | Enables the proxy's validation check for Lua scripts. For details on what is checked, see Proxy checks for Lua scripts. Default: 1. Valid values: 1 — proxy validates Lua scripts before execution. 0 — proxy skips validation, except for read-only account connections, which are always checked. |
transfer_subscrible_to_psubscrible_enable | Converts SUBSCRIBE to PSUBSCRIBE at the proxy level. Default: 0. Valid values: 1 — enables conversion. 0 — no conversion. Enable this if you cannot receive messages on a subscribed channel because SUBSCRIBE or PUBLISH commands are used inside a Lua script. |
Observability
These parameters are part of observability features. They require audit logs to be enabled before statistics are recorded. Statistics are collected every 5 seconds.
| Parameter | Description |
|---|---|
#no_loose_statistics-ip-enable | Enables IP address connection statistics. Default: no. Valid values: yes, no. When enabled, the instance records the IP addresses of connecting clients. |
#no_loose_statistics-cmds | Specifies commands to monitor for source IP and access frequency. Default: empty (no monitoring). Specify command names in lowercase, separated by commas. |
#no_loose_statistics-keys | Specifies keys to monitor for source IP and access frequency. Default: empty (no monitoring). Separate multiple key names with commas. |
After enabling these parameters, download audit logs from the Simple Log Service console. See Download audit logs. Filter by log type:
Type 7: IP address QPS statistics
Type 8: IP address connection statistics
Type 9: Key statistics
Type 10: Command statistics
To avoid performance impact, limit the number of commands and keys specified in#no_loose_statistics-cmdsand#no_loose_statistics-keys. Enable these parameters only during troubleshooting or maintenance tasks.