Subject: Re: Raising NFS parameters for higher bandwith or "long fat pipe"
To: YAMAMOTO Takashi <>
From: Thor Lancelot Simon <>
List: tech-kern
Date: 12/13/2003 21:22:18
On Sun, Dec 14, 2003 at 11:00:58AM +0900, YAMAMOTO Takashi wrote:
> > >> Below is an untested, almost certinaly broken, patch showing how
> > >> FreeBSD 4.x does NFS readahead. It' basically two chunks:
> > >
> > >yes, i agree it's broken. :-)
> > >we're not using traditional buffer cache interfaces for VREG's pages.
> > 
> > So how can we make it non-broken?
> do readahead at upper layer (as we're doing now, or even more upper layer.)

The thing is, by the time the request hits genfs_getpages, the actual
size passed to the read() call has been discarded -- genfs_getpages()
never gets a chance to find out even if the application wanted, say,
1MB worth of pages and we knew this because it told us so with read()

I don't really see any reason why that should be so, but at least
last time I looked, it was.  It would probably not be too hard to

I _think_ we could whack things so read() caused the whole range to
get willneed'ed.  Eric was doing something with this, maybe he
remembers more.