我刚刚在2个新VM上安装了rabbitmq,并试图创建一个简单的两节点集群。我已将erlang cookie文件从一台计算机复制到该计算机上的两个位置(C:\ Users {用户名}和C:\ Windows \ System32 \ config \ systemprofile),以及在另一台计算机上的那些位置。
当我尝试使用rabbitmqctl join_cluster命令彼此连接以创建集群时,得到以下输出:
Clustering node rabbit@{machinename1} with rabbit@{machinename2}
Error: unable to perform an operation on node 'rabbit@{machinename2}. Please see diagnostics information and suggestions below.
Most common reasons for this are:
* Target node is unreachable (e.g. due to hostname resolution, TCP connection or firewall issues)
* CLI tool fails to authenticate with the server (e.g. due to CLI tool's Erlang cookie not matching that of the server)
* Target node is not running
In addition to the diagnostics info below:
* See the CLI, clustering and networking guides on http://rabbitmq.com/documentation.html to learn more
* Consult server logs on node rabbit@{machinename2}
DIAGNOSTICS
===========
attempted to contact: ['{machinename2}']
rabbit@{machinename2}:
* connected to epmd (port 4369) on {machinename2}
* epmd reports node 'rabbit' uses port 25672 for inter-node and CLI tool traffic
* TCP connection succeeded but Erlang distribution failed
* Hostname mismatch: node "rabbit@{machinename2}" believes its host is different. Please ensure that hostnames resolve the same way locally and on "rabbit@{machinename2}"
Current node details:
* node name: 'rabbitmqcli60@{machinename1}'
* effective user's home directory: {homedirectory}
* Erlang cookie hash: {hash}
互联网上的每个人似乎都在说这是由于Cookie不匹配引起的,但我已经证实它们是相同的。我在这里想念什么?
运行Erlang OTP 20.2和RabbitMQ 3.7.3
答案 0 :(得分:0)
我注意到join_cluster
在机器名称方面区分大小写。