]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mon/OSDMonitor: Make the pg_num check more accurate 39062/head
authorjerryluo <luojierui@chinatelecom.cn>
Mon, 25 Jan 2021 16:10:57 +0000 (00:10 +0800)
committerKefu Chai <tchaikov@gmail.com>
Mon, 27 Sep 2021 13:55:00 +0000 (21:55 +0800)
commitc726ce9e5088b30d29e0db5c0ecc8c03fe41da1d
treee94aa75eedbbe027d30daaf201d77b0b16c6186e
parent99f1f0f4c0c8adeda362d188d72b244064a2c024
mon/OSDMonitor: Make the pg_num check more accurate

In check_pg_num function, finding the corresponding osd according to the
current pool's crush rule, and calculating whether the average value of
pg_num on these osd will exceed the value of 'mon_max_pg_per_osd'. Make
the pg_num check more accurate by counting all the pgs on the osd used
by the new pool.

Fixes: https://tracker.ceph.com/issues/47062
Signed-off-by: Jerry Luo <luojierui@chinatelecom.cn>
src/mon/OSDMonitor.cc
src/mon/OSDMonitor.h
src/osd/OSDMapMapping.h