解决:ERR This instance has cluster support disabled

Problem Description

When using Redisson for distributed locks and connecting to redis, the following error is prompted:
Insert image description here

identify the problem

By command:

cluster nodes

view, discover
Insert image description here

The reason for this prompt is that the cluster has been disabled for this Redis instance (disabled by default).

solve

Modify the value of the cluster-enabled parameter in the configuration file redis.conf to yes and remove the # in front of the parameter, and restart the Redis server.
Insert image description here

Note: It cannot be solved by running the command config set cluster-enable yes, because there is no cluster-enable configuration item in the config command.

After restarting the service, execute: cluster nodes
Insert image description here

Guess you like

Origin blog.csdn.net/zhiyikeji/article/details/134534904