[rabbitmq-discuss] WinXP Embedded - Interactive Server works, Service does not.

Daniel Lewis DanielLewis at Ticketmaster.com
Thu Nov 1 23:25:08 GMT 2012


As a status update, I found that if I go back to RabbitMQ version 2.2.0, the service works correctly on my VM running XP, but this did not change the behavior on the Windows XP Embedded system.  So this is not "common across XP versions" as I had been thinking before.

I have also tested with versions 2.0.0 and 1.7.0 but so far I am not able to get the service running on XP embedded.

Best Regards,
Daniel

-----Original Message-----
From: rabbitmq-discuss-bounces at lists.rabbitmq.com [mailto:rabbitmq-discuss-bounces at lists.rabbitmq.com] On Behalf Of Daniel Lewis
Sent: Thursday, November 01, 2012 11:11 AM
To: 'Simon MacMullen'
Cc: Discussions about RabbitMQ
Subject: Re: [rabbitmq-discuss] WinXP Embedded - Interactive Server works, Service does not.

Hi Simon,

Here is the output from running rabbitmq-service.bat install, after removing the @echo off.

(One additional note, I just done the same steps to install RabbitMQ on a virtual machine running regular XP, and it gives the same results that I have described for the XP embedded install, so maybe this is common across XP versions.)



C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rabbitmq-service.bat install

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  The contents of this file are subje ct to the Mozilla Public License

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  Version 1.1 (the "License"); you ma y not use this file except in

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  compliance with the License. You ma y obtain a copy of the License

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  at http://www.mozilla.org/MPL/

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  Software distributed under the Lice nse is distributed on an "AS IS"

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  basis, WITHOUT WARRANTY OF ANY KIND , either express or implied. See

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  the License for the specific langua ge governing rights and

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  limitations under the License.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  The Original Code is RabbitMQ.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  The Initial Developer of the Origin al Code is VMware, Inc.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM  Copyright (c) 2007-2012 VMware, Inc .  All rights reserved.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>REM

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>setlocal

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem Preserve values that might contain e xclamation marks before

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem enabling delayed expansion

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set TN0=rabbitmq-service

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set TDP0=C:\PROGRA~1\TICKET~1\TMDS\rabbi
tmq\sbin\

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set P1=install

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set STAR=install

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>setlocal enabledelayedexpansion

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_SERVICENAME!" == "" (set R ABBITMQ_SERVICENAME=RabbitMQ )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_BASE!" == "" (set RABBITMQ _BASE=!APPDATA!\!RABBITMQ_SERVICENAME! )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!COMPUTERNAME!" == "" (set COMPUTERN AME=localhost )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_NODENAME!" == "" (set RABB ITMQ_NODENAME=rabbit@!COMPUTERNAME! )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_NODE_IP_ADDRESS!" == "" (i f not "!RABBITMQ_NODE_PORT!" == "" (set RABBITMQ_NODE_IP_ADDRESS=auto ) )  else (if "!RABBITMQ_NODE_PORT!" == "" (set RABBITMQ_NODE_PORT=5672 ) )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!ERLANG_SERVICE_MANAGER_PATH!" == ""
 (
if not exist "!ERLANG_HOME!\bin\erl.exe" ( echo.
 echo ******************************
 echo ERLANG_HOME not set correctly.
 echo ******************************
 echo.
 echo Please either set ERLANG_HOME to point to your Erlang installation or plac e the  echo RabbitMQ server distribution in the Erlang lib folder.
 echo.
 exit /B
)
 for /F "delims=" %i in ('dir /ad/b "!ERLANG_HOME!"') do if exist "!ERLANG_HOME!
\%i\bin\erlsrv.exe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\%i\bin )
)

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\bin\bin\erlsrv.e xe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\bin\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\doc\bin\erlsrv.e xe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\doc\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\erts-5.9.2\bin\e rlsrv.exe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\erts-5.9.2\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\lib\bin\erlsrv.e xe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\lib\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\releases\bin\erl srv.exe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\releases\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!ERLANG_HOME!\usr\bin\erlsrv.e xe" (set ERLANG_SERVICE_MANAGER_PATH=!ERLANG_HOME!\usr\bin )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set CONSOLE_FLAG=

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set CONSOLE_LOG_VALID=

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>for %i in (new reuse) do if "%i" == "!RA BBITMQ_CONSOLE_LOG!" set CONSOLE_LOG_VALID=TRUE

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "new" == "!RABBITMQ_CONSOLE_LOG!" set  CONSOLE_LOG_VALID=TRUE

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "reuse" == "!RABBITMQ_CONSOLE_LOG!" s et CONSOLE_LOG_VALID=TRUE

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!CONSOLE_LOG_VALID!" == "TRUE" (set CONSOLE_FLAG=-debugtype !RABBITMQ_CONSOLE_LOG! )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem *** End of configuration ***

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if not exist "!ERLANG_SERVICE_MANAGER_PA TH!\erlsrv.exe" ( echo.
 echo **********************************************
 echo ERLANG_SERVICE_MANAGER_PATH not set correctly.
 echo **********************************************
 echo.
 echo "!ERLANG_SERVICE_MANAGER_PATH!\erlsrv.exe" not found  echo Please set ERLANG_SERVICE_MANAGER_PATH to the folder containing "erlsrv.ex e".
 echo.
 exit /B 1
)

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_MNESIA_BASE!" == "" (set R ABBITMQ_MNESIA_BASE=!RABBITMQ_BASE!/db )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_LOG_BASE!" == "" (set RABB ITMQ_LOG_BASE=!RABBITMQ_BASE!/log )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem We save the previous logs in their r espective backup

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem Log management (rotation, filtering based on size...) is left as an exercise for the user.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set LOGS=!RABBITMQ_LOG_BASE!\!RABBITMQ_N
ODENAME!.log

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set SASL_LOGS=!RABBITMQ_LOG_BASE!\!RABBI
TMQ_NODENAME!-sasl.log

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>rem End of log management

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_MNESIA_DIR!" == "" (set RA BBITMQ_MNESIA_DIR=!RABBITMQ_MNESIA_BASE!/!RABBITMQ_NODENAME!-mnesia )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_PLUGINS_EXPAND_DIR!" == ""
 (set RABBITMQ_PLUGINS_EXPAND_DIR=!RABBITMQ_MNESIA_BASE!/!RABBITMQ_NODENAME!-plu
gins-expand )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!P1!" == "install" goto INSTALL_SERV ICE

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if not exist "!RABBITMQ_BASE!" (echo Cre
ating base directory !RABBITMQ_BASE!   & md "!RABBITMQ_BASE!" )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>"!ERLANG_SERVICE_MANAGER_PATH!\erlsrv" l ist !RABBITMQ_SERVICENAME!  2>NUL 1>NUL The system cannot find the file specified.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if errorlevel 1 ("!ERLANG_SERVICE_MANAGE R_PATH!\erlsrv" add !RABBITMQ_SERVICENAME! -internalservicename !RABBITMQ_SERVIC ENAME! )  else (echo !RABBITMQ_SERVICENAME! service is already present - only up dating service parameters )
c:\progra~1\ticketmaster\tmds\erlang\erts-5.9.2\bin\erlsrv: Service RabbitMQ add ed to system.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_ENABLED_PLUGINS_FILE!" == "" (set RABBITMQ_ENABLED_PLUGINS_FILE=!RABBITMQ_BASE!\enabled_plugins )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_PLUGINS_DIR!" == "" (set R ABBITMQ_PLUGINS_DIR=!TDP0!..\plugins )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set RABBITMQ_EBIN_ROOT=!TDP0!..\ebin

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>"!ERLANG_HOME!\bin\erl.exe" -pa "!RABBIT MQ_EBIN_ROOT!" -noinput -hidden -s rabbit_prelaunch -extra "!RABBITMQ_ENABLED_PL
UGINS_FILE:\=/!"        "!RABBITMQ_PLUGINS_DIR:\=/!"        "!RABBITMQ_PLUGINS_E
XPAND_DIR:\=/!"        ""
Activating RabbitMQ plugins ...
0 plugins activated:


C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set RABBITMQ_BOOT_FILE=!RABBITMQ_PLUGINS
_EXPAND_DIR!\rabbit

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if ERRORLEVEL 1 (exit /B 1 )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set RABBITMQ_EBIN_PATH=

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if "!RABBITMQ_CONFIG_FILE!" == "" (set R ABBITMQ_CONFIG_FILE=!RABBITMQ_BASE!\rabbitmq )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if exist "!RABBITMQ_CONFIG_FILE!.config"
 (set RABBITMQ_CONFIG_ARG=-config "!RABBITMQ_CONFIG_FILE!" )  else (set RABBITMQ _CONFIG_ARG= )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set RABBITMQ_LISTEN_ARG=

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>if not "!RABBITMQ_NODE_IP_ADDRESS!" == "
" (if not "!RABBITMQ_NODE_PORT!" == "" (set RABBITMQ_LISTEN_ARG=-rabbit tcp_list eners "[{\"!RABBITMQ_NODE_IP_ADDRESS!\", !RABBITMQ_NODE_PORT!}]" ) )

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set ERLANG_SERVICE_ARGUMENTS= !RABBITMQ_ EBIN_PATH! -boot "!RABBITMQ_BOOT_FILE!" !RABBITMQ_CONFIG_ARG! +W w +A30 +P 10485
76 -kernel inet_default_connect_options "[{nodelay,true}]" !RABBITMQ_LISTEN_ARG!
 !RABBITMQ_SERVER_ERL_ARGS! -sasl errlog_type error -sasl sasl_error_logger fals e -rabbit error_logger {file,\""!LOGS:\=/!"\"} -rabbit sasl_error_logger {file,\ ""!SASL_LOGS:\=/!"\"} -os_mon start_cpu_sup false -os_mon start_disksup false -o s_mon start_memsup false -mnesia dir \""!RABBITMQ_MNESIA_DIR:\=/!"\" !RABBITMQ_S ERVER_START_ARGS! !STAR!

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set ERLANG_SERVICE_ARGUMENTS=!ERLANG_SER
VICE_ARGUMENTS:\=\\!

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>set ERLANG_SERVICE_ARGUMENTS=!ERLANG_SER
VICE_ARGUMENTS:"=\"!

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>"!ERLANG_SERVICE_MANAGER_PATH!\erlsrv" s et !RABBITMQ_SERVICENAME! -machine "!ERLANG_SERVICE_MANAGER_PATH!\erl.exe" -env ERL_CRASH_DUMP="!RABBITMQ_BASE:\=/!/erl_crash.dump" -workdir "!RABBITMQ_BASE!" - stopaction "rabbit:stop_and_halt()." -sname !RABBITMQ_NODENAME! !CONSOLE_FLAG! - comment "A robust and scalable messaging broker" -args "!ERLANG_SERVICE_ARGUMENT S!"  1>NUL The system cannot find the file specified.

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>goto END

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>endlocal

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>endlocal

C:\PROGRA~1\TICKET~1\TMDS\rabbitmq\sbin>




Best Regards,
Daniel







-----Original Message-----
From: Simon MacMullen [mailto:simon at rabbitmq.com]
Sent: Thursday, November 01, 2012 10:52 AM
To: Daniel Lewis
Cc: Discussions about RabbitMQ
Subject: Re: [rabbitmq-discuss] WinXP Embedded - Interactive Server works, Service does not.

Gosh, I thought you must have done something strange. But no.

So my suspicion is obviously on WinXP Embedded. Unfortunately I'd never even heard of it before, and I certainly don't have a copy lying around.

My best guess is that something is going badly wrong with the batch interpreter and "rabbitmq-service.bat install". If you can run "rabbitmq-service.bat remove", (and make sure that worked), remove the "@echo off" from the start, run "rabbitmq-service.bat install" and send me the output I can peer at it. But I wouldn't want to promise anything.

Cheers, Simon

On 01/11/12 17:32, Daniel Lewis wrote:
> I installed erlang like this:
> otp_win32_R15B02.exe  /S  /D={my directory name}
>
> Then I copied the RabbitMQ entire directory structure over, set up the 
> environment variables for ERLANG_HOME and RABBITMQ_HOME, and ran 
> %RABBITMQ_HOME%/sbin/rabbitmq-service.bat install
>
> Best Regards,
> Daniel
>
> -----Original Message-----
> From: Simon MacMullen [mailto:simon at rabbitmq.com]
> Sent: Thursday, November 01, 2012 10:25 AM
> To: Discussions about RabbitMQ
> Cc: Daniel Lewis
> Subject: Re: [rabbitmq-discuss] WinXP Embedded - Interactive Server works, Service does not.
>
> The output of "rabbitmq-service.bat list" looks very odd.
>
> One problem is that the sname is specified as "RabbitMQ", we normally use "rabbit@(hostname)". That explains why rabbitmqctl can't connect.
> But it also looks like the "args" field is empty; this normally contains a complete command line for starting RabbitMQ. So I think you're just starting an Erlang VM.
>
> How did you install the service?
>
> Cheers, Simon
>
> On 01/11/12 16:24, Daniel Lewis wrote:
>> Hi, I am having some issues getting RabbitMQ to run as an service on 
>> Windows XP Embedded.
>>
>> It will start epmd.exe, erl.exe, and erlsrv.exe, but there are no log 
>> files created.
>>
>> rabbitmqctl.bat status       returns:
>>
>> Status of node 'rabbit at DANIEL-WYSE' ...
>>
>> Error: unable to connect to node 'rabbit at DANIEL-WYSE' : nodedown
>>
>> DIAGNOSTICS
>>
>> ===========
>>
>> nodes in question: ['rabbit at DANIEL-WYSE']
>>
>> hosts, their running nodes and ports:
>>
>> - DANIEL-WYSE: [{'RabbitMQ',1898},{rabbitmqctl2558445,1904}]
>>
>> current node details:
>>
>> - node name: 'rabbitmqctl2558445 at DANIEL-WYSE'
>>
>> - home dir: C:Docements and Settings\Administrator
>>
>> - cookie hash: ak3qKWQRwDfzEGk9nwYiVQ==
>>
>> All this works great when I start an interactive Server using 
>> rabbitmq-server.bat  (however when I use the -detach option, it fails 
>> exactly like rabbitmq-service.bat)
>>
>> The environment variables appear to be set identically in both the 
>> service and the server.
>>
>> rabbitmq-service.bat list      returns:
>>
>> Service name: RabbitMQ
>>
>> StopAction:
>>
>> OnFail: ignore
>>
>> Machine: c:\progra~1\ticketmaster\tmds\erlang\erts-5.9.2\bin\erl.exe
>>
>> WorkDir:
>>
>> SName: RabbitMQ
>>
>> Priority: default
>>
>> DebugType: none
>>
>> Args:
>>
>> InternalServiceName: RabbitMQ
>>
>> Comment:
>>
>> Env:
>>
>> I have disabled the windows firewall (this probably wasn't the issue 
>> anyway because I had it configured so that the server worked fine).
>>
>> Any suggestions what I should try next?
>>
>> Thanks
>>
>>
>>
>> _______________________________________________
>> rabbitmq-discuss mailing list
>> rabbitmq-discuss at lists.rabbitmq.com
>> https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>>
>
>
> --
> Simon MacMullen
> RabbitMQ, VMware
>


--
Simon MacMullen
RabbitMQ, VMware
_______________________________________________
rabbitmq-discuss mailing list
rabbitmq-discuss at lists.rabbitmq.com
https://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss


More information about the rabbitmq-discuss mailing list