]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
PG: set role for replicated even if role != shard 1590/head
authorSamuel Just <sam.just@inktank.com>
Tue, 1 Apr 2014 19:19:52 +0000 (12:19 -0700)
committerSamuel Just <sam.just@inktank.com>
Tue, 1 Apr 2014 19:19:57 +0000 (12:19 -0700)
Fixes: #7939
Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osd/PG.cc

index fab6981688f74c6043ef795b3c800430735ed7fa..55d791cbe9d38669c77fd3fa396cdd4205812ae4 100644 (file)
@@ -4644,7 +4644,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);