2

今天是个好日子,

我已经建立了一个包含三个虚拟机的测试环境,以便能够部署一个 ceph 集群。这些机器都与CentOS7 64位相同。我在所有这些上都安装了 ceph,并在节点一上部署了 ceph。我在 ceph-node1 上安装了初始监视器,但是当我尝试在 ceph-node2 上安装时,我收到一个错误,我无法通过它。我不确定如何解决此问题。有任何想法吗?

[root@ceph-node1 ~]# ceph-deploy mon create ceph-node2
[ceph_deploy.conf][DEBUG ] found configuration file at: /root/.cephdeploy.conf
[ceph_deploy.cli][INFO  ] Invoked (1.5.25): /usr/bin/ceph-deploy mon create ceph-node2
[ceph_deploy.mon][DEBUG ] Deploying mon, cluster ceph hosts ceph-node2
[ceph_deploy.mon][DEBUG ] detecting platform for host ceph-node2 ...
[ceph-node2][DEBUG ] connected to host: ceph-node2
[ceph-node2][DEBUG ] detect platform information from remote host
[ceph-node2][DEBUG ] detect machine type
[ceph_deploy.mon][INFO  ] distro info: CentOS Linux 7.2.1511 Core
[ceph-node2][DEBUG ] determining if provided host has same hostname in remote
[ceph-node2][DEBUG ] get remote short hostname
[ceph-node2][DEBUG ] deploying mon to ceph-node2
[ceph-node2][DEBUG ] get remote short hostname
[ceph-node2][DEBUG ] remote hostname: ceph-node2
[ceph-node2][DEBUG ] write cluster configuration to /etc/ceph/{cluster}.conf
[ceph-node2][DEBUG ] create the mon path if it does not exist
[ceph-node2][DEBUG ] checking for done path: /var/lib/ceph/mon/ceph-ceph-node2/done
[ceph-node2][DEBUG ] create a done file to avoid re-doing the mon deployment
[ceph-node2][DEBUG ] create the init path if it does not exist
[ceph-node2][DEBUG ] locating the `service` executable...
[ceph-node2][INFO  ] Running command: /usr/sbin/service ceph -c /etc/ceph/ceph.conf start mon.ceph-node2
[ceph-node2][DEBUG ] === mon.ceph-node2 ===
[ceph-node2][DEBUG ] Starting Ceph mon.ceph-node2 on ceph-node2...
[ceph-node2][WARNIN] Running as unit ceph-mon.ceph-node2.1460047679.725134876.service.
[ceph-node2][DEBUG ] Starting ceph-create-keys on ceph-node2...
[ceph-node2][INFO  ] Running command: systemctl enable ceph
[ceph-node2][WARNIN] ceph.service is not a native service, redirecting to /sbin/chkconfig.
[ceph-node2][WARNIN] Executing /sbin/chkconfig ceph on
[ceph-node2][INFO  ] Running command: ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.ceph-node2.asok mon_status
[ceph-node2][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory
[ceph-node2][WARNIN] monitor: mon.ceph-node2, might not be running yet
[ceph-node2][INFO  ] Running command: ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.ceph-node2.asok mon_status
[ceph-node2][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory
[ceph-node2][WARNIN] ceph-node2 is not defined in `mon initial members`
[ceph-node2][WARNIN] monitor ceph-node2 does not exist in monmap
[ceph-node2][WARNIN] neither `public_addr` nor `public_network` keys are defined for monitors
[ceph-node2][WARNIN] monitors may not be able to form quorum
4

4 回答 4

2

最终解决方案应符合警告信息: [ceph-node2][WARNIN] 既未public_addrpublic_network监视器定义也未定义密钥

所以解决方案是将 public_addr 添加到 ceph.conf 文件中,如下所示: public_network = 192.168.111.0/24

于 2017-05-03T01:53:04.170 回答
0

我在 Octopus 中遇到了同样的问题,因为 node3 上的 mon 容器无法以错误开始:

no public_addr or public_network specified, and mon.node3 not present in monmap or ceph.conf

不幸的是,我还没有弄清楚它发生的真正技术原因,只是删除了守护进程mon.node3

ceph orch daemon rm mon.node3 --force

等到 ceph 重新创建它。

于 2020-07-26T15:02:49.030 回答
0

Ceph 在虚拟服务器上表现不佳。我已经在 VMWare 上测试了 Luminous 和 Mimic。作为裸机,您不会获得相关结果(特别是对于 I/O)...

至于上面的错误,你应该在每台服务器上有 2 个网卡。您提供给客户的一份公开资料和一份私人资料供 ceph 重新平衡数据。

还要记住在您的服务器上具有 FQDN 名称...

于 2020-06-11T21:41:33.870 回答
0

我有同样的问题,我的所有设置都是正确的。在所有节点上禁用防火墙和 Selinux 后,我的问题解决了。顺便说一句,更改 Selinux 设置后,您应该重新启动系统以影响

于 2021-10-03T11:36:12.393 回答