]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/PeeringState: fix get_backfill_priority min_size comparison
authorSamuel Just <sjust@redhat.com>
Fri, 2 Apr 2021 23:06:14 +0000 (23:06 +0000)
committerNathan Cutler <ncutler@suse.com>
Sat, 10 Apr 2021 18:09:03 +0000 (20:09 +0200)
acting has placeholders for ec, need to use actingset.

Signed-off-by: Samuel Just <sjust@redhat.com>
(cherry picked from commit 7b2e0f4fd1c9071495dae9189428aa1cb8774c30)

src/osd/PeeringState.cc

index a1ccfea9ab4547ffe18a61833684b3514955fb34..6274d2959ab5e5de98b51f7f2b744801b1346028 100644 (file)
@@ -1054,10 +1054,10 @@ unsigned PeeringState::get_backfill_priority()
   if (state & PG_STATE_FORCED_BACKFILL) {
     ret = OSD_BACKFILL_PRIORITY_FORCED;
   } else {
-    if (acting.size() < pool.info.min_size) {
+    if (actingset.size() < pool.info.min_size) {
       base = OSD_BACKFILL_INACTIVE_PRIORITY_BASE;
       // inactive: no. of replicas < min_size, highest priority since it blocks IO
-      ret = base + (pool.info.min_size - acting.size());
+      ret = base + (pool.info.min_size - actingset.size());
 
     } else if (is_undersized()) {
       // undersized: OSD_BACKFILL_DEGRADED_PRIORITY_BASE + num missing replicas