清晰的理解pg与pgp之间的关系

这里先说下ceph中PG和PGP使用的一个典型场景,ceph中PG数是可以修改的,但是目前只能从小到大修改 ,那么就会有一种情况PG数修改变大后就会存在PG分裂的场景。如源集群PG为PG1/2/3  修改PG数为PG1/2/3/4/5后ceph为了保证存储数据平滑分裂引入PGP概念,PGP就是用来保存分裂前PG的状态,意为PG初始状态或PG祖先。所以修改PG数后PG分布不回引起太大的变化,但如果同时修改PG和PGP将引起集群数据大规模迁移,请结合上述理解以下文章内容

一、前言

首先来一段英文关于PG和PGP区别的解释:

PG = Placement Group
PGP = Placement Group for Placement purpose

pg_num = number of placement groups mapped to an OSD

When pg_num is increased for any pool, every PG of this pool splits into half, but they all remain mapped to their parent OSD.

Until this time, Ceph does not start rebalancing. Now, when you increase the pgp_num value for the same pool, PGs start to migrate from the parent to some other OSD, and cluster rebalancing starts. This is how PGP plays an important role.
By Karan Singh

  • 2
    点赞
  • 4
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值