当前位置:   article > 正文

RabbitMQ集群过程中遇到的一些问题的解决办法_rabbitmq加入集群报错:[error] failed to create a tracked

rabbitmq加入集群报错:[error] failed to create a tracked connection table for
    环境:
    容器环境:docker 1.12.1
    镜像版本:centos 7.2.1151
    1.添加集群节点报错:
  • 1
  • 2
  • 3
  • 4
[root@rabbitmqsalver2 /]# rabbitmqctl join_cluster --ram rabbit@rabbitmqmaster
Clustering node rabbit@rabbitmqsalver2 with rabbit@rabbitmqmaster ...
Error: unable to connect to nodes [rabbit@rabbitmqmaster]: nodedown

DIAGNOSTICS
===========

attempted to contact: [rabbit@rabbitmqmaster]

rabbit@rabbitmqmaster:
  * connected to epmd (port 4369) on rabbitmqmaster
  * epmd reports node 'rabbit' running on port 25672
  * TCP connection succeeded but Erlang distribution failed

  * Authentication failed (rejected by the remote node), please check the Erlang cookie


current node details:
- node name: 'rabbitmq-cli-88@rabbitmqsalver2'
- home dir: /root
- cookie hash: 55WeQTsiv71JcEDq/JcE9Q==
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
     从错误提示 TCP connection succeeded but Erlang distribution failed,Authentication failed (rejected by the remote node), please check the Erlang cookie 可以看出是 Erlang cookie的问题,节点的cookie和主节点的cookie不一致。解决办法在每个主机的$HOME目录下新建一个.erlang.cookie,里面随便输入一段字符串。或者在/var/lib/rabbitmq这个目录下新建同样的文件,里面随便写些字符,但是要在/etc/rabbitmq/rabbit-env.conf里面通过HOME=/var/lib/rabbitmq来指定。所有节点的.erlang.cookie必须保持一致。
    2.启动RabbitMQ出现"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",这个是cookie访问权限的问题,解决办法如下:
  • 1
  • 2
[root@rabbitmqmaster /]# chmod 600 /var/lib/rabbitmq/.erlang.cookie
  • 1
声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/在线问答5/article/detail/900174
推荐阅读
相关标签
  

闽ICP备14008679号