English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية

Redis Config Set Command

Redis Server

The Redis Config Set command can dynamically adjust the configuration (configuration) of the Redis server without restarting.

You can use it to modify configuration parameters or change the persistence (Persistence) method of Redis.

Syntax

Basic Syntax of Redis Config Set Command:

redis 127.0.0.1:6379> CONFIG Set parameter value

Available Versions

>= 2.0.0

Return Values

Returns OK when the setting is successful, otherwise it returns an error.

Online Examples

redis 127.0.0.1:6379> CONFIG GET slowlog-max-len
1) "slowlog-max-len"
2) "1024"
redis 127.0.0.1:6379> CONFIG SET slowlog-max-len 10086
OK
redis 127.0.0.1:6379> CONFIG GET slowlog-max-len
1) "slowlog-max-len"
2) "10086"

 

Redis Server