I am using RabbitMQ with Grails, and a problem cropped up this morning. When I run rabbitmqctl
status it tells me:
C:\\Users\\BuildnTest2>rab
I copied the cookie from C:\Windows
into my home folder (C:\Users\Current User\.erlang.cookie
) and everything started working fine.
The definitive answer to your specific question, on the RabbitMQ site is at http://www.rabbitmq.com/clustering.html
However, from your status dump, it doesn't look as though this is your issue. It just looks as though your node is down. Am I correct in assuming that you aren't running a cluster? The fact that the node that you can't connect to is the same as the one you are running the commands from indicates this.
If the RabbitMQ service is running then run rabbitmqctl start If it isn't running then go to services and start it and then the above. The erlang cookie is irrelevant for non-clustered configurations.
I observed this issue when clone server made alive with name change. Problem solved after clean rabbitmq and erlang installation.
In my case, for some reason the cookie (.erlang.cookie
) stored under C:\Windows\
was different from the one I had stored under my home (%HOMEDRIVE%
%HOMEPATH%
, which was C:\
for me).
Once I copied the cookie from C:\Windows
into my my home folder everything started working.
For what it's worth, in 2018, the docs are WRONG. In windows 10, the default location of the cookie file appears to be:
C:\Windows\System32\config\systemprofile
and NOT
C:\Windows
as the docs say.
The best thing to do is to look at the log file, which is typically located in your user %AppData%\Roaming\RabbitMQ\log
directory.
The log file contains this entry, which helped me determine the cookie location:
node : rabbit@computername
home dir : C:\WINDOWS\system32\config\systemprofile
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 and later).
https://www.rabbitmq.com/install-windows-manual.html