ceph 安装ceph问题汇总

Posted kuku0223

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了ceph 安装ceph问题汇总相关的知识,希望对你有一定的参考价值。

1、在不同节点安装ceph时,出现以下异常:
参考这里

ceph deploy RuntimeError: NoSectionError: No section: ‘ceph‘

解决方法:

在报错的机器上尝试:
yum remove ceph-release
rm  /etc/yum.repos.d/ceph.repo.rpmsave

执行以后再执行

ceph-deploy install admin  node1 node2 node3

2、ceph用户没有权限
**执行激活osd盘时出现 **

ceph-deploy osd activate node2:/var/local/osd0 node3:/var/local/osd1
[node3][WARNIN] ceph_disk.main.Error: Error: [‘ceph-osd‘, ‘--cluster‘, ‘ceph‘, ‘--mkfs‘, ‘--mkkey‘, ‘-i‘, ‘1‘, ‘--monmap‘, ‘/var/local/osd1/activate.monmap‘, ‘--osd-data‘, ‘/var/local/osd1‘, ‘--osd-journal‘, ‘/var/local/osd1/journal‘, ‘--osd-uuid‘, ‘ee9c4a6c-e2b5-46cd-9e91-fd5d6f36fd57‘, ‘--keyring‘, ‘/var/local/osd1/keyring‘, ‘--setuser‘, ‘ceph‘, ‘--setgroup‘, ‘ceph‘] failed : 2016-08-31 16:38:58.909449 7f48adbb7800 -1 filestore(/var/local/osd1) mkfs: write_version_stamp() failed: (13) Permission denied
[node3][WARNIN] 2016-08-31 16:38:58.909475 7f48adbb7800 -1 OSD::mkfs: ObjectStore::mkfs failed with error -13
[node3][WARNIN] 2016-08-31 16:38:58.909529 7f48adbb7800 -1  ** ERROR: error creating empty object store in /var/local/osd1: (13) Permission denied
[node3][WARNIN]
[node3][ERROR ] RuntimeError: command returned non-zero exit status: 1
[ceph_deploy][ERROR ] RuntimeError: Failed to execute command: /usr/sbin/ceph-disk -v activate --mark-init systemd --mount /var/local/osd1

解决方法

chown ceph:ceph  /var/local/osd0
chown ceph:ceph  /var/local/osd1

 
技术分享图片
创建成功ceph健康状况良好

3、RuntimeError: bootstrap-rgw keyring not found; run ‘gatherkeys‘

[email protected] ceph]# ceph-deploy rgw create node2
[ceph_deploy.conf][DEBUG ] found configuration file at: /root/.cephdeploy.conf
[ceph_deploy.cli][INFO  ] Invoked (1.5.34): /usr/bin/ceph-deploy rgw create node2
[ceph_deploy.cli][INFO  ] ceph-deploy options:
[ceph_deploy.cli][INFO  ]  username                      : None
[ceph_deploy.cli][INFO  ]  verbose                       : False
[ceph_deploy.cli][INFO  ]  rgw                           : [(‘node2‘, ‘rgw.node2‘)]
[ceph_deploy.cli][INFO  ]  overwrite_conf                : False
[ceph_deploy.cli][INFO  ]  subcommand                    : create
[ceph_deploy.cli][INFO  ]  quiet                         : False
[ceph_deploy.cli][INFO  ]  cd_conf                       : <ceph_deploy.conf.cephdeploy.Conf instance at 0x24aed88>
[ceph_deploy.cli][INFO  ]  cluster                       : ceph
[ceph_deploy.cli][INFO  ]  func                          : <function rgw at 0x241da28>
[ceph_deploy.cli][INFO  ]  ceph_conf                     : None
[ceph_deploy.cli][INFO  ]  default_release               : False
[ceph_deploy.rgw][DEBUG ] Deploying rgw, cluster ceph hosts node2:rgw.node2
[ceph_deploy][ERROR ] RuntimeError: bootstrap-rgw keyring not found; run ‘gatherkeys‘

执行如下命令解决

ceph-deploy gatherkeys node2


作者:topwqp
链接:https://www.jianshu.com/p/bbd4545161b0
來源:简书
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。







以上是关于ceph 安装ceph问题汇总的主要内容,如果未能解决你的问题,请参考以下文章

常见问题汇总

通过ceph-deploy安装ceph的问题

文章汇总(包括NVMe SPDK vSAN Ceph xfs等)

ceph--Ceph 与 OpenStack 集成的实现

ceph 的安装和维护

使用ceph-deploy进行ceph安装