Merge pull request #1590 from ceph/wip-7939

PG: set role for replicated even if role != shard

Reviewed-by: Sage Weil <sage@inktank.com>
This commit is contained in:
Sage Weil 2014-04-02 10:52:11 -07:00
commit 250a10296b

View File

@ -4655,7 +4655,7 @@ void PG::start_peering_interval(
state_clear(PG_STATE_REMAPPED);
int role = osdmap->calc_pg_role(osd->whoami, acting, acting.size());
if (role == pg_whoami.shard)
if (pool.info.is_replicated() || role == pg_whoami.shard)
set_role(role);
else
set_role(-1);