未为集群中的节点之一创建 Mnesia 文件夹

问题描述 投票:0回答:1

在尝试启动rabbitmq时,出现以下错误,并且我观察到主机1和2存在/var/lib/rabbitmq/mnesia目录,但主机3中不存在:

fatal: [host-3]: FAILED! => {"changed": true, "cmd": ["rabbitmqctl", "cluster_status"], "delta": "0:00:00.986969", "end": "2019-08-14 15:04:09.714266", "msg": "non-zero return code", "rc": 2, "start": "2019-08-14 15:04:08.727297", "stderr": "Error: {aborted,{bad_config,dir,\n                            \"/var/lib/rabbitmq/mnesia/rabbit@host-3\"}}", "stderr_lines": ["Error: {aborted,{bad_config,dir,", "                            \"/var/lib/rabbitmq/mnesia/rabbit@host-3\"}}"], "stdout": "Cluster status of node 'rabbit@host-3' ...", "stdout_lines": ["Cluster status of node 'rabbit@host-3' ..."]}
- name: Check RabbitMQ cluster
  command: rabbitmqctl cluster_status
  register: result

ansible rabbitmq
1个回答
0
投票

RabbitMQ 生成的配置似乎存在语法错误,导致 mnesia 目录值存在大量空格:

bad_config,dir,\n                            \"/var/lib/rabbitmq/mnesia/rabbit@host-3\"

我会仔细检查配置输入,并检查

/var/lib/rabbitmq/.../config/generated/rabbitmq.config
中生成的配置文件。

© www.soinside.com 2019 - 2024. All rights reserved.