首页 > 首页 > 数据库 > 非关系型数据库 > Redis > Redis集群迁移槽点报错:[WARNING] Node xx.xx.xx.xx:6379 has slots in importing state 306
2024
08-27

Redis集群迁移槽点报错:[WARNING] Node xx.xx.xx.xx:6379 has slots in importing state 306

1、现象

Redis集群迁移数据,分配槽点时遇到以下报错:
[root@sink ~]# redis-cli --cluster rebalance --cluster-use-empty-masters 172.0.1.1:6379

Performing Cluster Check (using node 172.0.1.1:6379)
[ERR] Nodes don't agree about configuration!
Check for open slots…
[WARNING] Node 172.0.1.1:6379 has slots in importing state 306.
[WARNING] The following slots are open: 306.
Check slots coverage…
[OK] All 16384 slots covered.
*** Please fix your cluster problems before rebalancing

2、原因

迁移过程中,迁移得槽点数过多,或者有bigkey导致源节点堵塞,引发源主从切换,导致迁移失败

3、解决

登录 172.0.1.1:6379 此节点,使用redis命令取消slots迁移,然后重新修复下集群

# redis-cli -h 172.0.1.1 -p 6379
> cluster setslot 306 stable
# redis-cli --cluster fix 172.0.1.1:6379
最后编辑:
作者:摘星怪
这个作者貌似有点懒,什么都没有留下。

留下一个回复

你的email不会被公开。