Make NFS-Client readahead tunable
Subsystems (2)
----- Original Message ----
Quoted 40 lines
From: Chuck Lever <[email protected]>
To: Martin Knoblauch <[email protected]>
Cc: Andrew Morton <[email protected]>; Greg Banks <gnb-cP1dWloDopni96+mSzHFpQC/[email protected]>; linux-nfs list <[email protected]>; [email protected]; Peter zijlstra <[email protected]>
Sent: Thursday, September 18, 2008 8:24:42 PM
Subject: Re: [RFC][Resend] Make NFS-Client readahead tunableQuoted 5 lines · Martin Knoblauch
----- Original Message ----
Quoted 3 lines
From: Andrew Morton
To: Martin Knoblauch
Cc: Greg Banks ; linux-nfs list; [email protected]; Peter zijlstra
Quoted 13 lines
Quoted 13 lines
Sent: Thursday, September 18, 2008 10:47:33 AM
Subject: Re: [RFC][Resend] Make NFS-Client readahead tunableQuoted 5 lines · On Thu, 18 Sep 2008 01:38:57 -0700 (PDT) Martin Knoblauch wrote:
Quoted 3 lines
No. mount(8) will pass unrecognised options straight down into the filesystem driver.
Has that always been the case, or is it a recent change? I have to support
RHEL4 userland, which is not really new.
Quoted 8 lines
Quoted 6 lines
It's been that way for ever and ever. It's how all these guys:
y:/usr/src/25> grep
Opt_fs/*/super.c|wc781 2626 33703get handled.
while that seems to be not to complicated, I seem to have a problem passing
the mount options to the kernel. They come down as mount data version "6". Apparently mount(8) or
mount.nfs(8)are doing the parsing and send down the legacy data block. So, what is the minimum version of mount or mount.nfs that pass the options down unaltered?
Quoted 6 lines
The mount command has passed a string of options to the kernel for particular file systems for a while, but the facility for the NFS client to parse a string of mount options in the kernel was added only recently -- at least 2.6.23 or 2.6.24 is required to support this. Before this, the mount command parsed these options.
I understand that. Question remains, which version of the mount(8) or nfs.mount(8) command do I need to pass the options to the kernel.
Quoted 7 lines
For RHEL 4, based on 2.6.9, you are stuck. It uses a binary structure whose fields must match between the kernel and user space. For RH enterprise kernels, the ABI cannot change in a given release, so RH wouldn't take a patch to change the data structure that mount uses. You would have to maintain such a change yourself, and build your own kernels and mount command after each RHEL 4 update is released.
For implementation/testing purposes I have some freedom in what userland I run. My systems are mainly RHEL4, but I have long junked the 2.6.9 based kernels.
Quoted 6 lines
I agree that a mount option would allow more fine-grained control over readahead. A system wide parameter controlling readahead has always been a weakness. Readahead, as implemented in the VFS, has a *per-file descriptor* context, however, which operates automatically (and can be tuned at run-time by an application with [mf]advise(2).
The per-file descriptor stuff is not applicable in my case, as I do not have controll over programms acessing the files.
Quoted 5 lines
As a future feature, this might work in better combination with the per-mount bdi changes proposed by Peter to provide maximal flexibility without exposing yet another confusing knob that could help some workloads but hurt others.
Thats why I am open to experiment, but need to know which userland tools support the direct passing of mount options to the NFS client.
Cheers
Martin
Quoted 42 lines · Martin Knoblauch
----- Original Message ----
Quoted 40 lines
From: Chuck Lever <[email protected]>
To: Martin Knoblauch <[email protected]>
Cc: Andrew Morton <[email protected]>; Greg Banks <gnb-cP1dWloDopni96+mSzHFpQC/[email protected]>; linux-nfs list <[email protected]>; [email protected]; Peter zijlstra <[email protected]>
Sent: Thursday, September 18, 2008 8:24:42 PM
Subject: Re: [RFC][Resend] Make NFS-Client readahead tunableQuoted 5 lines · Martin Knoblauch
----- Original Message ----
Quoted 3 lines
From: Andrew Morton
To: Martin Knoblauch
Cc: Greg Banks ; linux-nfs list; [email protected]; Peter zijlstra
Quoted 13 lines
Quoted 13 lines
Sent: Thursday, September 18, 2008 10:47:33 AM
Subject: Re: [RFC][Resend] Make NFS-Client readahead tunableQuoted 5 lines · On Thu, 18 Sep 2008 01:38:57 -0700 (PDT) Martin Knoblauch wrote:
Quoted 3 lines
No. mount(8) will pass unrecognised options straight down into the filesystem driver.
Has that always been the case, or is it a recent change? I have to support
RHEL4 userland, which is not really new.
Quoted 8 lines
Quoted 6 lines
It's been that way for ever and ever. It's how all these guys:
y:/usr/src/25> grep
Opt_fs/*/super.c|wc781 2626 33703get handled.
while that seems to be not to complicated, I seem to have a problem passing
the mount options to the kernel. They come down as mount data version "6". Apparently mount(8) or
mount.nfs(8)are doing the parsing and send down the legacy data block. So, what is the minimum version of mount or mount.nfs that pass the options down unaltered?
Quoted 8 lines
Quoted 6 lines
The mount command has passed a string of options to the kernel for particular file systems for a while, but the facility for the NFS client to parse a string of mount options in the kernel was added only recently -- at least 2.6.23 or 2.6.24 is required to support this. Before this, the mount command parsed these options.
I understand that. Question remains, which version of the mount(8) or
nfs.mount(8)command do I need to pass the options to the kernel.
You can use the latest version of nfs-utils, which is 1.1.3 to get a version of mount.nfs that passes a string of mount options.
You should probably also replace the mount command with the latest version from the util-linux package to get a version that starts the mount.nfs subcommand instead of trying to do an NFS mount itself.
This is not needed for experimentation, though. You can issue mount.nfs directly.
--
Chuck Lever