]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crush/CrushWrapper: rebuild shadow tree on 'osd crush reweight-subtree' 39920/head
authorSage Weil <sage@newdream.net>
Tue, 23 Feb 2021 15:15:01 +0000 (09:15 -0600)
committerNathan Cutler <ncutler@suse.com>
Mon, 8 Mar 2021 17:06:55 +0000 (18:06 +0100)
Signed-off-by: Sage Weil <sage@newdream.net>
(cherry picked from commit 9115c62ad2239d5122d8cd73cece54c1b122487a)

src/crush/CrushWrapper.cc

index 1e87635c5cb054c02f867adf21687ac56e587d18..69475c56f776370421abd9c627befd6544612aee 100644 (file)
@@ -1565,6 +1565,12 @@ int CrushWrapper::adjust_subtree_weight(CephContext *cct, int id, int weight,
       }
     }
   }
+  int ret = rebuild_roots_with_classes(cct);
+  if (ret < 0) {
+    ldout(cct, 0) << __func__ << " unable to rebuild roots with classes: "
+                 << cpp_strerror(ret) << dendl;
+    return ret;
+  }
   return changed;
 }