public inbox for linux-block@vger.kernel.org
 help / color / mirror / Atom feed
From: Ming Lei <ming.lei@redhat.com>
To: Yu Kuai <yukuai1@huaweicloud.com>
Cc: Shin'ichiro Kawasaki <shinichiro.kawasaki@wdc.com>,
	linux-block@vger.kernel.org, "yukuai (C)" <yukuai3@huawei.com>
Subject: Re: [PATCH] tests/throtl: add a new test 006
Date: Tue, 4 Mar 2025 18:02:03 +0800	[thread overview]
Message-ID: <Z8bPm44sMy88l0yL@fedora> (raw)
In-Reply-To: <7ff7166f-3069-59ae-6820-98e8b76057d6@huaweicloud.com>

On Tue, Mar 04, 2025 at 10:46:40AM +0800, Yu Kuai wrote:
> Hi,
> 
> 在 2025/02/25 10:07, Yu Kuai 写道:
> > Hi,
> > 
> > 在 2025/02/24 21:54, Ming Lei 写道:
> > > > Do you run this test without the kernel patch? If I remembered
> > > > correctly, ext4 issue the meta IO from jbd2 by default, which is from
> > > > root cgroup, and root cgroup can only throttled from cgroup v1.
> > > It passes on v6.14-rc1, does META/SWAP IO only route from cgroup v1?
> > 
> > Of course not, it's just ext4 will issue such IO from root cgroup, and
> > there is no IO can be throttled here.
> > 
> > You might want to bind jbd2 to the test cgroup as well.

But the issue still can't be reproduced by adding the following delta
change, meantime revert 29390bb5661d ("blk-throttle: support prioritized
processing of metadata") on kernel side.

diff --git a/tests/throtl/006 b/tests/throtl/006
index 4baadaf..bb09eb2 100755
--- a/tests/throtl/006
+++ b/tests/throtl/006
@@ -43,7 +43,11 @@ test() {

        _throtl_set_limits wbps=$((1024 * 1024))
        {
+               local jbd2_pid
+
+               jbd2_pid=$(ps -eo pid,comm |grep "jbd2/${THROTL_DEV}" |awk '{print $1}')
                echo "$BASHPID" > "$CGROUP2_DIR/$THROTL_DIR/cgroup.procs"
+               echo "$jbd2_pid" > "$CGROUP2_DIR/$THROTL_DIR/cgroup.procs"
                _throtl_issue_fs_io  "${TMPDIR}/mnt/test.img" write 64K 64 &
                sleep 2
                test_meta_io "${TMPDIR}/mnt"


Thanks,
Ming


  reply	other threads:[~2025-03-04 10:02 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-24  9:59 [PATCH] tests/throtl: add a new test 006 Ming Lei
2025-02-24 12:25 ` Yu Kuai
2025-02-24 13:54   ` Ming Lei
2025-02-25  2:07     ` Yu Kuai
2025-03-04  2:46       ` Yu Kuai
2025-03-04 10:02         ` Ming Lei [this message]
2025-03-04 13:08           ` Yu Kuai
2025-03-03 12:06 ` Shinichiro Kawasaki
2025-03-04  2:34   ` Ming Lei

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=Z8bPm44sMy88l0yL@fedora \
    --to=ming.lei@redhat.com \
    --cc=linux-block@vger.kernel.org \
    --cc=shinichiro.kawasaki@wdc.com \
    --cc=yukuai1@huaweicloud.com \
    --cc=yukuai3@huawei.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