]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
crush: update choose_args on bucket removal, resize, or position mismatch
authorSage Weil <sage@redhat.com>
Fri, 18 May 2018 18:11:57 +0000 (13:11 -0500)
committerSage Weil <sage@redhat.com>
Fri, 18 May 2018 22:12:22 +0000 (17:12 -0500)
commit564ef28a4014cb5d9959b1925154bbf7863fd0d4
tree6600600106246adbe70e5b8e0c3e45a1a7a47c5a
parentd8d08b8cbf5b0ad3646dd1e177a1418e96273244
crush: update choose_args on bucket removal, resize, or position mismatch

The specific bug I see is that a bucket no longer exists but its
choose_args still does.  However, I'm also taking the opportunity to
verify that the choose_args agrees with the bucket sizes and position
counts everywhere else, too.  Check for

- ids or weight_sets for buckets that don't exist or aren't straw2
- weight_set_positions that don't match the choose_args
- weight_set sizes that don't match the bucket size

Fixes: http://tracker.ceph.com/issues/24167
Signed-off-by: Sage Weil <sage@redhat.com>
src/crush/CrushWrapper.cc
src/crush/CrushWrapper.h