Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows installer for 3.6.0 and 3.6.1 RC1 fails to correctly install the Windows service #625

Closed
jcasale opened this issue Feb 15, 2016 · 16 comments
Assignees
Labels
bug pkg-windows An issue specific to Windows
Milestone

Comments

@jcasale
Copy link

jcasale commented Feb 15, 2016

With Windows Server 2008 R2, both installers create a HKEY_LOCAL_MACHINE\SOFTWARE\Ericsson\Erlang\ErlSrv\1.1\RabbitMQ key with Args and Env values missing all data. The service starts but does nothing.

The solution is to start a RabbitMQ Command Prompt and remove then install the service after installation.

@michaelklishin michaelklishin added bug pkg-windows An issue specific to Windows labels Feb 15, 2016
@michaelklishin michaelklishin added this to the 3.6.1 milestone Feb 15, 2016
@michaelklishin michaelklishin changed the title Windows installer for 3.6.0 and 3.6.0.901 fails to correctly install the windows service. Windows installer for 3.6.0 and 3.6.1 RC1 fails to correctly install the Windows service Feb 16, 2016
@hairyhum
Copy link
Contributor

Maybe it's related to fixes in #575
Look at.
bc3d524
and
0f5111c
And other non log or config related fixes in rabbitmq-service.bat

@Gsantomaggio
Copy link
Member

Hi @jcasale
Thank you for reporting.

I retried the Windows installer 3.6.1 RC1 on Windows 7, just to be sure, and it works correctly:

reg_windows_7

I'm going to try with Windows 2008 R2.

@hairyhum
Copy link
Contributor

@Gsantomaggio you can also check installation when epmd is not running.

@Gsantomaggio
Copy link
Member

@hairyhum Yes, thank you! I will.

@Gsantomaggio
Copy link
Member

Ok I have the same problem.

I noticed that there is and error during the setup :
error

I think that the installation didn't finish correctly and the registry is not correct:
reg_error

I stopped the service and put it as manual and I restarted the machine.

I got the same error using rabbitmq-server.bat as:

C:\Program Files\RabbitMQ Server\rabbitmq_server-3.6.0.901\sbin>rabbitmq-server.
bat
The filename, directory name, or volume label syntax is incorrect.
The filename, directory name, or volume label syntax is incorrect.
The filename, directory name, or volume label syntax is incorrect.
ERROR: epmd error for host Protocol: inet_tcp: register/listen error: econnrefus
ed: nxdomain (non-existing domain)

NOTE: This error appears only the first execution, I retried to execute rabbitmq-server.bat it worked:

C:\Program Files\RabbitMQ Server\rabbitmq_server-3.6.0.901\sbin>rabbitmq-server.
bat

              RabbitMQ 3.6.0.901. Copyright (C) 2007-2016 Pivotal Software, Inc.

  ##  ##      Licensed under the MPL.  See http://www.rabbitmq.com/
  ##  ##
  ##########  Logs: C:/Users/ADMINI~1/AppData/Roaming/RabbitMQ/log/RABBIT~1.LOG
  ######  ##        C:/Users/ADMINI~1/AppData/Roaming/RabbitMQ/log/RABBIT~2.LOG
  ##########
              Starting broker... completed with 0 plugins.

At this point I tried to uninstall RabbitMQ service re-install it again without reboot the machine and the setup worked correctly:
screen shot 2016-02-16 at 18 11 23

also the TCP listener is up:

C:\Program Files\RabbitMQ Server\rabbitmq_server-3.6.0.901\sbin>netstat -na | find "5672"
  TCP    0.0.0.0:5672           0.0.0.0:0              LISTENING
  TCP    0.0.0.0:25672          0.0.0.0:0              LISTENING

basically I think that we have two issues:

  1. ERROR: epmd error for host Protocol only to the first boot.
  2. The setup should stop if there is an error

@hairyhum
Copy link
Contributor

Looks like the same error I had when trying to install 3.7.x with epmd not running (e.g. after reboot).
@Gsantomaggio you can try fixes from commits I mentioned above.

@Gsantomaggio
Copy link
Member

Yes @hairyhum the error is when epmd.exe is not running. Thanks.

@Gsantomaggio
Copy link
Member

Using 0f5111c it works.
I tested it using rabbitmq-service.bat and rabbitmq-server.bat

@michaelklishin
Copy link
Member

We believe this is fixed in #631. We will produce a build for users to help verify.

@jcasale
Copy link
Author

jcasale commented Feb 17, 2016

@Gsantomaggio I saw the same error in the output window while installing RC1 however the window disappears before you can copy any of it. It might be good to fail the installation if any of the steps return invalid exit codes. In this case, the installation reports success even though you can fix it afterwords it is misleading.

@michaelklishin Once I see a new build, I will give it a spin.

Thanks everyone.

@michaelklishin
Copy link
Member

@jcasale thanks, I'm attaching a build which includes #631. Please give it a try.

rabbitmq-server-3.6.0.625.exe.zip

@Gsantomaggio
Copy link
Member

@michaelklishin just tried and it works correctly.
Before close I'd wait also @jcasale feedback.

@jcasale
Copy link
Author

jcasale commented Feb 17, 2016

I can confirm for the following cases with Erlang 18.2.1 x64 and rabbitmq-server-3.6.0.625 with Windows Server 2008 R2:

  • Installation in the default locations when SystemDrive=C:� works, the service installs and starts correctly.
  • Installation in an alternate drive and path such as the original user who had the problem at [https://groups.google.com/forum/#!topic/rabbitmq-users/Wa_4TJ8ozxE] works, the service installs and starts correctly.

Thanks.

@mishrsud
Copy link

mishrsud commented Apr 7, 2016

For the benefit of future visitors, I got hit by the same issue while trying to run any script from the sbin directory after installing RabbitMQ 3.6.1.
The issue in my case was that my HOMEDRIVE and HOMESHARE environment variables were set to a network drive and Rabbit Server didn't like this. It kept on telling me that it failed to write the Erlang cookie to H: (which was mapped to the network drive and set as my HOMEDRIVE)

Resolution: Set your HOMEDRIVE to a local drive
set HOMEDRIVE=C:
set HOMESHARE=C:\users

After this, run the RabbitMQ installer and things should be fine!
This may be helpful to set these options at startup: http://superuser.com/questions/246731/how-do-i-change-homedrive-homepath-and-homeshare-in-windows-xp

@grovesNL
Copy link

I had the same issue. I was able to use the fix provided by @mishrsud successfully.

@tr00st
Copy link

tr00st commented Oct 11, 2016

Alternative solution pulled from various sources for me was to patch the rabbitmq-env to pull the cookie from the network drive. Can't comment on whether this is ideal or works in all scenarios, but it's proven more robust for me, and doesn't require changing the home directory. Patch in gist:

https://gist.github.com/tr00st/c4609ca35121253dd0a6b25921c23417

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug pkg-windows An issue specific to Windows
Projects
None yet
Development

No branches or pull requests

7 participants