尝试运行RabbitMQ时出现Erlang错误

3

我正在尝试在Windows 7 64位系统中安装带有Erlang的RabbitMQ。我正在安装:

R16B01 Windows 64 Bit Binary File
rabbitmq-server-3.1.5.exe

我逐步按照这个教程的步骤进行了操作。

http://www.youtube.com/watch?v=x9wwZAuub1w

但是在运行命令:"rabbitmq-plugins enable rabbitmq_management" 时,会出现以下错误:
{error_logger,{{2013,9,12},{13,23,53}},"Failed to create cookie file 'z:/.erlang
.cookie': enoent",[]}
{error_logger,{{2013,9,12},{13,23,53}},crash_report,[[{initial_call,{auth,init,[
'Argument__1']}},{pid,<0.19.0>},{registered_name,[]},{error_info,{exit,{"Failed
to create cookie file 'z:/.erlang.cookie': enoent",[{auth,init_cookie,0,[{file,"
auth.erl"},{line,285}]},{auth,init,1,[{file,"auth.erl"},{line,139}]},{gen_server
,init_it,6,[{file,"gen_server.erl"},{line,304}]},{proc_lib,init_p_do_apply,3,[{f
ile,"proc_lib.erl"},{line,239}]}]},[{gen_server,init_it,6,[{file,"gen_server.erl
"},{line,328}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239}]}]
}},{ancestors,[net_sup,kernel_sup,<0.10.0>]},{messages,[]},{links,[<0.17.0>]},{d
ictionary,[]},{trap_exit,true},{status,running},{heap_size,610},{stack_size,27},
{reductions,951}],[]]}
{error_logger,{{2013,9,12},{13,23,53}},supervisor_report,[{supervisor,{local,net
_sup}},{errorContext,start_error},{reason,{"Failed to create cookie file 'z:/.er
lang.cookie': enoent",[{auth,init_cookie,0,[{file,"auth.erl"},{line,285}]},{auth
,init,1,[{file,"auth.erl"},{line,139}]},{gen_server,init_it,6,[{file,"gen_server
.erl"},{line,304}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,239
}]}]}},{offender,[{pid,undefined},{name,auth},{mfargs,{auth,start_link,[]}},{res
tart_type,permanent},{shutdown,2000},{child_type,worker}]}]}
{error_logger,{{2013,9,12},{13,23,53}},supervisor_report,[{supervisor,{local,ker
nel_sup}},{errorContext,start_error},{reason,{shutdown,{failed_to_start_child,au
th,{"Failed to create cookie file 'z:/.erlang.cookie': enoent",[{auth,init_cooki
e,0,[{file,"auth.erl"},{line,285}]},{auth,init,1,[{file,"auth.erl"},{line,139}]}
,{gen_server,init_it,6,[{file,"gen_server.erl"},{line,304}]},{proc_lib,init_p_do
_apply,3,[{file,"proc_lib.erl"},{line,239}]}]}}}},{offender,[{pid,undefined},{na
me,net_sup},{mfargs,{erl_distribution,start_link,[]}},{restart_type,permanent},{
shutdown,infinity},{child_type,supervisor}]}]}
{error_logger,{{2013,9,12},{13,23,53}},crash_report,[[{initial_call,{application
_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0
.9.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,
net_sup,{shutdown,{failed_to_start_child,auth,{"Failed to create cookie file 'z:
/.erlang.cookie': enoent",[{auth,init_cookie,0,[{file,"auth.erl"},{line,285}]},{
auth,init,1,[{file,"auth.erl"},{line,139}]},{gen_server,init_it,6,[{file,"gen_se
rver.erl"},{line,304}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line
,239}]}]}}}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"ap
plication_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib
.erl"},{line,239}]}]}},{ancestors,[<0.8.0>]},{messages,[{'EXIT',<0.10.0>,normal}
]},{links,[<0.8.0>,<0.7.0>]},{dictionary,[]},{trap_exit,true},{status,running},{
heap_size,610},{stack_size,27},{reductions,150}],[]]}
{error_logger,{{2013,9,12},{13,23,53}},std_info,[{application,kernel},{exited,{{
shutdown,{failed_to_start_child,net_sup,{shutdown,{failed_to_start_child,auth,{"
Failed to create cookie file 'z:/.erlang.cookie': enoent",[{auth,init_cookie,0,[
{file,"auth.erl"},{line,285}]},{auth,init,1,[{file,"auth.erl"},{line,139}]},{gen
_server,init_it,6,[{file,"gen_server.erl"},{line,304}]},{proc_lib,init_p_do_appl
y,3,[{file,"proc_lib.erl"},{line,239}]}]}}}}},{kernel,start,[normal,[]]}}},{type
,permanent}]}
{"Kernel pid terminated",application_controller,"{application_start_failure,kern
el,{{shutdown,{failed_to_start_child,net_sup,{shutdown,{failed_to_start_child,au
th,{\"Failed to create cookie file 'z:/.erlang.cookie': enoent\",[{auth,init_coo
kie,0,[{file,\"auth.erl\"},{line,285}]},{auth,init,1,[{file,\"auth.erl\"},{line,
139}]},{gen_server,init_it,6,[{file,\"gen_server.erl\"},{line,304}]},{proc_lib,i
nit_p_do_apply,3,[{file,\"proc_lib.erl\"},{line,239}]}]}}}}},{kernel,start,[norm
al,[]]}}}"}

Crash dump was written to: erl_crash.dump
Kernel pid terminated (application_controller) ({application_start_failure,kerne
l,{{shutdown,{failed_to_start_child,net_sup,{shutdown,{failed_to_start_child,aut
h,{"Failed to create cookie file 'z:/.

为什么尝试访问Z:/目录?我已经在配置文件中搜索过了,但找不到它。

在谷歌上搜索过,但没有一个能解决我的问题。

同时,我已经设置了ERLANG_HOME和RABBITMQ_SERVER这两个环境变量,其中:

ERLANG_HOME: C:\Program Files\erl5.10.2

RABBITMQ_SERVER: C:\rabbitmq_server-3.1.5

有人遇到这个问题吗?你们是如何解决的?
谢谢。

请参考这个问题,尽管它似乎从未得到过正确的答案。 - legoscia
2
可能是在Windows中创建RabbitMQ Cookie文件失败的重复问题。 - Ashutosh Srivastav
已经在此解决:https://dev59.com/mmMl5IYBdhLWcg3wVlpf#29018928 - Espresso
1个回答

5

根据这个邮件列表线程,你需要设置HOMEDRIVEHOMEPATH环境变量,使它们在连接时指向您的主目录。 假设由于某种原因HOMEDRIVE被设置为z:


感谢提供的信息。尽管在安装rabbitmq可执行文件时出现了问题,但使用.zip版本后重新启动计算机,一切都正常了。感谢您的帮助。 - msqar

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接