我正在用Docker和image 'ceph/daemon:v3.1.0-stable-3.1-luminous-centos-7'.建立一个Ceph集群但是,在设置了集群之后,ceph status命令永远不会到达HEALTH_OK。这是我的集群信息。它有足够的磁盘空间和网络是正常的。
我的问题是:
非常感谢!
➜ ~ ceph -s
cluster:
id: 483a61c4-d3c7-424d-b96b-311d2c6eb69b
health: HEALTH_WARN
Degraded data redundancy: 3 pgs undersized
services:
mon: 3 daemons, quorum pc-10-10-0-13,pc-10-10-0-89,pc-10-10-0-160
mgr: pc-10-10-0-89(active), standbys: pc-10-10-0-13, pc-10-10-0-160
mds: cephfs-1/1/1 up {0=pc-10-10-0-160=up:active}, 2 up:standby
osd: 5 osds: 5 up, 5 in
rbd-mirror: 3 daemons active
rgw: 3 daemons active
data:
pools: 6 pools, 68 pgs
objects: 212 objects, 5.27KiB
usage: 5.02GiB used, 12.7TiB / 12.7TiB avail
pgs: 65 active+clean
3 active+undersized
➜ ~ ceph osd tree
ID CLASS WEIGHT TYPE NAME STATUS REWEIGHT PRI-AFF
-1 12.73497 root default
-5 0.90959 host pc-10-10-0-13
3 hdd 0.90959 osd.3 up 1.00000 1.00000
-7 0.90959 host pc-10-10-0-160
4 hdd 0.90959 osd.4 up 1.00000 1.00000
-3 10.91579 host pc-10-10-0-89
0 hdd 3.63860 osd.0 up 1.00000 1.00000
1 hdd 3.63860 osd.1 up 1.00000 1.00000
2 hdd 3.63860 osd.2 up 1.00000 1.00000
➜ ~ ceph osd pool ls detail
pool 1 'cephfs_data' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 8 pgp_num 8 last_change 24 flags hashpspool stripe_width 0 application cephfs
pool 2 'cephfs_metadata' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 8 pgp_num 8 last_change 24 flags hashpspool stripe_width 0 application cephfs
pool 3 '.rgw.root' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 13 pgp_num 13 last_change 27 flags hashpspool stripe_width 0 application rgw
pool 4 'default.rgw.control' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 13 pgp_num 13 last_change 30 flags hashpspool stripe_width 0 application rgw
pool 5 'default.rgw.meta' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 13 pgp_num 13 last_change 32 owner 18446744073709551615 flags hashpspool stripe_width 0 application rgw
pool 6 'default.rgw.log' replicated size 3 min_size 2 crush_rule 0 object_hash rjenkins pg_num 13 pgp_num 13 last_change 34 flags hashpspool stripe_width 0 application rgw发布于 2018-10-02 14:04:35
@itsafire --这不是解决办法。他要求的是解决方案,而不是硬件推荐。
我运行8个节点和5个节点多个CEPH集群。我总是使用带有多个压缩映射的2个副本(用于SSD、SAS和72k驱动器)
如果使用资源有限的小型集群,为什么需要3个副本?
你能解释一下为什么我的解决方案会导致灾难吗?你的名声很好,我不知道你是怎么得到的。也许只是回复推荐而不是解决方案。
发布于 2018-09-19 20:55:09
创建一个大小为2和Min大小为1的新池。
对于pg-num,使用Ceph计算器https://ceph.com/pgcalc/。
发布于 2018-09-17 12:17:15
您似乎创建了一个具有不同osd配置和大小的三个节点集群。标准的挤压规则告诉C年会在不同的主机上有3张PG的副本。如果没有足够的空间将PG分散到三个主机上,那么您的集群就永远不会健康。
从一组大小相等的主机(RAM、CPU、OSD)开始总是一个好主意。
讨论大小为2vs3的集群的更新
不要使用两个副本。Ceph最初的大小默认值为2,但在Ceph0.82(萤火虫版本)中,这个值被更改为3。
为什么?因为如果一个驱动器发生故障,则只剩下一个包含数据的驱动器。如果这个驱动器在恢复运行时也失败了,那么您的数据就会永远消失。
请参阅此线程位于C年会用户邮件列表上。
无论集群有多大或多小,复制都不安全。随着磁盘变得更大,恢复时间将增加。在那个窗口中,您不想在一个副本上运行。
https://stackoverflow.com/questions/52362394
复制相似问题