From: "Stephen C. Tweedie" <sct@redhat.com>
To: Trond Myklebust <trond.myklebust@fys.uio.no>
Cc: "Stephen C. Tweedie" <sct@redhat.com>,
Jeremy Fitzhardinge <jeremy@goop.org>,
Ext2 devel <ext2-devel@lists.sourceforge.net>,
NFS maillist <nfs@lists.sourceforge.net>,
Linux Kernel List <linux-kernel@vger.kernel.org>
Subject: Re: Re: [NFS] htree+NFS (NFS client bug?)
Date: Thu, 28 Nov 2002 17:09:24 +0000 [thread overview]
Message-ID: <20021128170924.F2362@redhat.com> (raw)
In-Reply-To: <15846.19228.868861.629722@charged.uio.no>; from trond.myklebust@fys.uio.no on Thu, Nov 28, 2002 at 05:58:04PM +0100
Hi,
On Thu, Nov 28, 2002 at 05:58:04PM +0100, Trond Myklebust wrote:
> >>>>> " " == Stephen C Tweedie <sct@redhat.com> writes:
> > If you want it to be preserved in cache, it needs to be in the
> > inode, not in the file.
>
> You misunderstand the problem. It isn't that the page cache has an
> incorrect representation of the stream: the page cache is indeed
> stopping filling as soon as it hits the EOF marker.
I know that.
> The problem is that we are stuffing the server-supplied cookies into
> file->f_pos and using them to reconstruct where we are in the readdir
> stream.
> As there is no reserved 'EOF cookie' defined by the protocol that we
> might use, we must either rely on the server giving us a unique cookie
> also for the EOF case, or else mark the fact that filp->f_pos points
> to EOF in some other way.
Right. But marking the fact can be done in the inode. We do that for
regular files, after all --- we have an i_size field which marks the
value of f_pos which represents EOF. And _that_ is what I'm
suggesting for the NFS case --- record in the inode the cookie which
represents EOF, so that in future reads from cache, we still know when
we've got to the end of the stream.
This gets complicated by the possible presence of hash collisions,
though.
Ted, I think there's a problem with the logic for that case. We can
really only deal sensibly with hash collisions if we do everything in
our power to prevent returning f_pos back to the user in the middle of
a collision, but there's nothing in the ext3 code to do that right now
afaict. (And even if there were, NFS would just keep calling us to
get more dirents, so fixing it just in ext3 doesn't stop a hash
collision from spanning an NFS reply.)
--Stephen
-------------------------------------------------------
This SF.net email is sponsored by: Get the new Palm Tungsten T
handheld. Power & Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
next prev parent reply other threads:[~2002-11-28 17:09 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-26 23:44 htree+NFS (NFS client bug?) Jeremy Fitzhardinge
2002-11-27 3:26 ` [NFS] " Trond Myklebust
2002-11-27 2:59 ` [Ext2-devel] " chrisl
2002-11-27 8:58 ` Jeremy Fitzhardinge
2002-11-27 15:00 ` Stephen C. Tweedie
2002-11-27 20:25 ` [Ext2-devel] " Trond Myklebust
2002-11-27 20:55 ` Stephen C. Tweedie
2002-11-27 22:44 ` [Ext2-devel] " Trond Myklebust
2002-11-28 16:41 ` Stephen C. Tweedie
2002-11-28 16:58 ` Trond Myklebust
2002-11-28 17:09 ` Stephen C. Tweedie [this message]
2002-11-28 17:57 ` Trond Myklebust
2002-11-28 16:44 ` Stephen C. Tweedie
2002-11-28 17:13 ` Stephen C. Tweedie
2002-11-28 17:44 ` Trond Myklebust
2002-11-28 20:00 ` [Ext2-devel] " Jeremy Fitzhardinge
2002-11-28 2:07 ` Jeremy Fitzhardinge
2002-11-28 2:46 ` Trond Myklebust
2002-11-27 13:33 ` Theodore Ts'o
2002-11-27 20:42 ` Trond Myklebust
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20021128170924.F2362@redhat.com \
--to=sct@redhat.com \
--cc=ext2-devel@lists.sourceforge.net \
--cc=jeremy@goop.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nfs@lists.sourceforge.net \
--cc=trond.myklebust@fys.uio.no \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox