无法将初始监视器添加到Ubuntu中的Ceph

我正在尝试build立一个Ceph集群。 我有4个节点 – 1个pipe理节点,1个监视器和2个对象存储设备。 我正在使用的安装指南位于以下位置: http : //ceph.com/docs/master/start/quick-ceph-deploy/ 。

当我试图添加初始监视器(指南中的第5步),我收到以下错误:

[ceph_deploy.conf][DEBUG ] found configuration file at: /home/cloud-user/.cephdeploy.conf [ceph_deploy.cli][INFO ] Invoked (1.5.21): /usr/bin/ceph-deploy mon create-initial [ceph_deploy.mon][DEBUG ] Deploying mon, cluster ceph hosts worker-1-full [ceph_deploy.mon][DEBUG ] detecting platform for host worker-1-full ... [worker-1-full][DEBUG ] connection detected need for sudo [worker-1-full][DEBUG ] connected to host: worker-1-full [worker-1-full][DEBUG ] detect platform information from remote host [worker-1-full][DEBUG ] detect machine type [ceph_deploy.mon][INFO ] distro info: Ubuntu 14.04 trusty [worker-1-full][DEBUG ] determining if provided host has same hostname in remote [worker-1-full][DEBUG ] get remote short hostname [worker-1-full][DEBUG ] deploying mon to worker-1-full [worker-1-full][DEBUG ] get remote short hostname [worker-1-full][DEBUG ] remote hostname: worker-1-full [worker-1-full][DEBUG ] write cluster configuration to /etc/ceph/{cluster}.conf [worker-1-full][DEBUG ] create the mon path if it does not exist [worker-1-full][DEBUG ] checking for done path: /var/lib/ceph/mon/ceph-worker-1-full/done [worker-1-full][DEBUG ] create a done file to avoid re-doing the mon deployment [worker-1-full][DEBUG ] create the init path if it does not exist [worker-1-full][DEBUG ] locating the `service` executable... [worker-1-full][INFO ] Running command: sudo initctl emit ceph-mon cluster=ceph id=worker-1-full [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [worker-1-full][WARNIN] monitor: mon.worker-1-full, might not be running yet [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [worker-1-full][WARNIN] monitor worker-1-full does not exist in monmap [worker-1-full][WARNIN] neither `public_addr` nor `public_network` keys are defined for monitors [worker-1-full][WARNIN] monitors may not be able to form quorum [ceph_deploy.mon][INFO ] processing monitor mon.worker-1-full [worker-1-full][DEBUG ] connection detected need for sudo [worker-1-full][DEBUG ] connected to host: worker-1-full [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [ceph_deploy.mon][WARNIN] mon.worker-1-full monitor is not yet in quorum, tries left: 5 [ceph_deploy.mon][WARNIN] waiting 5 seconds before retrying [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [ceph_deploy.mon][WARNIN] mon.worker-1-full monitor is not yet in quorum, tries left: 4 [ceph_deploy.mon][WARNIN] waiting 10 seconds before retrying [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [ceph_deploy.mon][WARNIN] mon.worker-1-full monitor is not yet in quorum, tries left: 3 [ceph_deploy.mon][WARNIN] waiting 10 seconds before retrying [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [ceph_deploy.mon][WARNIN] mon.worker-1-full monitor is not yet in quorum, tries left: 2 [ceph_deploy.mon][WARNIN] waiting 15 seconds before retrying [worker-1-full][INFO ] Running command: sudo ceph --cluster=ceph --admin-daemon /var/run/ceph/ceph-mon.worker-1-full.asok mon_status [worker-1-full][ERROR ] admin_socket: exception getting command descriptions: [Errno 2] No such file or directory [ceph_deploy.mon][WARNIN] mon.worker-1-full monitor is not yet in quorum, tries left: 1 [ceph_deploy.mon][WARNIN] waiting 20 seconds before retrying [ceph_deploy.mon][ERROR ] Some monitors have still not reached quorum: [ceph_deploy.mon][ERROR ] worker-1-full 

“worker-1-full”是我试图设置为我的显示器的节点。 我用的命令是:

“ceph-deploy mon create-initial”。 请帮忙。 提前致谢!

我面临同样的错误是能够通过添加我的其他ceph节点的主机名和IpAdrress并通过添加“public_network =”来解决问题

我在ceph.conf中调整的部分是:

 mon_initial_members = mon_host = public_network = 

cat /etc/ceph/ceph.conf

 [global] fsid = 33cb5c76-a685-469e-8cdd-fee7c98c3f4d mon_initial_members = ceph1,ceph2 mon_host = 192.168.61.39,192.168.61.40 auth_cluster_required = cephx auth_service_required = cephx auth_client_required = cephx filestore_xattr_use_omap = true public_network = 192.168.61.0/24 

并运行命令:

 $ ceph-deploy --overwrite-conf mon create <ceph-node> 

看起来你的节点的名字和真正的主机名不同,所以/var/run/ceph/ceph-mon.worker-1-full.asok文件的名字不正确。 我已经改变了主机的名称,并为我工作。

/ var / run / ceph目录是否存在? 如果没有,那么Ceph可能将无法创build.asok(pipe理套接字)文件。

您可以在worker-1-full:/var/log/ceph/ceph-mon.worker-1-full.log检查MON日志worker-1-full:/var/log/ceph/ceph-mon.worker-1-full.log 。 如果MON没有出现或者无法创build套接字,应该在那里logging一些东西。