[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20241121102047.610700-1-jimzhao.ai@gmail.com>
Date: Thu, 21 Nov 2024 18:20:47 +0800
From: Jim Zhao <jimzhao.ai@...il.com>
To: jack@...e.cz,
akpm@...ux-foundation.org
Cc: jimzhao.ai@...il.com,
linux-fsdevel@...r.kernel.org,
linux-kernel@...r.kernel.org,
linux-mm@...ck.org,
shikemeng@...weicloud.com,
willy@...radead.org
Subject: Re: [PATCH v2] mm/page-writeback: Raise wb_thresh to prevent write blocking with strictlimit
> On Tue 19-11-24 20:29:22, Jim Zhao wrote:
> > Thanks, Jan, I just sent patch v2, could you please review it ?
>
> Yes, the patch looks good to me.
>
> >
> > And I found the debug info in the bdi stats.
> > The BdiDirtyThresh value may be greater than DirtyThresh, and after
> > applying this patch, the value of BdiDirtyThresh could become even
> > larger.
> >
> > without patch:
> > ---
> > root@...ntu:/sys/kernel/debug/bdi/8:0# cat stats
> > BdiWriteback: 0 kB
> > BdiReclaimable: 96 kB
> > BdiDirtyThresh: 1346824 kB
>
> But this is odd. The machine appears to have around 3GB of memory, doesn't
> it? I suspect this is caused by multiple cgroup-writeback contexts
> contributing to BdiDirtyThresh - in fact I think the math in
> bdi_collect_stats() is wrong as it is adding wb_thresh() calculated based
> on global dirty_thresh for each cgwb whereas it should be adding
> wb_thresh() calculated based on per-memcg dirty_thresh... You can have a
> look at /sys/kernel/debug/bdi/8:0/wb_stats file which should have correct
> limits as far as I'm reading the code.
Thanks for review!
Yes, It should be caused by multiple cgroup-writeback with bdi_collect_stats issue.
@Andrew,
I sent patch v2 according Jan's suggestion.
Since patch v1 already in tree. So I sent out the diff of v1 -> v2:
https://lore.kernel.org/all/20241121100539.605818-1-jimzhao.ai@gmail.com/
Could you please review it, thanks!
Jim Zhao
Powered by blists - more mailing lists