一台mq节点在加入集群后退出了, 后面重新加入集群失败, 报如下错误:

RabbitMQ Node [email protected] thinks its clustered with node [email protected], but rabbit disagrees

原因是: 主机集群认为该节点仍在集群中, 而该节点实际上退出集群了。 导致数据文件日志不一致,而无法加入集群。

解决方法:

   rabbitmqctl stop_app

 1: 删除 /var/lib/rabbitmq/mnesia

  2:  主节点中将该节点移除集群: rabbitmqctl forget_cluster_node [email protected]   ([email protected] 节点名称)

 3:rabbitmqctl join_cluster  --disc  [email protected]       (--disc 是以磁盘方式加入集群, --ram是内存节点)

 4: rabbitmqctl start_app

5: rabbitmqctl set_policy ha-all "^ha\." '{"ha-mode":"all"}'   (镜像模式。)

RabbitMQ Node [email protected] thinks its clustered with node [email protected], but rabbit disagrees

主机:

RabbitMQ Node [email protected] thinks its clustered with node [email protected], but rabbit disagrees

官网说明:

RabbitMQ Node [email protected] thinks its clustered with node [email protected], but rabbit disagrees RabbitMQ Node [email protected] thinks its clustered with node [email protected], but rabbit disagrees

相关文章: