Re: [PATCH v3] blk-throtl: Introduce sync and async queues for blk-throtl

From: Tejun Heo
Date: Thu Jan 05 2023 - 12:36:27 EST


Hello,

On Thu, Jan 05, 2023 at 05:18:54PM +0100, Michal Koutný wrote:
> I guess similar problem would arise for devices that are "naturally"
> slow.
> Then:
> a) it must have been solved elsewhere in the block layer (but it's
> broken),
> b) it should be solved generically in the block layer (thus this is only
> a partial solution).

Hard limits tend to make this sort of problems a lot more pronounced because
the existing mechanisms tend to break down for the users which are severely
throttled down even while the device as a whole is fairly idle. cpu.max
often triggers severe priority inversions too, so it isn't too surprising
that people hit severe priority inversion issues w/ io.max.

Another problem with blk-throttle is that it doesn't prioritize shared IOs
identified by bio_issue_as_root_blkg() like iolatency and iocost do, so
there can be very severe priority inversions when e.g. journal commit gets
trapped in a low priority cgroup further exacerbating issues like this.

Thanks.

--
tejun