Erlang machine stopped instantly (distribution name conflict?). The service is not restarted as OnFail is set to ignore
Asked Answered
A

15

17

I am using RabbitMQ. For some reason the rabbitMQ service stops as soon as you start it. I saw following error in the event log:

RabbitMQ: Erlang machine stopped instantly (distribution name conflict?). The service is not restarted as OnFail is set to ignore.

Someone told me to run this command: erl -sname rabbit

This command generates following output:

{(no error logger present")i neirtr otre: r"mEirnraotri nign  ipnr odcoe_sbso o<
t0".,2{.b0a>d awrigt,h[ {eexrilt_p rviaml_uleo:a d{ebra,dcahregc,k[_{feirlle__pr
reismu_llto,a3d,e[r{,fcihleec,k"_efrill_e_prreismu_llto,a3d,e[r{.feirlle",}\,"{e
lriln_ep,r29i3m}_]l}o,a{dienri.te,rgle\t"_}b,o{olti,n1e,,[2{9f3i}l]e},,"{iinniit
t.,egrelt"_}b,o{olti,n1e,,[78{9f}i]l}e,,{\i"niinti,tg.eetr_lb\o"o}t,,{2l,i[n{ef,
i7l8e9,}"]i}n,i{ti.neirtl,"g}e,t{_lbionoet,,7762},][}{,f{iilnei,t\,"dion_ibto.oe
tr,l3\,"[}{,f{illien,e",i77n6i}t].}e,r{li"n}i,t{,ldion_eb,o74o3t},]3},][}{}f
ile,\"init.erl\"},{line,743}]}]}\n"

I am not sure how to interpret this output. I wonder the error is specific to RabbitMQ or erlang.

I have no idea how to procceed. Please suggest.

Ash answered 7/10, 2015 at 14:59 Comment(3)
Ok, welcome to the club ! I am sitting and searchin around - have a similar problem, resulting in the error you describe. I removed an older version and tried to install 3.5.6. Then I started the "rabbitmq-server.bat" file, which shows me, that it tries to log to c:\logs - which, at my box, is a directory ..... The next hours I spent to change the logdirectory, but all my attempts to change it, failed. If I remove that logdirectory, rabbit starts. So it seems to ignore all my attempts to ovveride all log-definitions by configfile or environment variable.Emelina
For me, the issue was a missing advanced.config file in the RabbitMQ configuration (base) folder. There was no mention of this problem anywhere in RabbitMQ logs, but an Erlang crash log (dump) file was neatly present right there, in the base directory. And it had the root cause explained.Damn
I get the same error message when starting Couchbase server v7.1.1 enterprise edition on Windows 2016Alcoholometer
H
10

The only thing that worked for me was to clear the directory C:\Users\xxxxx\AppData\Roaming\RabbitMQ.

(cf. https://groups.google.com/forum/#!topic/rabbitmq-users/138RHzzsORU)

Hent answered 11/3, 2016 at 8:18 Comment(0)
M
10

I have just run into this problem setting up RabbitMq as a service up on a new Windows server. The only thing I can think of that broke it for me is renaming the new windows box after installing the RabbitMq service, but before testing it for the first time.

First off I noticed it ran as an application fine. I solved it by installing the service again using the command from the manual install instructions:

rabbitmq-service install

Assuming that you have your path variables included for the RabbitMq sbin directory.

Monteith answered 8/6, 2016 at 19:45 Comment(1)
I ran into this when installing RabbitMQ into a Windows AMI. New instances based off the image couldn't start RabbitMQ until it was reinstalled.Sensibility
S
3

I ran into the same issue when installing RabbitMQ 3.7.17 via Chocolatey on a Windows Server 2016.

After trying most of the suggested solutions, the one that worked for me was:

rabbitmq-service remove
rabbitmq-service install
rabbitmq-service start

PS: if your PATH is not configured for RabbitMQ, this is the folder you need to run the commands from: C:\Program Files\RabbitMQ Server\rabbitmq_server-3.7.17\sbin (if your version is also 3.7.17).

Snipe answered 19/11, 2019 at 2:0 Comment(0)
U
3

In my scenario, Two directories of Erlang under C:\Program Files with different versions were there, I uninstalled one of the version, also uninstalled RabbitMQ service from Windows services list - Restarted the system.

Again ran RabbitMQ setup - RabbitMQ service was setup successfully.

Udo answered 9/9, 2020 at 13:30 Comment(0)
T
1

For anyone else looking up this error: double check your config files and SSL files. I ran into this issue when I had specified the ssl_options.cacertfile with ca.pem but the file was mistyped as ca-pem in the directory. Unfortunately RabbitMQ wasn't smart enough to catch the missing file and was dumping with no logs.

Titograd answered 31/12, 2019 at 21:32 Comment(0)
D
1

Checking in from 2021:

None of this worked for me, the problem was actually that I had another instance of RabbitMQ running inside my WSL Ubuntu distro.

Disrobe answered 26/3, 2021 at 16:2 Comment(0)
A
1

I had this today trying to install rabbitmq 3.8.0 with erlang 22.0 (64Bit).

Even completely re-installing both erlang and rabbit, deleteing all directories and registry did not help at all. Also i tried to set the needed PATH variables for erlang manually and re-installing the service each time.

The only solution working for me was installing another version of erlang. In my sepcific case i used erlang 21.3 in the 32bit version.

Doing that, no manually action was necessary and rabbit was up and running (after re-installing the service).

Amu answered 3/2, 2023 at 11:24 Comment(0)
E
0

I found a name conflict with an env-variable, I use since years - means, this was not a problem with the previous version. I have "Logs" and apps will write into that directory, usually with their own subdirectories. RMQ uses the same variable name and means a plain filename. So using: "C:\Users\rabbit\AppData\Roaming\RabbitMQ\log\log" made it working for me - this is in the rabbit's users private environment. So the global settings are now not seen by rabbit. Uff. And it looks like, this is really meant as a filename and after I changed it again to "[email protected]", it writes like the earlier version. The service starts now for me - but this was really messy and I don't trust it at the moment ;-)

Emelina answered 8/10, 2015 at 4:48 Comment(2)
Where can I find the rabbit's users private environement variables ? What is the name of variable you set? Can you please provide me more information.Ash
On my machine, I do not see any environement variable set for rabbitmq . When I click run and type %APPDATA%, I do not see rabbitmq folder under this. I wonder where can find all the variables that rabbitmq uses?Ash
E
0

From my perspective, one should run such a service under its own account. If the service is already there, create a local user account - I've used "rabbit" and give it a password. The account I created, got admin right from me - but I currently just dont know, it this is needed. At least it should not - will see this later. If you have account/credentials, go to the service manager and click properties for the service. On the second tab ("log on"), check "this account" and enter username an password. If you have an account for the service you should be able to login with user. Run service with specific account Then you can specify environment variables with user scope. To do this, logon with the user you created. Go to ControlPanel/System and click "advanced": See bottom: Environment variables

In the Environment UI, enter user specific variables in the top panel: Users variables at top panel

Note: This was not my rabbit user, because I currently cannot login there. The variables, I entered - not guaranteed, it is correct - are the following:

RABBITMQ_BASE=C:\Users\rabbit\AppData\Roaming\RabbitMQ
RABBITMQ_CONFIG_FILE=C:\Users\rabbit\AppData\Roaming\RabbitMQ\rabbitmq
RABBITMQ_LOGS=C:\Users\rabbit\AppData\Roaming\RabbitMQ\log
RABBITMQ_LOG_BASE=C:\Users\rabbit\AppData\Roaming\RabbitMQ\log
RABBITMQ_NODE_IP_ADDRESS=192.168.26.3

This works for me. The last time I installed it - some years ago - it was better to understand - this time, sorry, I dont ..... But made it workig.

Emelina answered 8/10, 2015 at 21:53 Comment(0)
G
0

According to RabbitMQ Install on Windows guide here

Troubleshooting When Running as a Service

In the event that the Erlang VM crashes whilst RabbitMQ is running as a service, rather than writing the crash dump to the current directory (which doesn't make sense for a service) it is written to an erl_crash.dump file in the base directory of the RabbitMQ server (set by the RABBITMQ_BASE environment variable, defaulting to %APPDATA%\%RABBITMQ_SERVICENAME% - typically %APPDATA%\RabbitMQ otherwise).

Basically it means to add a Environment Variable named RABBITMQ_BASE with value %APPDATA%\RabbitMQ

This fixed my problem.

Glomerulonephritis answered 20/1, 2020 at 20:36 Comment(0)
C
0

I ran into this issue and the only way I could solve it was by unintalling RabbitMQ, unsintalling Erlang, rebooting the server and installing a clean Erlang and a clean RabbitMQ. After all this, I could finally install and start the RabbitMQ instance as a windows service.

Tried all the solutions in this post and nothing worked.

Lucky for me it was in our development server, so the loss was acceptable.

The downside to this approach is that you loose all configs (all users, virtual hosts, etc). It's all gone and you have to reconfigure the RabbitMQ instance from scratch.

Cavetto answered 13/2, 2021 at 23:57 Comment(0)
S
0

I had the same issue and I just downloaded the latested version of erlang and RabbitmQ and this resolved the issue for me.

Spindly answered 16/12, 2021 at 16:57 Comment(0)
M
0

While I got the same error, and the root cause for me seems related to Erlang cookie, I fixed it by doing:

  • Create a folder to store cookie, for example I am using C:\erl-23.2\home .
  • Add new system environment variable HOMEDRIVE, set the value to C:\
  • Add new system environment variable HOMEPATH, set the value to erl-23.2\home

This is making use of the rule:

%HOMEDRIVE%%HOMEPATH%.erlang.cookie (usually C:\Users%USERNAME%.erlang.cookie for user %USERNAME%) if both the HOMEDRIVE and HOMEPATH environment variables are set

Moslem answered 4/11, 2022 at 3:44 Comment(0)
T
0

Since I was doing a migration when the error popped up, I still had my original .erlang.cookie in C:\Users\Me, but the new installation generated a new .erlang.cookie during installation in C:\Windows\System32\config\systemprofile. After making them equal again and performing these steps from the sbin dir, it worked again.

rabbitmq-service remove
rabbitmq-service install
rabbitmq-service start
Tours answered 24/11, 2022 at 15:31 Comment(0)
K
0

For anyone that will stumble upon this question in 2023. We had this issue when upgrading from 3.8.2 to 3.11.21.

The issue was that when upgrading to 3.11.xx you need to enable all feature flags (https://blog.rabbitmq.com/posts/2022/07/required-feature-flags-in-rabbitmq-3.11/). And all the feature flags simply does not exist in 3.8.xx. This made RabbitMQ fail with:

Erlang machine stopped instantly (distribution name conflict?). The service is not restarted as OnFail is set to ignore

After going 3.8.xx => 3.9.xx => 3.10.xx => enable all feature flags => 3.11.xx it worked. This is documented here: https://www.rabbitmq.com/upgrade.html.

I was using Chocolatey as a package manager for erlang and rabbitmq and it said the installation when great (but it obviously did not). One could have wished for the installation itself would fail when you can't skip a version without a full stop, but lesson learned. RTFM :)

Keratose answered 22/8, 2023 at 9:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.