What it means
A Redis or Valkey server runs either standalone or as a node of a cluster, decided by
cluster-enabled when it starts. A standalone server answers every CLUSTER command with:
(error) ERR This instance has cluster support disabled
That includes CLUSTER SLOTS, CLUSTER SHARDS, CLUSTER NODES and CLUSTER INFO, which cluster
clients send first to learn which node holds which slots, and even CLUSTER KEYSLOT. Without an
answer, a cluster client can’t start, and it may report this error inside a message of its own
about the cluster.
The server itself is fine, and commands such as GET and SET work on it.
Common causes
- A cluster client pointed at a standalone server. Most libraries have a separate cluster client, or a cluster option, and it was used for a server that isn’t a cluster: a local Docker Redis while production is a cluster, or a configuration copied between environments.
- ElastiCache with cluster mode disabled, used through a cluster client. Its primary and reader endpoints are standalone servers.
- Redis Cloud’s default endpoint used with a cluster client. Redis Cloud routes commands to the right shard behind that endpoint, for a plain client; cluster clients are for databases with the OSS Cluster API turned on (Pro databases only), its documentation says.
- Cluster tools run against a standalone server:
redis-cli --cluster check,--cluster infoand the like.
How to fix it
Check what the server is
redis-cli INFO server | grep redis_mode
redis-cli INFO cluster
redis_mode:standalone and cluster_enabled:0 mean a standalone server; a cluster node says
redis_mode:cluster and cluster_enabled:1.
Use a standalone client for a standalone server
Create the library’s ordinary client instead of its cluster client, or turn its cluster option off, for this environment. If your code has to run against both a standalone server in development and a cluster in production, choose the client from configuration, and keep to commands that work on both: keys used together share a hash tag (see CROSSSLOT) and only database 0 (see DB index is out of range).
redis-cli -c is different: it only follows MOVED and ASK redirects, so it works against a
standalone server too (redis-cli -c PING replied PONG on the test server).
Or run a real cluster
cluster-enabled can’t be turned on while the server runs (CONFIG SET replies can't set immutable config). A cluster is a different deployment: at least three primaries, each started
with --cluster-enabled yes, joined with
redis-cli --cluster create <host1>:<port> <host2>:<port> <host3>:<port>. Moving data from a
standalone server into it is a migration, not a setting.
Reproduce it
Redis 8.10.2 and Valkey 8.1.10 test servers, both standalone:
CLUSTER SLOTS
(error) ERR This instance has cluster support disabled
CLUSTER SHARDS
(error) ERR This instance has cluster support disabled
CLUSTER KEYSLOT user:1
(error) ERR This instance has cluster support disabled
ASKING
(error) ERR This instance has cluster support disabled
INFO cluster
# Cluster
cluster_enabled:0
CLUSTER INFO, CLUSTER NODES and CLUSTER MYID got the same message. One difference: Redis also
refused READONLY and READWRITE (the commands a cluster client uses to read from replicas) with
this error, while Valkey replied OK to both. redis-cli’s cluster tools:
$ redis-cli --cluster check 127.0.0.1:6379
[ERR] Node 127.0.0.1:6379 is not configured as a cluster node.
On a temporary Redis 8.10.2 container, CONFIG SET cluster-enabled yes replied:
(error) ERR CONFIG SET failed (possibly related to argument 'cluster-enabled') - can't set immutable config
A node of a temporary cluster answered INFO server with redis_mode:cluster, and HELLO 3 with
mode cluster.
In Inlet
You connect Inlet to a cluster the same way as to one server: given any node or a configuration
endpoint of a cluster, it follows the whole cluster (Pro); given a standalone server, it works with
that server. INFO server, INFO cluster and CLUSTER commands run in a query tab. When the
server refuses a command, Inlet shows its message and links to this page.