Linux NFS development
 help / color / mirror / Atom feed
From: "J. Bruce Fields" <bfields@fieldses.org>
To: Trond Myklebust <trond.myklebust@primarydata.com>
Cc: Chuck Lever <chuck.lever@oracle.com>,
	Linux NFS Mailing List <linux-nfs@vger.kernel.org>
Subject: Re: [PATCH] nfs(5): Update close-to-open discussion in DATA AND METADATA COHERENCY
Date: Thu, 5 Mar 2015 15:33:50 -0500	[thread overview]
Message-ID: <20150305203350.GA17297@fieldses.org> (raw)
In-Reply-To: <CAHQdGtSrJS6XEegy7COxBijMKg5UTMa8nCopfFnWGrF2FaxXPA@mail.gmail.com>

On Thu, Mar 05, 2015 at 03:18:00PM -0500, Trond Myklebust wrote:
> On Thu, Mar 5, 2015 at 1:42 PM, J. Bruce Fields <bfields@fieldses.org> wrote:
> > On Thu, Mar 05, 2015 at 11:06:37AM -0500, Chuck Lever wrote:
> >> The discussion of close-to-open describes the GETATTR and data flush
> >> behavior implemented on the Linux client, but does not describe what
> >> happens between open() and close(). The lack of strict cache
> >> coherency surprises users who expect single-system behavior
> >> similar to local file systems.
> >>
> >> An explicit description of this behavior is inserted.  Additional
> >> clarifications are made of the surrounding text.
> >>
> >> Text contributed by Trond, Bruce, Chuck, and Chris Perl.
> >>
> >> Link: http://marc.info/?l=linux-nfs&m=142472673425307&w=2
> >> Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
> >> ---
> >> Hi-
> >>
> >> TBH I'm more concerned about nfs(5) than I am about the antique NFS
> >> FAQ. Besides, my sf.net login expired long ago, after I retired from
> >> FAQ maintenance.
> >
> > If someone wanted to just copy the whole thing over to the linux-nfs.org
> > wiki, I'd support that.
> >
> >> Thus I'm proposing this change to nfs(5). Then I'd like to suggest
> >> eventually replacing the bulk of FAQ A8 with a pointer to the DATA
> >> AND METADATA COHERENCE section of nfs(5).
> >
> > Moving it to the man pages sounds fine to me too, though.
> >
> >> Comments?
> >
> > We're leading with the mechanism (flushing and attribute checking),
> > which I think encourages people to reason starting from the
> > implementation.  We know that's difficult.
> >
> > I'd rather lead with a conservative black-box explanation of what
> > applications can and cannot depend on.
> >
> 
> This should be the case here.  Exactly what are we saying that you
> believe goes beyond the close-to-open caching model?

Nothing.  I'm not claiming the text is incorrect.  I would just prefer
that we begin by describing the behavior from the point of view of a
user of the filesystem interface, rather than from the point of view of
the implementation.

Statements like

	When an application opens a file stored on an NFS version 3
	server, the NFS client checks that the file exists on the server
	and is permitted to the opener by sending a GETATTR or ACCESS
	request.  The NFS client sends these requests regardless of the
	freshness of the file's cached attributes.

describe the implementation.

A block-box explanation of what applications can and cannot depend on
might consist of statements of the form:

	Access from multiple processes on the same client provides the
	same guarantees as on local filesystems.

	Access from multiple clients will provide the same guarantees as
	long as no client's open for write overlaps any other open from
	another client.

	If a client does open a file for read while another holds it
	open for write, results of that client's reads are undefined.

Etc.

--b.

      reply	other threads:[~2015-03-05 20:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-05 16:06 [PATCH] nfs(5): Update close-to-open discussion in DATA AND METADATA COHERENCY Chuck Lever
2015-03-05 18:42 ` J. Bruce Fields
2015-03-05 20:01   ` Chuck Lever
2015-03-05 20:18   ` Trond Myklebust
2015-03-05 20:33     ` J. Bruce Fields [this message]

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=20150305203350.GA17297@fieldses.org \
    --to=bfields@fieldses.org \
    --cc=chuck.lever@oracle.com \
    --cc=linux-nfs@vger.kernel.org \
    --cc=trond.myklebust@primarydata.com \
    /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