]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr/pg_autoscaler: treat target ratios as weights
authorJosh Durgin <jdurgin@redhat.com>
Sat, 1 Feb 2020 04:31:40 +0000 (23:31 -0500)
committerKefu Chai <kchai@redhat.com>
Mon, 10 Feb 2020 02:08:36 +0000 (10:08 +0800)
commit435c56a03b7424b23fe977a13c4704304189e829
tree421e5f7555d774bced1cdd7b1f670660d104ce18
parent67a2a4e7aa851a21c94415de4aaff655ae3bfaed
mgr/pg_autoscaler: treat target ratios as weights

Normalize across pools so that it's simpler to use - this way you
don't have to adjust every other pool when you add one.

Handle pools with target_bytes by taking their capacity off the top,
and dividing the rest into the pools with a target_ratio.

If both target bytes and ratio are specified, ignore bytes. This
matches the docs and makes accounting simpler.

Fixes: https://tracker.ceph.com/issues/43947
Signed-off-by: Josh Durgin <jdurgin@redhat.com>
qa/workunits/mon/pg_autoscaler.sh
src/pybind/mgr/pg_autoscaler/module.py