1. 程式人生 > >windows安裝rabbitmq出現問題(2)

windows安裝rabbitmq出現問題(2)

1、出現問題

執行命令

rabbitmqctl status

部分錯誤資訊擷取:
[email protected]:
* connected to epmd (port 4369) on LAPTOP-SDG10LIN
* epmd reports node ‘rabbit’ uses port 25672 for inter-node and CLI tool traffic
* TCP connection succeeded but Erlang distribution failed
* Authentication failed (rejected by the remote node), please check the Erlang cookie

2、問題原因

.erlang.cookie檔案在兩處地方不一致導致的。使用軟體everything查詢
這裡寫圖片描述

3、解決方法

官方給出方法:
Synchronise Erlang Cookies (when running a manually installed Windows Service) Erlang Security Cookies used by the service account and the user running rabbitmqctl.bat must be synchronised for rabbitmqctl.bat to function.
To ensure Erlang cookie files contain the same string, copy the.erlang.cookie file from the Windows directory (normally C:\WINDOWS.erlang.cookie) to replace the user.erlang.cookie. The user cookie will be in the user’s home directory (%HOMEDRIVE%%HOMEPATH%), e.g.C:\Documents and Settings\%USERNAME%.erlang.cookie or C:\Users\%USERNAME%.erlang.cookie (Windows Vista andlater).
整段話的意思就是:用系統windows資料夾下的.erlang.cookie覆蓋usrs檔案下的.erlang.cookie。簡單的方法就是如上圖,直接用everything搜尋得到兩處.erlang.cookie。用第二處換掉第一處。
成功如下圖:
這裡寫圖片描述