]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Objecter: resend op if primary role changed
authorSamuel Just <sam.just@inktank.com>
Fri, 21 Feb 2014 19:59:04 +0000 (11:59 -0800)
committerSamuel Just <sam.just@inktank.com>
Sat, 22 Feb 2014 20:37:50 +0000 (12:37 -0800)
Fixes: #7508
Signed-off-by: Samuel Just <sam.just@inktank.com>
src/osdc/Objecter.cc

index 28243ea4f423edf9be8b82c914eac21e400ac754..fb80f3c85252580778f8f5164c32932f9d702b36 100644 (file)
@@ -1387,6 +1387,9 @@ bool Objecter::is_pg_changed(
     return true;     // was empty, now not, or vice versa
   if (oldprimary != newprimary)
     return true;     // primary changed
+  if (OSDMap::calc_pg_rank(oldprimary, oldacting) !=
+      OSDMap::calc_pg_rank(newprimary, newacting))
+    return true;
   if (any_change && oldacting != newacting)
     return true;
   return false;      // same primary (tho replicas may have changed)