From: "Michal Koutný" <mkoutny@suse.com>
To: Jinke Han <hanjinke.666@bytedance.com>
Cc: tj@kernel.org, josef@toxicpanda.com, axboe@kernel.dk,
cgroups@vger.kernel.org, linux-block@vger.kernel.org,
linux-kernel@vger.kernel.org, yinxin.x@bytedance.com
Subject: Re: [PATCH v2] blk-throtl: Introduce sync and async queues for blk-throtl
Date: Thu, 22 Dec 2022 14:39:12 +0100 [thread overview]
Message-ID: <20221222133912.GA20830@blackbody.suse.cz> (raw)
In-Reply-To: <20221221104246.37714-1-hanjinke.666@bytedance.com>
[-- Attachment #1: Type: text/plain, Size: 1319 bytes --]
Hello Jinke.
On Wed, Dec 21, 2022 at 06:42:46PM +0800, Jinke Han <hanjinke.666@bytedance.com> wrote:
> In our test, fio writes a 100g file in sequential 4k blocksize in
> a container with low bps limit configured (wbps=10M). More than 1200
> ios were throttled in blk-throtl queue and the avarage throtle time
> of each io is 140s. At the same time, the operation of saving a small
> file by vim will be blocked amolst 140s. As a fsync will be send by vim,
> the sync ios of fsync will be blocked by a huge amount of buffer write
> ios ahead. This is also a priority inversion problem within one cgroup.
> In the database scene, things got really bad with blk-throtle enabled
> as fsync is called very often.
I'm trying to make sense of the numbers:
- at 10 MB/s, it's 0.4 ms per 4k block
- there are 1.2k throttled bios that gives waiting time of roughly 0.5s
~ 0.4ms * 1200
- you say that you observe 280 times longer throttling time,
- that'd mean there should be 340k queued bios
- or cummulative dispatch of ~1400 MB of data
So what are the queued quantities? Are there more than 1200 bios or are
they bigger than the 4k you mention?
Thanks for clarification.
(I acknowledge the possible problem with a large population of async
writes delaying scarce sync writes.)
Michal
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2022-12-22 13:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-18 11:13 [PATCH] blk-throtl: Introduce sync and async queues for blk-throtl Jinke Han
[not found] ` <20221218111314.55525-1-hanjinke.666-EC8Uxl6Npydl57MIdRCFDg@public.gmane.org>
2022-12-19 21:22 ` Tejun Heo
2022-12-20 2:38 ` [External] " hanjinke
2022-12-21 10:42 ` [PATCH v2] " Jinke Han
2022-12-22 13:39 ` Michal Koutný [this message]
[not found] ` <20221222133912.GA20830-9OudH3eul5jcvrawFnH+a6VXKuFTiq87@public.gmane.org>
2022-12-22 15:38 ` [External] " hanjinke
2022-12-23 9:52 ` hanjinke
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221222133912.GA20830@blackbody.suse.cz \
--to=mkoutny@suse.com \
--cc=axboe@kernel.dk \
--cc=cgroups@vger.kernel.org \
--cc=hanjinke.666@bytedance.com \
--cc=josef@toxicpanda.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tj@kernel.org \
--cc=yinxin.x@bytedance.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox