Re: [PATCH 1/6] NFSD: add the ability to enable use of RWF_DONTCACHE for all IO

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 2025-06-11 at 06:44 -0400, Mike Snitzer wrote:
> On Tue, Jun 10, 2025 at 11:57:33PM -0700, Christoph Hellwig wrote:
> > On Tue, Jun 10, 2025 at 04:57:32PM -0400, Mike Snitzer wrote:
> > > Add 'enable-dontcache' to NFSD's debugfs interface so that: Any data
> > > read or written by NFSD will either not be cached (thanks to O_DIRECT)
> > > or will be removed from the page cache upon completion (DONTCACHE).
> > > 
> > > enable-dontcache is 0 by default.  It may be enabled with:
> > >   echo 1 > /sys/kernel/debug/nfsd/enable-dontcache
> > 
> > Having this as a global debug-only interface feels a bit odd.
> > 
> 
> I generally agree, I originally proposed nfsd.nfsd_dontcache=Y
> modparam:
> https://lore.kernel.org/linux-nfs/20250220171205.12092-1-snitzer@xxxxxxxxxx/
> 
> (and even implemented formal NFSD per-export "dontcache" control,
> which Trond and I both think is probably needed).
> 
> But (ab)using debugfs is the approach Chuck and Jeff would like to
> take for experimental NFSD changes so that we can kick the tires
> without having to support an interface until the end of time. See
> commit 9fe5ea760e64 ("NFSD: Add /sys/kernel/debug/nfsd") for more on
> the general thinking.  First consumer was commit c9dcd1de7977 ("NFSD:
> Add experimental setting to disable the use of splice read").
> 
> I'm fine with using debugfs, means to an end with no strings attached.
> 
> Once we have confidence in what is needed we can pivot back to
> a modparam or per-export controls or whatever.
> 

Yeah. I think this will probably end up being a per-export setting.
We're just hesitant to commit to an interface until we have a bit more
experience with this.
-- 
Jeff Layton <jlayton@xxxxxxxxxx>





[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux