mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andi Kleen <ak@suse.de>
To: Craig Soules <soules@happyplace.pdl.cmu.edu>
Cc: Andi Kleen <ak@suse.de>, Chris Wedgwood <cw@f00f.org>,
	linux-kernel@vger.kernel.org
Subject: Re: NFS Client patch
Date: Tue, 10 Jul 2001 19:06:02 +0200	[thread overview]
Message-ID: <20010710190602.A8997@gruyere.muc.suse.de> (raw)
In-Reply-To: <20010710154135.A4603@gruyere.muc.suse.de> <Pine.LNX.3.96L.1010710124338.16113W-100000@happyplace.pdl.cmu.edu>
In-Reply-To: <Pine.LNX.3.96L.1010710124338.16113W-100000@happyplace.pdl.cmu.edu>; from soules@happyplace.pdl.cmu.edu on Tue, Jul 10, 2001 at 12:48:20PM -0400

On Tue, Jul 10, 2001 at 12:48:20PM -0400, Craig Soules wrote:
> On Tue, 10 Jul 2001, Andi Kleen wrote:
> > Because to get that new cookie you would need another cookie; otherwise
> > you could violate the readdir guarantee that it'll never return files
> > twice.
> 
> I cannot locate any such guarantee in the NFS spec... are you refering to
> another spec which applies?

It's the unix semantics of readdir(); e.g. specified in Single Unix:

``   The type DIR, which is defined in the header <dirent.h>, represents
     a directory stream, which is an ordered sequence of all the
     directory entries in a particular directory. Directory entries
     represent files; files may be removed from a directory or added to
     a directory asynchronously to the operation of readdir(). ''

An ordered sequence does not include cycles.


> 
> > BTW; the cookie issue is not an NFS only problem. It occurs on local
> > IO as well. Just consider rm -rf - reading directories and in parallel
> > deleting them (the original poster's file system would have surely
> > gotten that wrong). Another tricky case is telldir().  
> 
> I don't believe that the behavior in this case is deterministic.  If you
> have multiple people accessing a single file, reading and writing to it,
> there is no guarantee as to what the behavior is.  The client should be
> able to handle any errors it creates for itself while doing this kind of
> parallel operation.

What happens with new entries added is unspecified; but old entries removed
in parallel should never cause a violation of the rule above.

A simple index into a rebalancing btree unfortunately doesn't fulfil this;
but there are ways to add additional layers to fix it.

The easiest test for it is rm -rf. 


-Andi

  reply	other threads:[~2001-07-10 17:06 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <Pine.LNX.3.96L.1010709131315.16113O-200000@happyplace.pdl.cmu.edu.suse.lists.linux.kernel>
2001-07-09 18:33 ` Andi Kleen
2001-07-10 13:33   ` Chris Wedgwood
2001-07-10 13:41     ` Andi Kleen
2001-07-10 16:48       ` Craig Soules
2001-07-10 17:06         ` Andi Kleen [this message]
2001-07-10 18:04           ` Chris Wedgwood
2001-07-12 20:57             ` Alan Cox
2001-07-13 11:26               ` Chris Wedgwood
2001-07-17 22:02   ` Hans Reiser
2001-07-17 22:14     ` Craig Soules
2001-07-17 22:21       ` Hans Reiser
2001-07-18 13:30         ` Daniel Phillips
2001-07-18 14:46           ` Hans Reiser
2001-07-18 14:00         ` Jan Harkes
2001-07-18 14:46           ` Hans Reiser
2001-07-19 18:24             ` Pavel Machek
2001-07-22 15:15               ` Rob Landley
2001-07-23  2:02                 ` Horst von Brand
2001-07-23  9:57                   ` Rob Landley
2001-07-18 13:57     ` Chris Mason
2001-07-19 11:35       ` Trond Myklebust
2001-07-19 18:02         ` Hans Reiser
2001-07-20  8:50         ` Trond Myklebust
2001-07-20 11:30           ` Hans Reiser
2001-07-20 14:07           ` Chris Mason
2001-07-09 17:28 Craig Soules
2001-07-09 18:59 ` Trond Myklebust
2001-07-09 19:45   ` Craig Soules
2001-07-09 19:53     ` Charles Cazabon
2001-07-09 21:46     ` J. Richard Sladkey
2001-07-10 15:06       ` Craig Soules
2001-07-09 20:05   ` Trond Myklebust
2001-07-09 22:09     ` Craig Soules
2001-07-10  8:22     ` Trond Myklebust
2001-07-10 13:38       ` Chris Wedgwood
2001-07-11  8:14       ` 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=20010710190602.A8997@gruyere.muc.suse.de \
    --to=ak@suse.de \
    --cc=cw@f00f.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=soules@happyplace.pdl.cmu.edu \
    /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

all inboxes | Powered by JetHome®