linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* Re: [RFC PATCH 1/2] NFSD: Add aggressive write throttling control
       [not found] ` <20251219141105.1247093-2-cel@kernel.org>
@ 2026-01-07  7:55   ` Christoph Hellwig
  2026-01-07 14:36     ` Chuck Lever
  0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2026-01-07  7:55 UTC (permalink / raw)
  To: Chuck Lever
  Cc: Christoph Hellwig, Mike Snitzer, linux-nfs, Chuck Lever,
	linux-mm, linux-fsdevel

On Fri, Dec 19, 2025 at 09:11:04AM -0500, Chuck Lever wrote:
> From: Chuck Lever <chuck.lever@oracle.com>
> 
> On NFS servers with fast network links but slow storage, clients can
> generate WRITE requests faster than the server can flush payloads to
> durable storage. This can push the server into memory exhaustion as
> dirty pages accumulate across hundreds of concurrent NFSD threads.
> 
> The existing dirty page throttling (balance_dirty_pages()) uses
> per-task accounting with default ratelimits that allow each thread
> to dirty ~32 pages before throttling occurs. With many NFSD threads,
> this allows significant dirty page accumulation before any
> throttling kicks in.

What makes NFSD so special here vs say a userspace process with a bunch
of threads?  Also what is the actual problem we're trying to solve?

I kinda hate having this stuff in NFSD when there's nothing specific
about nfs serving here.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC PATCH 1/2] NFSD: Add aggressive write throttling control
  2026-01-07  7:55   ` [RFC PATCH 1/2] NFSD: Add aggressive write throttling control Christoph Hellwig
@ 2026-01-07 14:36     ` Chuck Lever
  2026-01-07 14:42       ` Christoph Hellwig
  0 siblings, 1 reply; 4+ messages in thread
From: Chuck Lever @ 2026-01-07 14:36 UTC (permalink / raw)
  To: Christoph Hellwig
  Cc: Mike Snitzer, linux-nfs, Chuck Lever, linux-mm, linux-fsdevel

On 1/7/26 2:55 AM, Christoph Hellwig wrote:
> On Fri, Dec 19, 2025 at 09:11:04AM -0500, Chuck Lever wrote:
>> From: Chuck Lever <chuck.lever@oracle.com>
>>
>> On NFS servers with fast network links but slow storage, clients can
>> generate WRITE requests faster than the server can flush payloads to
>> durable storage. This can push the server into memory exhaustion as
>> dirty pages accumulate across hundreds of concurrent NFSD threads.
>>
>> The existing dirty page throttling (balance_dirty_pages()) uses
>> per-task accounting with default ratelimits that allow each thread
>> to dirty ~32 pages before throttling occurs. With many NFSD threads,
>> this allows significant dirty page accumulation before any
>> throttling kicks in.
> 
> What makes NFSD so special here vs say a userspace process with a bunch
> of threads?  Also what is the actual problem we're trying to solve?

The problem, as I see it, is that the system is not providing enough
backpressure to slow down noisy clients, allowing them to overwhelm
the server's memory with UNSTABLE WRITE traffic.

This is the same issue, IMO, that Mike's direct I/O is attempting to
address. Our implementation of UNSTABLE WRITE is a denial-of-service
vector.


> I kinda hate having this stuff in NFSD when there's nothing specific
> about nfs serving here.
Don't worry too much about that, these patches are obviously not in any
kind of merge-able shape yet. We do need to understand the metabolism of
UNSTABLE WRITEs, in particular, to get a clear picture of what needs to
be controlled to make the server autonomously stable.


-- 
Chuck Lever


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC PATCH 1/2] NFSD: Add aggressive write throttling control
  2026-01-07 14:36     ` Chuck Lever
@ 2026-01-07 14:42       ` Christoph Hellwig
  2026-01-07 14:49         ` Chuck Lever
  0 siblings, 1 reply; 4+ messages in thread
From: Christoph Hellwig @ 2026-01-07 14:42 UTC (permalink / raw)
  To: Chuck Lever
  Cc: Christoph Hellwig, Mike Snitzer, linux-nfs, Chuck Lever,
	linux-mm, linux-fsdevel

On Wed, Jan 07, 2026 at 09:36:39AM -0500, Chuck Lever wrote:
> > What makes NFSD so special here vs say a userspace process with a bunch
> > of threads?  Also what is the actual problem we're trying to solve?
> 
> The problem, as I see it, is that the system is not providing enough
> backpressure to slow down noisy clients, allowing them to overwhelm
> the server's memory with UNSTABLE WRITE traffic.
> 
> This is the same issue, IMO, that Mike's direct I/O is attempting to
> address. Our implementation of UNSTABLE WRITE is a denial-of-service
> vector.

But how is this different from Samba or a userspace NFS server?



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFC PATCH 1/2] NFSD: Add aggressive write throttling control
  2026-01-07 14:42       ` Christoph Hellwig
@ 2026-01-07 14:49         ` Chuck Lever
  0 siblings, 0 replies; 4+ messages in thread
From: Chuck Lever @ 2026-01-07 14:49 UTC (permalink / raw)
  To: Christoph Hellwig
  Cc: Mike Snitzer, linux-nfs, Chuck Lever, linux-mm, linux-fsdevel

On 1/7/26 9:42 AM, Christoph Hellwig wrote:
> On Wed, Jan 07, 2026 at 09:36:39AM -0500, Chuck Lever wrote:
>>> What makes NFSD so special here vs say a userspace process with a bunch
>>> of threads?  Also what is the actual problem we're trying to solve?
>>
>> The problem, as I see it, is that the system is not providing enough
>> backpressure to slow down noisy clients, allowing them to overwhelm
>> the server's memory with UNSTABLE WRITE traffic.
>>
>> This is the same issue, IMO, that Mike's direct I/O is attempting to
>> address. Our implementation of UNSTABLE WRITE is a denial-of-service
>> vector.
> 
> But how is this different from Samba or a userspace NFS server?
Well it might not be different. But at this point I don't think we know
enough about the problem to say one way or another. I'm just trying to
gather more experimental evidence about what is happening.


-- 
Chuck Lever


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-01-07 14:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20251219141105.1247093-1-cel@kernel.org>
     [not found] ` <20251219141105.1247093-2-cel@kernel.org>
2026-01-07  7:55   ` [RFC PATCH 1/2] NFSD: Add aggressive write throttling control Christoph Hellwig
2026-01-07 14:36     ` Chuck Lever
2026-01-07 14:42       ` Christoph Hellwig
2026-01-07 14:49         ` Chuck Lever

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox