-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge "Lazy IO capacity replenishment" from Pavel E
" The rate-limiter-based IO scheduler uses two token-buckets to rate limit the requests rate. The tokens are put into the second bucket (from where they are then grabbed for dispatch) by the procedure called "replenisher" which is run by a steady timer. This timer generates several troubles: its rate is magically selected, it runs on a single shard, it generates a noticeable user time when the reactor is idling. To fix that the proposal is to make io-queue poller replenish the tokens from all shards when they need them. Before this change it's worth tuning the replenishment threshold to be not less than the minimal capacity that can be claimed from the group. Verified on i3en instance with the rl-iosched. tests: unit(dev), manual.rl-iosched(dev) This set places one more item into the TODO list. If the disk slows down for some reason the replenisher may start generating more tokens for the 2nd bucket than there appears on the 1st. When it happens the replenishment code drops some re-generated tokens until some future time, thus slowing down its rate. This behavior is deliberate and was aimed at making the token-buckets adopt to the real disk speed. However, this logic may lead to false drops. The tokens appear on the 1st bucket in batches, with the "trendline" being at the expected rate. However, the replenisher most likely runs between those batches thus constantly generating more tokens just because those batches are not "linear enough". This is what surfaced during verification -- when the replenisher was switched into on-demand manner it became more "aggressive" thus losing more tokens. This was partially addressed by the threshold increase, but some more care is still needed. " Fixes #996 * 'br-fair-group-replenish-relax' of https://github.com/xemul/seastar: fair_queue: Replenish tokens on grab, not by timer fair_queue, io_queue: Configure replenish threshold from minimal IO request fair_group: Generalize duration -> capacity conversion fair_queue: Tune-up clock_type fair_queue: Remove unused _base
- Loading branch information
Showing
5 changed files
with
48 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters