我是靠谱客的博主 紧张哈密瓜,最近开发中收集的这篇文章主要介绍rabbitmq启动报错 failed_to_start_child,auth,{“Cookie file.erlang.cookie must be accessible by owner only,觉得挺不错的,现在分享给大家,希望可以做个参考。
概述
????’???? ????????????, ???? ???????? ???? ???????????????????????????????? ???????????????????????????? ???????????????? ????????????????????????????, ????????????????????.
- ???? ????????????????????????: ???????????????????? ????????????????????????????????????????
- ???? ????????????????????????????????: ????’???? ???????????????????????????????????? ???????????????????????????????? ???????????????????????? ????????????????????????????, ????????????????????????????????, ???????????????????????????????????????????? ????????????????????????, ???????????????????????????????????????? ???????????? ???????? ????????.
- ???? ???????????? ???????? ???????????????????? ????????:????????
- ???? ???????? ????????????????: ????????????????????://????????????????????????????.????????????????.????????????????.????????????/
- ???? ???????????????????????????????????????????????? ????????????????????????:???????? ????????????????????
问题描述
rabbitmq1 | 2022-01-16 15:07:46.501437+00:00 [erro] <0.145.0> Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> supervisor: {local,net_sup}
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> errorContext: start_error
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> reason: {"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> [{auth,init_no_setcookie,0,[{file,"auth.erl"},{line,293}]},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {auth,init,1,[{file,"auth.erl"},{line,144}]},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {gen_server,init_it,2,[{file,"gen_server.erl"},{line,423}]},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {gen_server,init_it,6,[{file,"gen_server.erl"},{line,390}]},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {proc_lib,init_p_do_apply,3,
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> [{file,"proc_lib.erl"},{line,226}]}]}
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> offender: [{pid,undefined},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {id,auth},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {mfargs,{auth,start_link,[]}},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {restart_type,permanent},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {significant,false},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {shutdown,2000},
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0> {child_type,worker}]
rabbitmq1 | 2022-01-16 15:07:46.506942+00:00 [erro] <0.143.0>
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> crasher:
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> initial call: auth:init/1
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> pid: <0.145.0>
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> registered_name: []
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> exception error: "Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only"
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> in function auth:init_no_setcookie/0 (auth.erl, line 293)
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> in call from auth:init/1 (auth.erl, line 144)
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> in call from gen_server:init_it/2 (gen_server.erl, line 423)
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> in call from gen_server:init_it/6 (gen_server.erl, line 390)
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> ancestors: [net_sup,kernel_sup,<0.47.0>]
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> message_queue_len: 0
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> messages: []
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> links: [<0.143.0>]
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> dictionary: []
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> trap_exit: true
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> status: running
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> heap_size: 610
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> stack_size: 29
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> reductions: 2016
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0> neighbours:
rabbitmq1 | 2022-01-16 15:07:46.507008+00:00 [erro] <0.145.0>
rabbitmq1 |
rabbitmq1 | BOOT FAILED
rabbitmq1 | ===========
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0>
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> BOOT FAILED
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> ===========
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> Exception during startup:
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0>
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> error:{badmatch,{error,{{shutdown,{failed_to_start_child,auth,{"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",[{auth,init_no_setcookie,0,[{file,"auth.erl"},{line,293}]},{auth,init,1,[{file,"auth.erl"},{line,144}]},{gen_server,init_it,2,[{file,"gen_server.erl"},{line,423}]},{gen_server,init_it,6,[{file,"gen_server.erl"},{line,390}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,226}]}]}}},{child,undefined,net_sup_dynamic,{erl_distribution,start_link,[[rabbit_prelaunch_21@localhost,shortnames],false,net_sup_dynamic]},permanent,false,1000,supervisor,[erl_distribution]}}}}
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0>
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> rabbit_prelaunch_dist:duplicate_node_check/1, line 78
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> rabbit_prelaunch_dist:setup/1, line 23
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> rabbit_prelaunch:do_run/0, line 115
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> rabbit_prelaunch:run_prelaunch_first_phase/0, line 32
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> supervisor:do_start_child_i/3, line 414
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> supervisor:do_start_child/2, line 400
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> supervisor:-start_children/2-fun-0-/3, line 384
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0> supervisor:children_map/4, line 1250
rabbitmq1 | 2022-01-16 15:07:46.510413+00:00 [erro] <0.130.0>
rabbitmq1 | Exception during startup:
rabbitmq1 |
rabbitmq1 | error:{badmatch,{error,{{shutdown,{failed_to_start_child,auth,{"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",[{auth,init_no_setcookie,0,[{file,"auth.erl"},{line,293}]},{auth,init,1,[{file,"auth.erl"},{line,144}]},{gen_server,init_it,2,[{file,"gen_server.erl"},{line,423}]},{gen_server,init_it,6,[{file,"gen_server.erl"},{line,390}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,226}]}]}}},{child,undefined,net_sup_dynamic,{erl_distribution,start_link,[[rabbit_prelaunch_21@localhost,shortnames],false,net_sup_dynamic]},permanent,false,1000,supervisor,[erl_distribution]}}}}
rabbitmq1 |
rabbitmq1 | rabbit_prelaunch_dist:duplicate_node_check/1, line 78
rabbitmq1 | rabbit_prelaunch_dist:setup/1, line 23
rabbitmq1 | rabbit_prelaunch:do_run/0, line 115
rabbitmq1 | rabbit_prelaunch:run_prelaunch_first_phase/0, line 32
rabbitmq1 | supervisor:do_start_child_i/3, line 414
rabbitmq1 | supervisor:do_start_child/2, line 400
rabbitmq1 | supervisor:-start_children/2-fun-0-/3, line 384
rabbitmq1 | supervisor:children_map/4, line 1250
rabbitmq1 |
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> supervisor: {local,rabbit_prelaunch_sup}
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> errorContext: start_error
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> reason: {badmatch,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {error,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {{shutdown,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {failed_to_start_child,auth,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {"Cookie file /var/lib/rabbitmq/.erlang.cookie must be accessible by owner only",
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> [{auth,init_no_setcookie,0,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> [{file,"auth.erl"},{line,293}]},
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {auth,init,1,[{file,"auth.erl"},{line,144}]},
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.130.0> {gen_server,init_it,2,
rabbitmq1 | 2022-01-16 15:07:47.513680+00:00 [erro] <0.
问题解决
总的来说就是由于移动了data,从一个PC移动到了另一个PC上,导致文件权限出现了问题,所以我们将文件权限修改成700,并且更改拥有者为root,再用root启动就没事了。
最后
以上就是紧张哈密瓜为你收集整理的rabbitmq启动报错 failed_to_start_child,auth,{“Cookie file.erlang.cookie must be accessible by owner only的全部内容,希望文章能够帮你解决rabbitmq启动报错 failed_to_start_child,auth,{“Cookie file.erlang.cookie must be accessible by owner only所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
发表评论 取消回复