redis集群分配槽点时遇到以下报错:
[root@index_2 ~]# docker run -it --rm redis redis-cli --cluster rebalance --cluster-use-empty-masters 172.20.188.161:1002
>>> Performing Cluster Check (using node 172.20.188.161:1002)
[ERR] Nodes don't agree about configuration!
>>> Check for open slots...
[WARNING] Node 172.20.188.161:1002 has slots in importing state 11401.
[WARNING] The following slots are open: 11401.
>>> Check slots coverage...
[OK] All 16384 slots covered.
*** Please fix your cluster problems before rebalancing
造成原因:
11401这个节点可能数据比较大,迁移太慢
解决办法:
登陆1002这个节点
使用redis命令取消slots迁移(11401为slot的ID):
cluster setslot 11401 stable