Rabbitmq 启动失败 [英] Rabbitmq start fails
问题描述
我的RabbitMQ服务器宕机了,无法重启.我试图重新启动,重新安装它......我仍然不明白错误.这是我得到的
My RabbitMQ server went down and it is impossible to restart it. I tried to restart, reinstall it... I still don't understand the error. This is what I get
BOOT FAILED
===========
Error description:
{could_not_start,rabbit,
{bad_return,
{{rabbit,start,[normal,[]]},
{'EXIT',
{rabbit,failure_during_boot,
{badmatch,
{error,
{{{function_clause,
[{rabbit_queue_index,journal_minus_segment1,
[{no_pub,del,no_ack},
{{<<115,254,171,167,171,226,110,171,251,38,217,145,3,12,215,151>>,
{message_properties,1409712663123302,false},
true},
del,ack}],
[{file,"src/rabbit_queue_index.erl"},{line,989}]},
{rabbit_queue_index,'-journal_minus_segment/2-fun-0-',4,
[{file,"src/rabbit_queue_index.erl"},{line,973}]},
{array,sparse_foldl_3,7,[{file,"array.erl"},{line,1675}]},
{array,sparse_foldl_2,9,[{file,"array.erl"},{line,1669}]},
{rabbit_queue_index,'-recover_journal/1-fun-0-',1,
[{file,"src/rabbit_queue_index.erl"},{line,701}]},
{lists,map,2,[{file,"lists.erl"},{line,1224}]},
{rabbit_queue_index,segment_map,2,
[{file,"src/rabbit_queue_index.erl"},{line,819}]},
{rabbit_queue_index,recover_journal,1,
[{file,"src/rabbit_queue_index.erl"},{line,693}]}]},
{gen_server2,call,[<0.186.0>,out,infinity]}},
{child,undefined,msg_store_persistent,
{rabbit_msg_store,start_link,
[msg_store_persistent,
"/var/lib/rabbitmq/mnesia/rabbit@host",[],
{#Fun<rabbit_queue_index.2.132977059>,
{start,
[{resource,<<"/">>,queue,
<<"photos_to_be_tagged_user_36">>}]}}]},
transient,4294967295,worker,
[rabbit_msg_store]}}}}}}}}}
有人可以帮忙吗?
非常感谢
推荐答案
对于寻找此错误的任何其他人来说,failure_during_boot,
For anyone else looking for this error rabbit,failure_during_boot,
{badmatch,
{error,
{{{function_clause,
[{rabbit_queue_index,journal_minus_segment1, ...
我刚刚处理了同样的问题,有什么帮助是转到 mnesia 目录并删除队列和 msg_store_transient 目录.
I just dealt with the same issue and what helped was going to the mnesia directories and deleting the queues and msg_store_transient directories.
据我所知,发生的情况是您最终得到了一个错误的队列数据库(无论出于何种原因 - 即突然断电,其他一些进程接触到文件),rabbitmq 无法解析它,因此它崩溃了.清除消息队列后,它就可以正常工作了.
From what I understand, what happens is that you end up with a bad queue db (for whatever reason -i.e. a sudden power failure, some other process touches the files) which rabbitmq can't parse and so it crashes. Once you clear the queue of messages, it works fine.
这篇关于Rabbitmq 启动失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!