You can tune and customize the parameters of a Tair (Enterprise Edition) instance to improve its performance and security based on your business scenario. This topic describes these parameters in detail.
Notes
If the error message
Parameter is not supported for current versionis returned when you set a parameter, upgrade the minor version of the instance and try again. For more information, see Upgrade the minor version and proxy version.Some parameters automatically restart the instance after you submit the changes. The instance may experience a transient disconnection that lasts for a few seconds during the restart. When you set a parameter, check the Takes Effect upon Restart column for that parameter. For more information, see Set parameters.
The supported parameters vary based on the database engine version and architecture. This topic describes only the parameters for Tair (Enterprise Edition) instances, including memory-optimized, persistent memory, and disk-based instances. For information about the parameters for Redis Open-Source Edition instances, see Supported Redis parameters.
Supported parameters and descriptions
For readability and clarity, the tables in this topic use the following conventions:
✔️: The parameter is supported by the major version or architecture.
❌: The parameter is not supported by the major version or architecture.
To ensure instance stability, you can configure only the parameters that are listed in this topic.
For more information about architectures, see Query architecture information.
Memory-optimized and persistent memory instances
Parameter | Description | Instance edition and architecture | |
Memory-optimized | Persistent memory | ||
#no_loose_check-whitelist-always | Specifies whether to check if the client IP address is in the instance's whitelist after you enable passwordless access for a VPC. Valid values:
Note
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
#no_loose_disabled-commands | Specifies the commands to disable. You can disable high-risk commands or commands with high time complexity as needed, such as FLUSHALL, FLUSHDB, KEYS, HGETALL, EVAL, EVALSHA, and SCRIPT. Note
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
#no_loose_high-cost-key-enabled | Specifies whether to enable the feature that monitors hot keys (keys with high access traffic). This feature identifies keys that have high access traffic per second, such as keys with large values. After you enable this feature, you can view the monitored hot keys in the panel.
Note This feature is supported only by cloud-native memory-optimized instances with a minor version of 25.2.0.0 or later. Hashtag parsing and prefix parsing require minor version 25.9.1.0 or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
#no_loose_high-cost-key-traffic-bytes-threshold | |||
#no_loose_high-cost-key-parse-hashtag | |||
#no_loose_high-cost-key-parse-prefix | |||
#no_loose_high-cost-key-parse-prefix-delimiters | |||
#no_loose_high-cost-key-parse-prefix-find-limit-n | |||
#no_loose_high-cost-key-parse-prefix-skip-first-n | |||
#no_loose_lua-strict-mode | Specifies whether to enable strict mode for Lua scripts. When enabled, standard architecture instances, similar to cluster architecture instances, require that data keys in Lua scripts are passed through the
Note This parameter is supported only by memory-optimized instances that are compatible with Redis 6.0 or later. | Standard ✔️ Cluster ❌ Read/write splitting ❌ | ❌ |
#no_loose_maxmemory-evict-percent-soft-limit | Sets the memory threshold for early eviction. Valid values: [50-100]. Unit: percentage. Default value: 100. When the instance's memory usage reaches this threshold, Tair starts data eviction in the background without affecting the performance of command execution. The eviction policy still depends on the configuration of the maxmemory-policy parameter. Note This parameter is supported only by memory-optimized instances that are compatible with Redis 6.0 or later and have a minor version of 25.2.0.0 or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
#no_loose_publish-no-wait-result | Enabling this parameter improves the throughput of the PUBLISH command for Tair instances, but the return value of the PUBLISH command is always 0.
Note This parameter is supported only by memory-optimized instances that are compatible with Redis 6.0 or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
#no_loose_slow-query-isolation-weight | To improve the latency of regular commands, Tair isolates a separate thread to process slow query commands. This is an additional thread and does not affect the normal processing of the instance. Specific slow query commands include KEYS, SMEMBERS, HKEYS, HVALS, HGETALL, EXHKEYS, EXHVALS, and EXHGETALL. You cannot add or remove commands from this list. This parameter defines the threshold for slow query commands, which is the number of sub-members of the corresponding key. For the KEYS command, it is the number of keys in the current DB. Valid values: [1-999999999999999]. Default value: 1000. For example, if a Set collection has more than 1,000 sub-members, running the SMEMBERS command on this key uses the isolated thread. When the number of pending requests in the isolated thread exceeds 500, subsequent commands are processed on regular threads. Note
| Standard ✔️ Direct connection cluster ✔️ Proxy cluster ❌ Read/write splitting ❌ | ❌ |
#no_loose_sentinel-enabled | Enables or disables Sentinel-compatible mode for standard architecture instances. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ❌ |
#no_loose_sentinel-password-free-access | Specifies whether to allow password-free execution of Sentinel commands when the Sentinel mode is enabled. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
#no_loose_sentinel-password-free-commands | After you enable the Sentinel mode and set the #no_loose_sentinel-password-free-access parameter to yes, you can use this parameter to specify an additional list of commands that can be run without requiring a password. By default, this parameter is empty. Important
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
#no_loose_tls-min-version | Sets the minimum TLS version supported by the instance. Valid values:
| Standard ❌ Cluster ✔️ Read/write splitting ✔️ | ❌ |
active-expire-effort | Sets the proactivity of the task that cleans up expired keys. Increasing this value makes the engine more proactive in cleaning up expired keys, reducing the memory space they occupy, but it also increases CPU usage and latency. Valid values: [1-10]. Default value: 1. Note This parameter is supported only by persistent memory instances. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
appendfsync | The fsync frequency for Append-Only File (AOF) persistence. This parameter takes effect only when the appendonly parameter is enabled. The default value is everysec and cannot be modified. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
appendonly | Enables or disables AOF persistence for the primary node. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
| Limits the output buffer for publish/subscribe clients and normal clients. The parameter value format is
Important
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
dynamic-hz | Enables or disables dynamic hz. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
globalvectorindex_enabled | The switch for the TairVector global index. Valid values:
| Standard ❌ Cluster ✔️ Read/write splitting ❌ | ❌ |
| For instances compatible with Redis 6.0 and earlier, ziplist is used as the default encoding for hashes. A hash object uses ziplist encoding when both of the following conditions are met:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
| For instances compatible with Redis 7.0 and later, listpack is used as the default encoding for hashes. A hash object uses listpack encoding when both of the following conditions are met:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
hz | Sets the execution frequency of background tasks for the instance, such as the task to clear expired keys. Valid values: [1-500]. Default value: 10, which means 10 times per second. Note A higher value consumes more CPU resources but also results in a higher cleanup frequency when there are many expired keys. It also allows the instance to handle timeouts more precisely. We recommend a value no greater than 100. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
lazyfree-lazy-eviction | Specifies whether to enable lazyfree-based eviction. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
lazyfree-lazy-expire | Specifies whether to enable lazyfree-based deletion of expired keys. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
lazyfree-lazy-server-del | Specifies whether the DEL command asynchronously deletes data based on lazyfree. Valid values:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
lazyfree-lazy-user-del | Specifies whether the DEL command asynchronously deletes data based on lazyfree. Valid values:
| ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
list-compress-depth | The number of uncompressed nodes at both ends of a list. Valid values: [0-65535].
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
| For instances compatible with Redis 6.0 and earlier, ziplist is the default encoding for lists (the list-max-ziplist-size parameter). For instances compatible with Redis 7.0 and later, listpack is the default encoding for lists (the list-max-listpack-size parameter).
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
maxmemory-policy | The data eviction policy. When the instance runs out of memory and its memory usage reaches the Maxmemory limit, data eviction is triggered. You can select different data eviction policies. Valid values: Note
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
notify-keyspace-events | The value of notify-keyspace-events can be any combination of the following characters. It specifies the types of notifications the server sends. This parameter enables notifications for the entire instance (all DBs). Enabling it consumes extra CPU resources. For more information, see Redis keyspace notifications.
Important The value must contain at least K or E. Otherwise, no notifications are dispatched. For example, to subscribe to expiration events, set this parameter to | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
pena_rename_move_compatible_enabled | Specifies whether to enable compatible mode for the MOVE and RENAME series of commands. The time complexity of these commands is O(n), unlike the O(1) of native Redis. If the object being operated on is a large key, the operation will take a long time. Valid values:
Note This parameter is supported only by persistent memory instances with version 1.2.4 or later. | ❌ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
set-max-intset-entries | When the data in a Set collection meets the following conditions, intset encoding is used.
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
slowlog-log-slower-than | The threshold for the slow query log. Commands with an execution time exceeding this threshold are recorded. Unit: microseconds (μs). Valid values: [10000-10000000]. Default value: 20000 (20 milliseconds). | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
slowlog-max-len | The maximum number of records that the slow query log can store. Valid values: [100-10000]. Default value: 1024. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
stream-node-max-bytes | The maximum memory that each macro node in a Stream can occupy. Unit: bytes. Valid values: [0-999999999999999]. Default value: 4096. A value of 0 means no limit. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
stream-node-max-entries | The maximum number of entries that can be stored in each macro node of a Stream. Valid values: [0-999999999999999]. Default value: 100. A value of 0 means no limit. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
timeout | When a client is idle for the specified number of seconds, the instance closes the connection. Unit: seconds. Valid values: [0, 100000]. Default value: 0 (no connections are closed). | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
#no_loose_ts-auto-del-empty-skey-enable | Specifies whether to automatically delete an Skey in a TairTS data structure when all data points within the Skey have expired. Valid values:
Note This parameter is supported only by memory-optimized instances that are compatible with Redis 6.0 or later and have a minor version of 24.7.0.0 or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
| For instances compatible with Redis 6.0 and earlier, ziplist is the default encoding for Zsets. A Zset uses ziplist encoding when both of the following conditions are met:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ |
| For instances compatible with Redis 7.0 and later, listpack is the default encoding for Zsets. A Zset uses listpack encoding when both of the following conditions are met:
| ||
bigkey-threshold | The element count threshold for large keys (keys with many elements) in Top Key Statistics. Default value: 2000. Valid values: [500-100000]. Note If this parameter is not displayed in the parameter settings, upgrade the minor version and try again. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
bigkey-mem-threshold | The memory size threshold for large keys (keys with large memory usage) in Top Key Statistics. Default value: 536870912 B. Valid values: [1048576 B-1073741824 B]. Note This parameter is supported only by cloud-native memory-optimized instances with a minor version of 25.6.0.0 or later. | Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
hotkey-threshold | The statistics threshold for hot keys (by QPS) in Top Key Statistics. Default value: 5000. Valid values: [100-100000]. Note This parameter is supported only by cloud-native memory-optimized instances, and the minor version must meet the following requirements:
| Standard ✔️ Cluster ✔️ Read/write splitting ✔️ | ❌ |
Disk-based instances
Parameter | Description | Disk-based |
#no_loose_disabled-commands | Specifies the commands to disable. You can disable high-risk commands or commands with high time complexity as needed, such as FLUSHALL, FLUSHDB, KEYS, HGETALL, EVAL, EVALSHA, and SCRIPT. Note
| Standard ✔️ Cluster ✔️ |
#no_loose_lua-strict-mode | Specifies whether to enable strict mode for Lua scripts. When enabled, standard architecture instances, similar to cluster architecture instances, require that data keys in Lua scripts are passed through the
| Standard ✔️ Cluster ✔️ |
bigkey-threshold | The element count threshold for large keys (keys with many elements) in Top Key Statistics. Default value: 2000. Valid values: [500-100000]. Note This parameter is supported only by disk-based instances with version 2.6.0 or later. | Standard ✔️ Cluster ✔️ |
hotkey-threshold | The statistics threshold for hot keys (by QPS) in Top Key Statistics. Default value: 5000. Valid values: [100-100000]. Note This parameter is supported only by disk-based instances with version 2.6.0 or later. | Standard ✔️ Cluster ✔️ |
latency-monitor-threshold | Sets the latency threshold. Events with a duration exceeding this threshold are recorded as latency events. Unit: milliseconds. Valid values: [0-10000000]. Default value: 100. | Standard ✔️ Cluster ✔️ |
max-rename-commit-size | The maximum data volume that can be stored in a key that the RENAME command can rename. Unit: bytes. Valid values: [1024-268435456]. Default value: 16777216. If the actual data volume exceeds this threshold, the operation fails. | Standard ✔️ Cluster ✔️ |
max-write-batch-size | The size limit for data generated in memory in the disk storage format during command execution. Unit: bytes. Valid values: 0-1073741824 (1 GB). The default value is 0, which means no upper limit. Note If the data distribution and requests are likely to generate large intermediate data, we recommend setting this to 1073741824 (1 GB) to prevent memory overflow. | Standard ✔️ Cluster ✔️ |
optimise-huge-value | Specifies whether to enable performance optimization for large values. Valid values:
Note This parameter is supported only by disk-based SSD instances with version 2.6.0 or later. | Standard ✔️ Cluster ✔️ |
slowlog-log-slower-than | The threshold for the slow query log. Commands with an execution time exceeding this threshold are recorded. Unit: microseconds (μs). Valid values: [10000-10000000]. Default value: 1000000. | Standard ✔️ Cluster ✔️ |
slowlog-max-len | The maximum number of records that the slow query log can store. Valid values: [100-10000]. Default value: 1024. | Standard ✔️ Cluster ✔️ |
scan-background-interval-ms | The instance's background process actively polls keys to determine information such as TTL and performs garbage collection.
Note
| Standard ✔️ Cluster ✔️ |
batch-scan-count | ||
batch-scan-size | ||
timeout | When a client is idle for the specified number of seconds, the instance closes the connection. Unit: seconds. Valid values: [0, 100000]. Default value: 0 (no connections are closed). | Standard ✔️ Cluster ✔️ |
txn-isolation-lock | Specifies whether to enable transaction locks. When enabled, disk-based instances can execute MULTI, EXEC, and Lua script-related commands. The transaction lock feature may cause a 10% performance degradation. Valid values:
| Standard ✔️ Cluster ✔️ |
Proxy node parameters
These parameters are provided by proxy nodes. They are supported only by instances that use the cluster architecture in proxy mode or the read/write splitting architecture.
Parameter | Description |
cluster_compat_enable | Specifies whether to enable compatibility with native Redis cluster syntax. Valid values:
|
hello_enabled | The switch to enable switching between RESP2 and RESP3 protocols using the HELLO command. Valid values:
Note This parameter is supported only by Proxy version 7.0.9 and later. |
max_session_processing | The maximum number of requests that can be stacked for a single connection. Valid values: [10-10000000]. Default value: 1000. When a proxy node forwards a client's request to a data node but does not receive a reply, the request is in a stacked state. This parameter is mainly used to limit request stacking caused by differences in processing capabilities between the proxy node's frontend and backend, avoiding issues with increased memory usage. |
| This group of parameters is part of the observability feature. After setting them, you must also enable the audit log for them to take effect. The statistic period is 5 seconds.
Note
|
ptod_enabled | Specifies whether to pass through the client's IP address to the data node. Valid values:
|
query_cache_enabled | The query cache feature for proxy nodes. When enabled, the proxy node caches requests and query results for hot keys. When the proxy node receives the same request within the validity period, it directly returns the result to the client without interacting with the backend data shards. Important Because the key-value pair information for hot keys cached in the proxy node is not updated during the validity period, you must confirm whether your business can tolerate eventual consistency for the data during the cache validity period before you enable this feature.
|
query_cache_expire | |
query_cache_mode | |
readonly_lua_route_ronode_enable | Enables or disables Lua execution mode for read replicas. Valid values:
|
read_request_only_ronode_whenrwsplit_enable | Enables or disables directional forwarding for read-only account requests. Valid values:
|
rt_threshold_ms | The slow query log threshold for the proxy node. Unit: milliseconds (ms). Valid values: [30-2000]. Default value: 500. If the time from when a proxy node sends a request to a data node to when the proxy node receives a response exceeds this threshold, a slow query log entry is generated. |
script_check_enable | Enables or disables the proxy node's check for Lua scripts. For a list of check items, see Proxy check items for Lua. Valid values:
|
sentinel_compat_enable | Enables or disables Sentinel-compatible mode. Valid values:
|
transfer_subscrible_to_psubscrible_enable | Enables or disables the feature that converts SUBSCRIBE to PSUBSCRIBE. Valid values:
|