From nfs4-wg-request@sunroof.eng.sun.com  Sun Mar  5 01:14:52 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id BAA14173
	for <nfsv4-archive@odin.ietf.org>; Sun, 5 Mar 2000 01:14:51 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id WAA26496;
	Sat, 4 Mar 2000 22:14:23 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id WAA23518;
	Sat, 4 Mar 2000 22:14:10 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e256Dv902562;
	Sat, 4 Mar 2000 22:13:57 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id WAA18554;
	Sat, 4 Mar 2000 22:13:56 -0800 (PST)
Received: from isgood.centertel.pl (isgood.centertel.pl [194.9.223.77])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id XAA07360;
	Sat, 4 Mar 2000 23:13:54 -0700 (MST)
Received: from kllklk (ip22.providence11.ri.pub-ip.psi.net [38.26.242.22])
	by isgood.centertel.pl (8.9.2/8.9.2) with ESMTP id HAA01030;
	Sun, 5 Mar 2000 07:12:46 +0100 (MET)
Message-Id: <200003050612.HAA01030@isgood.centertel.pl>
From: "Frank" <petr82@bettergolf.net>
Subject: For Today...
To: first88u@isgood.centertel.pl
X-Mailer: Microsoft Outlook Express 4..72.1712.3
X-MimeOLE: Produced By Microsoft MimeOLE V(null).1712.3
Mime-Version: 1.0
Date: Sat, 04 Mar 2000 23:14:32 -0500
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by ietf.org id BAA14173

*Earn $2000 - $5000 weekly-starting within 1-4 weeks
*78% Profit Paid Daily
*No Selling
*No Risk Guarantee
*Work from home, No overhead, or employees.
*High Tech Training & Support
*Not MLM, 100x more profitable
*Multibillion Dollar Travel Industry
 
The most incredible part of our business
is that ALL MY CLIENTS CALL ME!
 
DO YOU QUALIFY FOR OUR MENTOR PROGRAM?
ACCEPTING ONLY 12 NEW ASSOCIATES
 
This is not a hobby!  Serious Inquires Only!!

Please reply with the following information 
NAME:
EMAIL ADDRESS:
PHONE:             (Required)
BEST TIME TO CALL:

TO:

mailto:per9@pplmail.com?subject=more_info


FOR MORE INFORMATION

If you are an entrepreneur or have always wanted to be your own BOSS,
read on.  We supply state-of-the-art training and a support system
that allows you to work your business from your home with just a
phone-without cold calling.  DO NOT REPLY IF YOU ARE LOOKING FOR A 
"GET RICH QUICK" SCHEME or some extra cash or if you're lazy.  We are
only looking for  FOCUSED serious entrepreneurs. (Pt/FT) with the
DESIRE to  improve their lifestyle immediately. 

///////////////////////////////////////////////////////////
Please remove at mailto:frank4545@yahoo.com?subject=remove
///////////////////////////////////////////////////////////





From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 11:13:48 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id LAA12615
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 11:13:45 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id JAA05930;
	Mon, 6 Mar 2000 09:11:29 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA09240;
	Mon, 6 Mar 2000 08:11:12 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26GAx903799
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 08:10:59 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA09193
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 08:10:59 -0800 (PST)
Received: from daffy.ee.lbl.gov (daffy.ee.lbl.gov [131.243.1.31])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id JAA05640
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 09:10:58 -0700 (MST)
Received: (from vern@localhost)
	by daffy.ee.lbl.gov (8.9.2/8.9.2) id IAA02787;
	Mon, 6 Mar 2000 08:10:57 -0800 (PST)
Message-Id: <200003061610.IAA02787@daffy.ee.lbl.gov>
To: "nfsv4-wg@sunroof.eng.sun.com" <nfsv4-wg@sunroof.eng.sun.com>
Subject: NFSv4 last call comments pending
Cc: dm@reeducation-labor.lcs.mit.edu
Date: Mon, 06 Mar 2000 08:10:57 PST
From: Vern Paxson <vern@ee.lbl.gov>

Given that the last call ends today, I wanted to alert the WG that David
Mazieres has been reviewing the v4 spec and has a number of comments he'll
be sending along late tonight.  He's been on the job interview circuit
these past couple of weeks, hence the delay in sending these out.

		Vern


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 13:29:13 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id NAA18403
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 13:29:12 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA03438;
	Mon, 6 Mar 2000 10:28:34 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id KAA07983;
	Mon, 6 Mar 2000 10:28:12 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26IRw903871
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 10:27:58 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id KAA19626
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 10:27:57 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id LAA16038
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 11:27:56 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id NAA17716
	for nfsv4-wg@sunroof.eng.sun.com; Mon, 6 Mar 2000 13:27:55 -0500 (EST)
Date: Mon, 6 Mar 2000 13:27:55 -0500 (EST)
Message-Id: <200003061827.NAA17716@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: Definition of utf8string

The draft NFS spec defines a utf8string as:

   utf8string    typedef opaque          utf8string<>;

There is an implicit requirement here that file names be able to
contain embedded 0 bytes, which would lead to undesirable behavior
when implementing an NFS4 server for a Unix file system (since most
Unix file system do not support embedded 0 bytes in file names).

One of the goals of UTF8 was to make UTF8 strings work well with the
standard C string functions.  Thus, all ASCII characters and the byte
0 are self-encoding and self-synchronizing.  In particular, the byte 0
does not appear in any runes other than 0.

Thus, I suggest that utf8strings actually be encoded as strings:

   utf8string    typedef string          utf8string<>;

The only difference between this and the proposed opaque is that now
strings cannot contain the byte 0.

I discussed this issue with one of the members of the Plan9 operating
system group at Bell Labs (the group from which UTF8 originated), and
he agreed that utf8string should be represented as a null-terminated
string, not as opaque data.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 13:46:47 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id NAA18887
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 13:46:46 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA13939;
	Mon, 6 Mar 2000 10:46:14 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id KAA24817;
	Mon, 6 Mar 2000 10:46:04 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.88.31])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26Ijo903880
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 10:45:50 -0800 (PST)
Received: from teal (awe8-102.Central.Sun.COM [129.147.8.102])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26IjmL28688;
	Mon, 6 Mar 2000 10:45:48 -0800 (PST)
Date: Mon, 6 Mar 2000 10:48:44 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: Definition of utf8string
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003061827.NAA17716@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952368524.11451.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> The draft NFS spec defines a utf8string as:
> 
>    utf8string    typedef opaque          utf8string<>;
> 
> There is an implicit requirement here that file names be able to
> contain embedded 0 bytes, which would lead to undesirable behavior
> when implementing an NFS4 server for a Unix file system (since most
> Unix file system do not support embedded 0 bytes in file names).
> 
> One of the goals of UTF8 was to make UTF8 strings work well with the
> standard C string functions.  Thus, all ASCII characters and the byte
> 0 are self-encoding and self-synchronizing.  In particular, the byte 0
> does not appear in any runes other than 0.
> 
> Thus, I suggest that utf8strings actually be encoded as strings:
> 
>    utf8string    typedef string          utf8string<>;
> 
> The only difference between this and the proposed opaque is that now
> strings cannot contain the byte 0.

I disagree on two counts.

First, nothing in RFC 1831 says that the string data type can't have a 0
(nul).  The issue of whether a utf8string incudes a nul is no much different
than the issue as to whether utf8string used for a file name component has an
embedded '/'. Some implementations will accept the nul, some (most) won't,
some will accept the '/', some won't. That most implementations of RFC 1831
are written in C and C uses nul terminated strings is a personal problem on
the part of those implementations. 

Second, the string data type defintion in RFC 1832 explicitly and unambiguously
states that it defines a "string of N ... ASCII bytes". Since we
want to include non-ascii bytes in the utf8string type, defining it
terms of "string" violates the definition of "string"; a correct
implementation of the string decoder would flag an error if it
encountered a non-ASCII octet.

> I discussed this issue with one of the members of the Plan9 operating
> system group at Bell Labs (the group from which UTF8 originated), and
> he agreed that utf8string should be represented as a null-terminated
> string, not as opaque data.

On the wire, both utf8string, and string look exactly the same. utf8string
is variable length data of octets, string are variable length data of ascii 
octets. Compare the diagrams of sections 3.10 and 3.11 of RFC 1832.

	-mre




From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 15:54:14 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id PAA29034
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 15:54:13 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id MAA24443;
	Mon, 6 Mar 2000 12:53:43 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA26679;
	Mon, 6 Mar 2000 12:53:21 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26Kr8904063
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 12:53:08 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA28403
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 12:53:06 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id MAA25915
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 12:53:04 -0800 (PST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id PAA18738
	for nfsv4-wg@sunroof.eng.sun.com; Mon, 6 Mar 2000 15:52:59 -0500 (EST)
Date: Mon, 6 Mar 2000 15:52:59 -0500 (EST)
Message-Id: <200003062052.PAA18738@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: Implementing POSIX stat(2), df(1) with NFSv4

From reading the NFS4 draft, it is not clear how exactly clients might
reasonably deal with the fsid attribute.  This is relevant when
implementing stat(2) and df(1) as required by POSIX.

The POSIX 1003.1 spec, in section 5.6.1, line 687, says "File serial
number and device ID taken together uniquely identify the file within
the system."  In other words, stat(2) must return a unique pair of
values (st_dev, st_ino) for each distinct file on the system.

Several UNIX utilities (e.g. pwd, cp) actually rely on the stat system
call returning aunique st_dev/st_ino pairs.  If there is a plan for
letting clients do this in NFS4, it might be worth describing as an
example in the RFC.

In previous versions of NFS, providing unique st_dev/st_ino pairs
wasn't a problem because clients mounted each file system on the
server separately.  Thus, NFS clients could ignore the fsid field of
the NFS fattr structure, assign a unique st_dev value to all files on
each NFS mount point, and use the NFS fileid value as the st_ino.

What I can't figure out from the draft spec is what reasonable mapping
one could use from NFS4 fileid/fsid attributes to st_dev/st_ino fields
in the stat structure.  Several obvious possibilities have problems:

 1. st_ino = fileid; st_dev = fsid;

    There are two problems here.  One is that fsid4 is huge--128 bits.
    In fact, a separate question might be why fsid4 needs to be larger
    than specdata4.  At any rate, you probably can't hope for more
    64-bits in a stat structure's st_dev field, so there is no way
    just to assign fsid to st_dev.

    Another problem is that there is no way to guarantee uniqueness
    across multiple servers (and file systems other than NFS).

 2. st_ino = fileid; st_dev = dynamic_map (server, fsid)

    Keep a dynamic mapping between server/fsid pairs and st_dev
    values.  Basically allocate a new st_dev value each time you run
    across a new fsid value on a given server.

    Here the problem is that the server could use a huge number of
    fsid values, particularly over time.  Is there anything in the
    spec preventing every single directory on a server from having a
    different fsid?  This could run the client out of space.

 3. st_dev = map (server); st_ino = hash (fileid, fsid)

    Map each server to a unique st_dev value (as was done with each
    mount point in NFS2-3).  Make st_ino a hash value of fileid and
    fsid.

    Here the problem is that you can hope for at most 64-bits of
    st_ino, which is too small to guarantee you will never have a
    collision.

If there is a better solution, I think it would make sense to put it
in the RFC as an example.

There is this somewhat cryptic statement in section 14.2.13:

  Unix clients that detect a mountpoint crossing will need to mount
  the server's filesystem.

This could conceivably be the same as option 2 above, but then how
does unmounting work?


A related question is how to implement the POSIX df(1) utility.  When
no arguments are specified, "information shall be written for all file
systems" (POSIX 1003.2, sec. 5.8.2, lines 814-815).  It's not clear
how even to determine "all file systems" on an NFS4 server.  Part of
the point of section 7.2 of the draft spec is that "There is a
drawback to [the old way of doing things]: it is static.  If the
server administrator adds a new export the client will be unaware of
it."  Is there some way to determine all file systems at any given
point?


The answers to both these questions may have to do with some sort of
plan for automounting built into NFS4.  I don't think it's clear what
to do without a more detailed suggestion in the document.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 16:16:16 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id QAA01911
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 16:16:16 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id NAA04769;
	Mon, 6 Mar 2000 13:15:42 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id NAA03039;
	Mon, 6 Mar 2000 13:15:24 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.88.31])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26LF2904084
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 13:15:02 -0800 (PST)
Received: from teal (awe8-102.Central.Sun.COM [129.147.8.102])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26LF0L24885;
	Mon, 6 Mar 2000 13:15:00 -0800 (PST)
Date: Mon, 6 Mar 2000 13:17:56 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: Implementing POSIX stat(2), df(1) with NFSv4
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003062052.PAA18738@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952377476.14297.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> >From reading the NFS4 draft, it is not clear how exactly clients might
> reasonably deal with the fsid attribute.  This is relevant when
> implementing stat(2) and df(1) as required by POSIX.
> 
> The POSIX 1003.1 spec, in section 5.6.1, line 687, says "File serial
> number and device ID taken together uniquely identify the file within
> the system."  In other words, stat(2) must return a unique pair of
> values (st_dev, st_ino) for each distinct file on the system.
> 
> Several UNIX utilities (e.g. pwd, cp) actually rely on the stat system
> call returning aunique st_dev/st_ino pairs.  If there is a plan for
> letting clients do this in NFS4, it might be worth describing as an
> example in the RFC.

Possibly, but it seems quite O/S specific to consider it. 

> What I can't figure out from the draft spec is what reasonable mapping
> one could use from NFS4 fileid/fsid attributes to st_dev/st_ino fields
> in the stat structure.  Several obvious possibilities have problems:

You can't directly map a server's fsid to an st_dev, unless st_dev is > 128
bits on your system. When the UNIX client crosses a server mount moint, the
new fsid tells it is has crossed mount points. UNIX clients in NFSv[23]
generate unqiue, if not random, values for for st_dev that have no correlation
with the contests of server's fsid's, and NFSv4 UNIX clients could do the same
thing.

> There is this somewhat cryptic statement in section 14.2.13:
> 
>   Unix clients that detect a mountpoint crossing will need to mount
>   the server's filesystem.
> 
> This could conceivably be the same as option 2 above, but then how

No it means the UNIX client creates a new NFS mounted file system.

> does unmounting work?

An implementation detail. For a system like Solaris 8, with in-kernel
mnttab, this is straightforward.

> A related question is how to implement the POSIX df(1) utility.  When
> no arguments are specified, "information shall be written for all file
> systems" (POSIX 1003.2, sec. 5.8.2, lines 814-815).  It's not clear

I hope it means all mounted file ssytems. With dynamic mounting and unmounting,
this is implementable in UNIX NFSv4 clients.

> how even to determine "all file systems" on an NFS4 server.  Part of
> the point of section 7.2 of the draft spec is that "There is a
> drawback to [the old way of doing things]: it is static.  If the
> server administrator adds a new export the client will be unaware of
> it."  Is there some way to determine all file systems at any given
> point?

Even NFSv[23] clients have this problem. You only see what's mounted.
If the client doesn't access the new export, it's not mounted.

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 17:09:40 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id RAA11304
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 17:09:39 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA18886;
	Mon, 6 Mar 2000 15:08:43 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA23228;
	Mon, 6 Mar 2000 14:08:31 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26M8J904131
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 14:08:19 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA28764
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 14:08:18 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA18561
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:08:12 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id RAA15324
	for nfsv4-wg@sunroof.eng.sun.com; Mon, 6 Mar 2000 17:08:08 -0500 (EST)
Date: Mon, 6 Mar 2000 17:08:08 -0500 (EST)
Message-Id: <200003062208.RAA15324@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: READDIR attributes ambiguity

The NFS4 draft spec does not make explicit which attributes READDIR
should return for a mount point.  For example, suppose a server with
two disks has the following directories:

  /      fsid=1, fileid=2
  /a     fsid=1, fileid=3
  /b     fsid=2, fileid=3   (mounted over /b fsid=1, flieid=4)

When requesting the fsid and fileid attributes from READDIR, Which
fsid/fileid pair should READDIR return for file name "b".

Implementers would probably prefer to return fsid=1, fileid=4, because
this is more efficient in many cases.

The spec would imply that the correct answer is fsid=2, flieid=3,
because technically that is correct, and it never says READDIR can
return anything else.

In fact, though, if you implement what I think the spec requires, it
becomes difficult to implement functions like the ANSI C getcwd()
efficiently.  Moreover, most implementations of getcwd (which are
optimized to take advantage getting the fileid from OS-specific
readdir extensions) will need to be changed before they work on NFS4.

In the example above, getcwd() might not work from within /a, because
the client OS can never see the hidden fileid 4 and therefor cannot
return a fileid unique to fsid=1 for the directory entry /b.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 17:38:33 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id RAA17413
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 17:38:32 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA02337;
	Mon, 6 Mar 2000 15:27:25 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA26754;
	Mon, 6 Mar 2000 14:27:10 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26MQu904139
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 14:26:57 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA18248
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 14:26:56 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA02002
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:26:51 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id RAA06175
	for nfsv4-wg@sunroof.eng.sun.com; Mon, 6 Mar 2000 17:26:46 -0500 (EST)
Date: Mon, 6 Mar 2000 17:26:46 -0500 (EST)
Message-Id: <200003062226.RAA06175@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: attributes of renamed file

It would be extremely useful if NFS4 servers could, after a RENAME
operation, atomically return the file handle and change_info4 of the
file actually being renamed.  In many implementations the server will
already have this information handy.  The client could use this
information to invalidate cached attributes without exposing itself to
a race condition as it must currently do.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:03:29 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA22543
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:03:28 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA22521;
	Mon, 6 Mar 2000 16:02:11 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA03926;
	Mon, 6 Mar 2000 15:02:02 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.82.166] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26N1m904181
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:01:48 -0800 (PST)
Received: from teal (awe171-58.AWE.Sun.COM [192.29.171.58])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26N1lL10482;
	Mon, 6 Mar 2000 15:01:47 -0800 (PST)
Date: Mon, 6 Mar 2000 15:04:43 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: attributes of renamed file
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003062226.RAA06175@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952383883.4026.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> It would be extremely useful if NFS4 servers could, after a RENAME
> operation, atomically return the file handle and change_info4 of the
> file actually being renamed.  In many implementations the server will
> already have this information handy.  The client could use this
> information to invalidate cached attributes without exposing itself to
> a race condition as it must currently do.

Could you describe the race condition? The NFSv3 RENAME procedure didn't
include the equivalent of change_info4 on the target file, just from source and target directories?

If the client has never cached any data on the file being renamed, why should
client and network be forced to bear the burden of extraneous information?

If the information is handy, COMPOUND can be used to get it.

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:07:11 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA23326
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:07:11 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA00058;
	Mon, 6 Mar 2000 15:06:31 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA11589;
	Mon, 6 Mar 2000 15:06:24 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.87.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26N62904185
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:06:03 -0800 (PST)
Received: from teal (awe171-58.AWE.Sun.COM [192.29.171.58])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26N62L11464;
	Mon, 6 Mar 2000 15:06:02 -0800 (PST)
Date: Mon, 6 Mar 2000 15:08:58 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: READDIR attributes ambiguity
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003062208.RAA15324@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952384138.21683.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> The NFS4 draft spec does not make explicit which attributes READDIR
> should return for a mount point.  For example, suppose a server with
> two disks has the following directories:
> 
>   /      fsid=1, fileid=2
>   /a     fsid=1, fileid=3
>   /b     fsid=2, fileid=3   (mounted over /b fsid=1, flieid=4)
> 
> When requesting the fsid and fileid attributes from READDIR, Which
> fsid/fileid pair should READDIR return for file name "b".
> 
> Implementers would probably prefer to return fsid=1, fileid=4, because
> this is more efficient in many cases.
> 
> The spec would imply that the correct answer is fsid=2, flieid=3,
> because technically that is correct, and it never says READDIR can
> return anything else.

Yes that's the correct answer. To do otherwise is inconsistent with
the mount point crossing of all the other procedures that deal with
path names.

> In fact, though, if you implement what I think the spec requires, it
> becomes difficult to implement functions like the ANSI C getcwd()
> efficiently.  Moreover, most implementations of getcwd (which are
> optimized to take advantage getting the fileid from OS-specific
> readdir extensions) will need to be changed before they work on NFS4.

I doo have been concerned about this, but I don't think it is impossible to
implement. 

> In the example above, getcwd() might not work from within /a, because
> the client OS can never see the hidden fileid 4 and therefor cannot
> return a fileid unique to fsid=1 for the directory entry /b.

But the client OS can see that the fsid changes. If nothing else, the client
file system can fake the inode # in the readdir results when the entry is a
mount point.

	-mre




From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:17:09 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA25369
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:17:08 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA04497;
	Mon, 6 Mar 2000 15:16:41 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA02164;
	Mon, 6 Mar 2000 15:16:32 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26NGH904194
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:16:17 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA00704;
	Mon, 6 Mar 2000 15:16:16 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA02542;
	Mon, 6 Mar 2000 16:16:15 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id SAA21702;
	Mon, 6 Mar 2000 18:16:06 -0500 (EST)
Date: Mon, 6 Mar 2000 18:16:06 -0500 (EST)
Message-Id: <200003062316.SAA21702@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952383883.4026.mre@eng.sun.com> (message from
	Mike Eisler on Mon, 6 Mar 2000 15:04:43 -0800 (PST))
Subject: Re: attributes of renamed file
References:  <Roam.SIMC.2.0.6.952383883.4026.mre@eng.sun.com>

> Date: Mon, 6 Mar 2000 15:04:43 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> > It would be extremely useful if NFS4 servers could, after a RENAME
> > operation, atomically return the file handle and change_info4 of the
> > file actually being renamed.  In many implementations the server will
> > already have this information handy.  The client could use this
> > information to invalidate cached attributes without exposing itself to
> > a race condition as it must currently do.
> 
> Could you describe the race condition? The NFSv3 RENAME procedure didn't
> include the equivalent of change_info4 on the target file, just from source and target directories?
> 
> If the client has never cached any data on the file being renamed, why should
> client and network be forced to bear the burden of extraneous information?
> 
> If the information is handy, COMPOUND can be used to get it.

Is a COMPOUND operation atomic?  Suppose the client renames a file and
then does a LOOKUP.  If someone else gets in there and renames the
file again, the client will end up thinking it renamed the wrong
file.

Suppose the client is caching the attributes for file A, and then
RENAMEs file A but thinks it renamed file B (because of a non-atomic
compound operation).  If it doesn't flush the attributes for file A,
it may return the wrong ctime in a stat system call.

This can actually be pretty annoying in applications that rename a
file then stat it.  If they get a stale ctime, the next time they stat
the file they will think it has changed, even though it hasn't changed
since the rename.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:21:09 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA26204
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:21:09 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA04663;
	Mon, 6 Mar 2000 16:19:19 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA07375;
	Mon, 6 Mar 2000 15:19:06 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26NIu904198
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:18:56 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA03159;
	Mon, 6 Mar 2000 15:18:55 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA04327;
	Mon, 6 Mar 2000 16:18:53 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id SAA16982;
	Mon, 6 Mar 2000 18:18:49 -0500 (EST)
Date: Mon, 6 Mar 2000 18:18:49 -0500 (EST)
Message-Id: <200003062318.SAA16982@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952384138.21683.mre@eng.sun.com> (message from
	Mike Eisler on Mon, 6 Mar 2000 15:08:58 -0800 (PST))
Subject: Re: READDIR attributes ambiguity
References:  <Roam.SIMC.2.0.6.952384138.21683.mre@eng.sun.com>

> Date: Mon, 6 Mar 2000 15:08:58 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> >   /      fsid=1, fileid=2
> >   /a     fsid=1, fileid=3
> >   /b     fsid=2, fileid=3   (mounted over /b fsid=1, flieid=4)
> 
> But the client OS can see that the fsid changes. If nothing else, the client
> file system can fake the inode # in the readdir results when the entry is a
> mount point.

What fake inode # should it use.  Are any fileid's reserved for the
client (like maybe 0)?  The problem is the client cannot pick a unique
fileid to make up, because, in the example, it doesn't even know about
the number 4 which would be guaranteed to be unique.

David



From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:36:29 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA28775
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:36:29 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA14544;
	Mon, 6 Mar 2000 16:33:23 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA09972;
	Mon, 6 Mar 2000 15:32:50 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.85.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26NWc904203
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:32:38 -0800 (PST)
Received: from teal (awe171-58.AWE.Sun.COM [192.29.171.58])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26NWcL18844;
	Mon, 6 Mar 2000 15:32:38 -0800 (PST)
Date: Mon, 6 Mar 2000 15:35:34 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: READDIR attributes ambiguity
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003062318.SAA16982@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952385734.4628.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> > Date: Mon, 6 Mar 2000 15:08:58 -0800 (PST)
> > From: Mike Eisler <mre@eng.sun.com>
> > 
> > >   /      fsid=1, fileid=2
> > >   /a     fsid=1, fileid=3
> > >   /b     fsid=2, fileid=3   (mounted over /b fsid=1, flieid=4)
> > 
> > But the client OS can see that the fsid changes. If nothing else, the client
> > file system can fake the inode # in the readdir results when the entry is a
> > mount point.
> 
> What fake inode # should it use.  Are any fileid's reserved for the
> client (like maybe 0)?  The problem is the client cannot pick a unique
> fileid to make up, because, in the example, it doesn't even know about
> the number 4 which would be guaranteed to be unique.

Since the purpose is give getcwd a fileid that is different from that of the
/b, any fileid that doesn't conflict with the readdir results should suffice. The
getcwd() library code I'm looking at as this snippet:

 		if (nd.st_ino != dir->d_ino) {
                        (void) closedir(ndirp);
                        goto do_mount_pt;
                }

Personally, I think comparing the inode# from readdir to that from stat
is a extremely crude. 

	-mre

> 
> David




From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 18:43:47 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA29950
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 18:43:47 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA17176;
	Mon, 6 Mar 2000 15:43:24 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA09011;
	Mon, 6 Mar 2000 15:43:17 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.87.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e26Nh5904207
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 15:43:05 -0800 (PST)
Received: from teal (awe171-58.AWE.Sun.COM [192.29.171.58])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e26Nh4L20904;
	Mon, 6 Mar 2000 15:43:04 -0800 (PST)
Date: Mon, 6 Mar 2000 15:46:00 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: attributes of renamed file
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003062316.SAA21702@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> Is a COMPOUND operation atomic?  Suppose the client renames a file and
> then does a LOOKUP.  If someone else gets in there and renames the
> file again, the client will end up thinking it renamed the wrong
> file.
> 
> Suppose the client is caching the attributes for file A, and then
> RENAMEs file A but thinks it renamed file B (because of a non-atomic
> compound operation).  If it doesn't flush the attributes for file A,
> it may return the wrong ctime in a stat system call.

If the server indicates the file handle is volatile through RENAMEs, then the
the client shouldn't be caching attributes over a RENAME. If the file handle is
not volatile through a RENAME, then I don't see the problem.

> This can actually be pretty annoying in applications that rename a
> file then stat it.  If they get a stale ctime, the next time they stat
> the file they will think it has changed, even though it hasn't changed
> since the rename.

The above applies to a local file system. Such applications
had better cache inode# information before the rename.

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 22:44:53 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id WAA14564
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 22:44:53 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id TAA10529;
	Mon, 6 Mar 2000 19:44:20 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id TAA27988;
	Mon, 6 Mar 2000 19:44:11 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e273hw904280
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 19:43:59 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id TAA15317;
	Mon, 6 Mar 2000 19:43:57 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA02226;
	Mon, 6 Mar 2000 20:43:57 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id WAA10954;
	Mon, 6 Mar 2000 22:43:56 -0500 (EST)
Date: Mon, 6 Mar 2000 22:43:56 -0500 (EST)
Message-Id: <200003070343.WAA10954@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952385734.4628.mre@eng.sun.com> (message from
	Mike Eisler on Mon, 6 Mar 2000 15:35:34 -0800 (PST))
Subject: Re: READDIR attributes ambiguity
References:  <Roam.SIMC.2.0.6.952385734.4628.mre@eng.sun.com>

> Date: Mon, 6 Mar 2000 15:35:34 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> Since the purpose is give getcwd a fileid that is different from that of the
> /b, any fileid that doesn't conflict with the readdir results should
> suffice.

But you might not get the fileid for /b until a subsequent readdir.
Currently, the only way to guarantee that a fileid you generate will
not conflict with another fileid in the same directory would be to
read the entire directory first.  It would be nice to support existing
implementations of getcwd without committing to unbounded storage in
the kernel.

> The
> getcwd() library code I'm looking at as this snippet:
> 
>  		if (nd.st_ino != dir->d_ino) {
>                         (void) closedir(ndirp);
>                         goto do_mount_pt;
>                 }
> 
> Personally, I think comparing the inode# from readdir to that from stat
> is a extremely crude. 

Well, it's also much more efficient.  It saves a lot of system calls,
and on some file systems it saves a lot of RPCs.  Obviously NFS3 and 4
will cost you fewer RPCs than NFS2 (at least in theory--several OSes
prime the attribute cache but not the name cache with READDIRPLUS).
Nonetheless, people will still want getcwd() to work fast on NFS2.

There's also, of course, the question of efficiency at the server,
though that is probably less of an issue.

David


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar  6 23:04:20 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id XAA17251
	for <nfsv4-archive@odin.ietf.org>; Mon, 6 Mar 2000 23:04:20 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA14758;
	Mon, 6 Mar 2000 20:03:43 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA29185;
	Mon, 6 Mar 2000 20:03:38 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e2743Q904286
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 6 Mar 2000 20:03:27 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA29164;
	Mon, 6 Mar 2000 20:03:24 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA13385;
	Mon, 6 Mar 2000 20:03:23 -0800 (PST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id XAA11306;
	Mon, 6 Mar 2000 23:03:22 -0500 (EST)
Date: Mon, 6 Mar 2000 23:03:22 -0500 (EST)
Message-Id: <200003070403.XAA11306@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com> (message from
	Mike Eisler on Mon, 6 Mar 2000 15:46:00 -0800 (PST))
Subject: Re: attributes of renamed file
References:  <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com>

> Date: Mon, 6 Mar 2000 15:46:00 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> > Is a COMPOUND operation atomic?  Suppose the client renames a file and
> > then does a LOOKUP.  If someone else gets in there and renames the
> > file again, the client will end up thinking it renamed the wrong
> > file.
> > 
> > Suppose the client is caching the attributes for file A, and then
> > RENAMEs file A but thinks it renamed file B (because of a non-atomic
> > compound operation).  If it doesn't flush the attributes for file A,
> > it may return the wrong ctime in a stat system call.
> 
> If the server indicates the file handle is volatile through RENAMEs, then the
> the client shouldn't be caching attributes over a RENAME. If the file handle is
> not volatile through a RENAME, then I don't see the problem.

Sorry, this is not what I meant.  Suppose file handles are not
volatile.  The issue is knowing which file handle you actually
modified the ctime of.  Otherwise, in order to be completely correct,
you would need to flush all your cached attributes whenever you
renamed any file (because for all you know you could have renamed any
file).

One possibility would be to make the current file handle into the file
handle of the renamed file.  This information will almost certainly be
readily available to the server (since it has to update the attributes
of the renamed file).

> > This can actually be pretty annoying in applications that rename a
> > file then stat it.  If they get a stale ctime, the next time they stat
> > the file they will think it has changed, even though it hasn't changed
> > since the rename.
> 
> The above applies to a local file system. Such applications
> had better cache inode# information before the rename.

It's not an issue in the local file system, because the local file
system knows which file it has renamed.  Thus, it never lets status
information get out of date.

Here is an example of code that could behave incorrectly if the client
didn't figure out which file handle it renamed.  Imagine a text editor
like emacs that performs the following series of system calls:

     fd = open (".#foo#", ...)
     write (fd, ...);
     fsync (fd);
     rename (".#foo#", "foo");
     fstat (fd, &sb);
     close (fd);

Then, when the user next goes to write the file out:

     stat ("foo", &sb2);
     if (sb.st_ino != sb2.st_ino || sb.st_mtime != sb2.st_mtime || ...)
         || sb.st_ctime != sb2.st_ctime || ...)
       warn ("File has been modified.  Really save?");

If the client doesn't know which file handle it has renamed, it will
not flush the attribute cache for that file handle.  Thus, the fstat
call will then return the wrong ctime for the file (the ctime before
the rename), and text editor will incorrectly print this warning
message (assuming by then the attribute cache has timed out).

David


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 03:35:51 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id DAA24788
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 03:35:48 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id AAA08955;
	Tue, 7 Mar 2000 00:35:12 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id AAA14028;
	Tue, 7 Mar 2000 00:33:47 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.82.166] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e278XX904382
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 00:33:34 -0800 (PST)
Received: from eng.sun.com (awe195-141.AWE.Sun.COM [192.29.195.141])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e278XYL23956
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 00:33:34 -0800 (PST)
Sender: Brent.Callaghan@eng.sun.com
Message-ID: <38C4BE88.87D50F48@eng.sun.com>
Date: Tue, 07 Mar 2000 00:32:08 -0800
From: Brent <brent@eng.sun.com>
Organization: NFS Whackers
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.8 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: nfsv4-wg@sunroof.eng.sun.com
Subject: Re: READDIR attributes ambiguity
References: <Roam.SIMC.2.0.6.952385734.4628.mre@eng.sun.com> <200003070343.WAA10954@reeducation-labor.lcs.mit.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

David Mazieres wrote:
> 
> > Date: Mon, 6 Mar 2000 15:35:34 -0800 (PST)
> > From: Mike Eisler <mre@eng.sun.com>
> >
> > Since the purpose is give getcwd a fileid that is different from that of the
> > /b, any fileid that doesn't conflict with the readdir results should
> > suffice.
> 
> But you might not get the fileid for /b until a subsequent readdir.
> Currently, the only way to guarantee that a fileid you generate will
> not conflict with another fileid in the same directory would be to
> read the entire directory first.  It would be nice to support existing
> implementations of getcwd without committing to unbounded storage in
> the kernel.

Perhaps an easier way to resolve this would be to have a "mounted on"
fileid attribute, e.g. call it "mfileid".

POSIX clients could then ask READDIR to return both "fileid" and
"mfileid"
attributes.  The "mfileid" would be returned in response to getdents()
calls
on UNIX clients, and the "fileid" would be cached along with other file
attributes for the directory entry, i.e. a subsequent "stat()" call
on the client would return the "fileid".

	Brent


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 04:01:55 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id EAA00280
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 04:01:53 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id BAA16228;
	Tue, 7 Mar 2000 01:01:18 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id BAA15532;
	Tue, 7 Mar 2000 01:01:12 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.86.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e2790u904391
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 01:00:56 -0800 (PST)
Received: from eng.sun.com (awe195-141.AWE.Sun.COM [192.29.195.141])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e2790uL25100;
	Tue, 7 Mar 2000 01:00:56 -0800 (PST)
Sender: Brent.Callaghan@eng.sun.com
Message-ID: <38C4C4F2.C53E9138@eng.sun.com>
Date: Tue, 07 Mar 2000 00:59:30 -0800
From: Brent <brent@eng.sun.com>
Organization: NFS Whackers
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.8 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
CC: nfsv4-wg@sunroof.eng.sun.com
Subject: Re: attributes of renamed file
References: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com> <200003070403.XAA11306@reeducation-labor.lcs.mit.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

David Mazieres wrote:
> It's not an issue in the local file system, because the local file
> system knows which file it has renamed.  Thus, it never lets status
> information get out of date.
> 
> Here is an example of code that could behave incorrectly if the client
> didn't figure out which file handle it renamed.  Imagine a text editor
> like emacs that performs the following series of system calls:
> 
>      fd = open (".#foo#", ...)
>      write (fd, ...);
>      fsync (fd);
>      rename (".#foo#", "foo");
>      fstat (fd, &sb);
>      close (fd);
> 
> Then, when the user next goes to write the file out:
> 
>      stat ("foo", &sb2);
>      if (sb.st_ino != sb2.st_ino || sb.st_mtime != sb2.st_mtime || ...)
>          || sb.st_ctime != sb2.st_ctime || ...)
>        warn ("File has been modified.  Really save?");
> 
> If the client doesn't know which file handle it has renamed, it will
> not flush the attribute cache for that file handle.  Thus, the fstat
> call will then return the wrong ctime for the file (the ctime before
> the rename), and text editor will incorrectly print this warning
> message (assuming by then the attribute cache has timed out).


Like Mike, I can't see a confusion problem here.  

If the client manipulates the file through its filehandle, or
in the example, through its file descriptor, then the renames
have no effect on the file contents or attributes.  The file
name is completely independent of the file content or attributes.

If the client app needs a stable reference to the file content (as in
the case of a text editor) then to be independent of renames, it must
reference the file through its file descriptor.

If the client app chooses to use the file name as a reference, then
there's a risk the name will change unexpectedly.

	Brent


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 08:17:33 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id IAA22666
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 08:17:30 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id FAA28384;
	Tue, 7 Mar 2000 05:16:27 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id FAA19517;
	Tue, 7 Mar 2000 05:16:21 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27DGA904484
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 05:16:10 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id FAA26775;
	Tue, 7 Mar 2000 05:16:09 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id FAA05074;
	Tue, 7 Mar 2000 05:16:08 -0800 (PST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id IAA28900;
	Tue, 7 Mar 2000 08:16:03 -0500 (EST)
Date: Tue, 7 Mar 2000 08:16:03 -0500 (EST)
Message-Id: <200003071316.IAA28900@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: brent@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <38C4C4F2.C53E9138@eng.sun.com> (message from Brent on Tue, 07
	Mar 2000 00:59:30 -0800)
Subject: Re: attributes of renamed file
References: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com> <200003070403.XAA11306@reeducation-labor.lcs.mit.edu> <38C4C4F2.C53E9138@eng.sun.com>

> Date: Tue, 07 Mar 2000 00:59:30 -0800
> From: Brent <brent@eng.sun.com>
> 
> Like Mike, I can't see a confusion problem here.  
> 
> If the client manipulates the file through its filehandle, or
> in the example, through its file descriptor, then the renames
> have no effect on the file contents or attributes.  The file
> name is completely independent of the file content or attributes.

Not so in most Unix file systems.  Changing the file's name changes
the ctime.  Since a bumped ctime may also be a sign of someone
manually fiddling with the mtime, applications may react to this.

> If the client app needs a stable reference to the file content (as in
> the case of a text editor) then to be independent of renames, it must
> reference the file through its file descriptor.

I agree.  However, as a rule, when the the client manipulates a file
by name, it is useful to tell it what file it has actually manipulated
so that it can keep its attribute cache in order.

To take another approach, consider, by analogy, the CREATE operation.
CREATE sets (chf) to the file handle of the newly created object,
presumably so the client can do a GETFH and find out what it just
created.  You could have left (cfh) as the parent directory, arguing
"just append a LOOKUP to the CREATE with COMPOUND", but this would
have opened a race condition since the compound is not atomic.

With RENAME, it's also important to know what file you are
renaming--so you can flush it from the attribute cache (or, better
yet, GETATTR it in a COMPOUND).

> If the client app chooses to use the file name as a reference, then
> there's a risk the name will change unexpectedly.

No argument about that.  The problem is using the file handle as a
reference (through a file descriptor), simultaneously manipulating the
file through its name, and in the end not realizing the file you just
manipulated corresponds to the file handle.

David


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:07:06 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA18788
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:07:04 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA09626;
	Tue, 7 Mar 2000 07:06:18 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA03965;
	Tue, 7 Mar 2000 07:05:27 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27F5D904511
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:05:14 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA22478
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:05:14 -0800 (PST)
Received: from penguin.wise.edt.ericsson.se (penguin-ext.wise.edt.ericsson.se [194.237.142.110])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA29689
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 08:05:13 -0700 (MST)
Received: from ms.uab.ericsson.se (ms.uab.ericsson.se [134.138.201.16])
	by penguin.wise.edt.ericsson.se (8.9.3/8.9.3/WIREfire-1.5) with ESMTP id QAA03526
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 16:05:12 +0100 (MET)
Received: from uabs78c65.uab.ericsson.se (uabs78c65 [134.138.201.115])
	by ms.uab.ericsson.se (8.9.3/8.9.3/uab-2.21) with ESMTP id QAA05666
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 16:05:11 +0100 (MET)
Received: from uab.ericsson.se by uabs78c65.uab.ericsson.se (8.8.8/client-1.3uab2)
	id QAA05817; Tue, 7 Mar 2000 16:05:10 +0100 (MET)
Sender: Michael.Salmon@uab.ericsson.se
Message-ID: <38C51AA2.8CE7D7B8@uab.ericsson.se>
Date: Tue, 07 Mar 2000 16:05:06 +0100
From: Michael Salmon <Michael.Salmon@uab.ericsson.se>
Organization: Ericsson Utvecklings AB
X-Mailer: Mozilla 4.72C-CCK-MCD  [en] (X11; U; SunOS 5.7 sun4u)
X-Accept-Language: sv, en-GB, en-US, en
MIME-Version: 1.0
To: nfsv4-wg@sunroof.eng.sun.com
Subject: Re: attributes of renamed file
References: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com> <200003070403.XAA11306@reeducation-labor.lcs.mit.edu> <38C4C4F2.C53E9138@eng.sun.com> <200003071316.IAA28900@reeducation-labor.lcs.mit.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

David Mazieres wrote:
> 
> > Date: Tue, 07 Mar 2000 00:59:30 -0800
> > From: Brent <brent@eng.sun.com>
> >
> > Like Mike, I can't see a confusion problem here.
> >
> > If the client manipulates the file through its filehandle, or
> > in the example, through its file descriptor, then the renames
> > have no effect on the file contents or attributes.  The file
> > name is completely independent of the file content or attributes.
> 
> Not so in most Unix file systems.  Changing the file's name changes
> the ctime.  Since a bumped ctime may also be a sign of someone
> manually fiddling with the mtime, applications may react to this.

The ctime is only updated when the inode changes and the file's name is not
coupled to the inode. File names only exist in directories, a file doesn't
even need to have a name.

/Michael
-- 
This space intentionally left non-blank.


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:16:49 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA21092
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:16:48 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA06009;
	Tue, 7 Mar 2000 08:16:03 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA27885;
	Tue, 7 Mar 2000 07:15:48 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.86.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FFR904537
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:15:27 -0800 (PST)
Received: from teal (awe171-92.AWE.Sun.COM [192.29.171.92])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e27FFRL11202;
	Tue, 7 Mar 2000 07:15:27 -0800 (PST)
Date: Tue, 7 Mar 2000 07:18:22 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: READDIR attributes ambiguity
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003070343.WAA10954@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952442302.1036.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> > Date: Mon, 6 Mar 2000 15:35:34 -0800 (PST)
> > From: Mike Eisler <mre@eng.sun.com>
> > 
> > Since the purpose is give getcwd a fileid that is different from that of the
> > /b, any fileid that doesn't conflict with the readdir results should
> > suffice.
> 
> But you might not get the fileid for /b until a subsequent readdir.

I don't undnerstand. If a reader is not on the server's /, you'll get the
fileid of what is mounted on /b.

> Currently, the only way to guarantee that a fileid you generate will
> not conflict with another fileid in the same directory would be to
> read the entire directory first.  It would be nice to support existing
> implementations of getcwd without committing to unbounded storage in
> the kernel.

Someday, and that day may even be today with W2k, non-UNIX systems are going
to mount drives in arbitrary places, and aren't necessarily going to adhere
to UNIX semantics. The time is nigh for getcwd to adapt.

> > The
> > getcwd() library code I'm looking at as this snippet:
> > 
> >  		if (nd.st_ino != dir->d_ino) {
> >                         (void) closedir(ndirp);
> >                         goto do_mount_pt;
> >                 }
> > 
> > Personally, I think comparing the inode# from readdir to that from stat
> > is a extremely crude. 
> 
> Well, it's also much more efficient.  It saves a lot of system calls,

You can achieve the same effect by looking at the st_dev of the directory and
the directory's "..".

As Brent says, a "mounted on fileid" attribute would be another way to solve
this. NFSv4 testing is going at connectathon this week, and it would be
interesting to get experience before we rush in and add the attribute.

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:17:39 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA21275
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:17:38 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA14858;
	Tue, 7 Mar 2000 07:17:15 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA23678;
	Tue, 7 Mar 2000 07:16:58 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FGe904545
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:16:41 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA28684
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:16:38 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA06457
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 08:16:37 -0700 (MST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id KAA31785;
	Tue, 7 Mar 2000 10:16:30 -0500 (EST)
Date: Tue, 7 Mar 2000 10:16:30 -0500 (EST)
Message-Id: <200003071516.KAA31785@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: Michael.Salmon@uab.ericsson.se
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <38C51AA2.8CE7D7B8@uab.ericsson.se> (message from Michael Salmon
	on Tue, 07 Mar 2000 16:05:06 +0100)
Subject: Re: attributes of renamed file
References: <Roam.SIMC.2.0.6.952386360.14958.mre@eng.sun.com> <200003070403.XAA11306@reeducation-labor.lcs.mit.edu> <38C4C4F2.C53E9138@eng.sun.com> <200003071316.IAA28900@reeducation-labor.lcs.mit.edu> <38C51AA2.8CE7D7B8@uab.ericsson.se>

> Date: Tue, 07 Mar 2000 16:05:06 +0100
> From: Michael Salmon <Michael.Salmon@uab.ericsson.se>
> 
> The ctime is only updated when the inode changes and the file's name is not
> coupled to the inode. File names only exist in directories, a file doesn't
> even need to have a name.

Perhaps in part for historical reasons (since rename used to be a
non-atomic link and unlink), rename bumps the ctime of a file.  It
would be very difficult to do things like incremental backups of a
directory without this feature, however, so I think it's not a bad
thing.

More concretely, though, I just tried this out on a solaris box, and
rename definitely bumps the ctime of a file, whether or not you agree
with the behavior.  It has been my experience that all Unixes do this.

David


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:19:13 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA21630
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:19:12 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA15925;
	Tue, 7 Mar 2000 07:18:49 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA05459;
	Tue, 7 Mar 2000 07:18:32 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.86.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FIM904558
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:18:23 -0800 (PST)
Received: from teal (awe171-92.AWE.Sun.COM [192.29.171.92])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e27FIML11724;
	Tue, 7 Mar 2000 07:18:22 -0800 (PST)
Date: Tue, 7 Mar 2000 07:21:18 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: READDIR attributes ambiguity
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>,
        nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <Roam.SIMC.2.0.6.952442302.1036.mre@eng.sun.com>
Message-ID: <Roam.SIMC.2.0.6.952442478.15649.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> > But you might not get the fileid for /b until a subsequent readdir.
> 
> I don't undnerstand. If a reader is not on the server's /, you'll get the
> fileid of what is mounted on /b.

Let's try that again:

If a readdir is on the server's /, you'll get the fileid of what is mounted on
/b.



From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:19:58 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA21813
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:19:57 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA06735;
	Tue, 7 Mar 2000 08:17:02 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA27971;
	Tue, 7 Mar 2000 07:16:52 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.86.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FGQ904542
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:16:26 -0800 (PST)
Received: from teal (awe171-92.AWE.Sun.COM [192.29.171.92])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e27FGPL11365;
	Tue, 7 Mar 2000 07:16:25 -0800 (PST)
Date: Tue, 7 Mar 2000 07:19:21 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: attributes of renamed file
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003070403.XAA11306@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952442361.3970.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> > If the server indicates the file handle is volatile through RENAMEs, then
> the > the client shouldn't be caching attributes over a RENAME. If the file
> handle is > not volatile through a RENAME, then I don't see the problem.
> Sorry, this is not what I meant.  Suppose file handles are not
> volatile.  The issue is knowing which file handle you actually
> modified the ctime of.  Otherwise, in order to be completely correct,
> you would need to flush all your cached attributes whenever you
> renamed any file (because for all you know you could have renamed any
> file).

Sorry, I'm just not getting it. The issue, whatever it is, is no
different from NFSv2 and NFSv3, and I don't know of any ctime problems
with RENAME.

> Then, when the user next goes to write the file out:
> 
>      stat ("foo", &sb2);
>      if (sb.st_ino != sb2.st_ino || sb.st_mtime != sb2.st_mtime || ...)
>          || sb.st_ctime != sb2.st_ctime || ...)
>        warn ("File has been modified.  Really save?");
> 
> If the client doesn't know which file handle it has renamed, it will
> not flush the attribute cache for that file handle. 

The client that supposedly doesn't know which file handle has been "renamed"
(the file handle doesn't change btw), is the one that did the rename. 
The client thus knows to flush its attributes.

"Michael Salmon" <Michael.Salmon@uab.ericsson.se> wrote:
> The ctime is only updated when the inode changes and the file's name is not
> coupled to the inode. File names only exist in directories, a file doesn't
> even need to have a name.

You would think. However I just ran a quick test on a local file system, and
saw that rename did change the ctime.

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:22:43 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA22493
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:22:42 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA17844;
	Tue, 7 Mar 2000 07:22:17 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA00276;
	Tue, 7 Mar 2000 07:22:10 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FM1904562
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:22:01 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA05895;
	Tue, 7 Mar 2000 07:22:01 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA03589;
	Tue, 7 Mar 2000 07:22:00 -0800 (PST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id KAA11214;
	Tue, 7 Mar 2000 10:21:55 -0500 (EST)
Date: Tue, 7 Mar 2000 10:21:55 -0500 (EST)
Message-Id: <200003071521.KAA11214@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952442361.3970.mre@eng.sun.com> (message from
	Mike Eisler on Tue, 7 Mar 2000 07:19:21 -0800 (PST))
Subject: Re: attributes of renamed file
References:  <Roam.SIMC.2.0.6.952442361.3970.mre@eng.sun.com>

> Date: Tue, 7 Mar 2000 07:19:21 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> Sorry, I'm just not getting it. The issue, whatever it is, is no
> different from NFSv2 and NFSv3, and I don't know of any ctime problems
> with RENAME.

Actually this was a problem in older NFSes to.  I got badly burned by
this.  Obviously I make somewhat "unusual" use of the file system that
I don't expect you guys to sympathize with.  Nonetheless the race is
present in previous versions of NFS.

> > Then, when the user next goes to write the file out:
> > 
> >      stat ("foo", &sb2);
> >      if (sb.st_ino != sb2.st_ino || sb.st_mtime != sb2.st_mtime || ...)
> >          || sb.st_ctime != sb2.st_ctime || ...)
> >        warn ("File has been modified.  Really save?");
> > 
> > If the client doesn't know which file handle it has renamed, it will
> > not flush the attribute cache for that file handle. 
> 
> The client that supposedly doesn't know which file handle has been "renamed"
> (the file handle doesn't change btw), is the one that did the rename. 
> The client thus knows to flush its attributes.

No, because there is a race condition.  If no one else touches the
file system, the client knows what file it has renamed.  If another
user changes things around at just the right time, howeve, the rename
will actually apply to another file.

David


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 10:32:04 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA24762
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 10:32:03 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA23878;
	Tue, 7 Mar 2000 07:31:02 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA24667;
	Tue, 7 Mar 2000 07:28:22 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.87.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27FS9904566
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 07:28:09 -0800 (PST)
Received: from teal (awe171-92.AWE.Sun.COM [192.29.171.92])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e27FS9L12508;
	Tue, 7 Mar 2000 07:28:09 -0800 (PST)
Date: Tue, 7 Mar 2000 07:31:04 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: attributes of renamed file
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003071521.KAA11214@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952443064.1721.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> > >      stat ("foo", &sb2);
> > >      if (sb.st_ino != sb2.st_ino || sb.st_mtime != sb2.st_mtime || ...)
> > >          || sb.st_ctime != sb2.st_ctime || ...)
> > >        warn ("File has been modified.  Really save?");

> > The client that supposedly doesn't know which file handle has been
> "renamed" > (the file handle doesn't change btw), is the one that did the
> rename.  > The client thus knows to flush its attributes.
> 
> No, because there is a race condition.  If no one else touches the
> file system, the client knows what file it has renamed.  If another
> user changes things around at just the right time, howeve, the rename
> will actually apply to another file.

Sorry, I guess I'm dense, but I don't see what problem you are trying to
solve, and how adding an a ctime to the results of the of
REANME will solve it. 

	-mre



From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 11:14:41 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id LAA02635
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 11:14:40 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA14781;
	Tue, 7 Mar 2000 08:11:23 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA12379;
	Tue, 7 Mar 2000 08:11:16 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27GB4904592
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 08:11:05 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA00188;
	Tue, 7 Mar 2000 08:11:04 -0800 (PST)
Received: from reeducation-labor.lcs.mit.edu (reeducation-labor.lcs.mit.edu [18.26.4.10])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA00850;
	Tue, 7 Mar 2000 08:11:02 -0800 (PST)
Received: (from dm@localhost)
	by reeducation-labor.lcs.mit.edu (8.9.3/8.8.7) id LAA07421;
	Tue, 7 Mar 2000 11:11:01 -0500 (EST)
Date: Tue, 7 Mar 2000 11:11:01 -0500 (EST)
Message-Id: <200003071611.LAA07421@reeducation-labor.lcs.mit.edu>
From: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
To: mre@eng.sun.com
CC: nfsv4-wg@sunroof.eng.sun.com
In-reply-to: <Roam.SIMC.2.0.6.952442302.1036.mre@eng.sun.com> (message from
	Mike Eisler on Tue, 7 Mar 2000 07:18:22 -0800 (PST))
Subject: Re: READDIR attributes ambiguity
References:  <Roam.SIMC.2.0.6.952442302.1036.mre@eng.sun.com>

> Date: Tue, 7 Mar 2000 07:18:22 -0800 (PST)
> From: Mike Eisler <mre@eng.sun.com>
> 
> I don't undnerstand. If a reader is not on the server's /, you'll get the
> fileid of what is mounted on /b.

That's correct, and fileids are not unique across fsid's.  Software
makes two assumptions:

   * st_ino's are unique within a given file system
   * all files in a directory are in the same file system

An NFS4 client implementation cannot make these guarantees in constant
space.  (It could maybe read the whole directory and make up unique
fileids where the fsids do not match, but this will not work well on
large directories.)

> Someday, and that day may even be today with W2k, non-UNIX systems are going
> to mount drives in arbitrary places, and aren't necessarily going to adhere
> to UNIX semantics. The time is nigh for getcwd to adapt.

Can't you already mount drives in arbitrary places in UNIX?  Certainly
it's easy for the server to make up fileid's in software for each
mount point, since the server knows about all the mount points.

> > > The
> > > getcwd() library code I'm looking at as this snippet:
> > > 
> > >  		if (nd.st_ino != dir->d_ino) {
> > >                         (void) closedir(ndirp);
> > >                         goto do_mount_pt;
> > >                 }
> > > 
> > > Personally, I think comparing the inode# from readdir to that from stat
> > > is a extremely crude. 
> > 
> > Well, it's also much more efficient.  It saves a lot of system calls,
> 
> You can achieve the same effect by looking at the st_dev of the directory and
> the directory's "..".

Indeed, this is what's going on.  I believe the common algorithm for
getcwd is as follows:

     stat (".", &sb);
     stat ("..", &sb2);

     if (sb.st_dev != sb2.st_dev) {
       /* Different file systems, so lstat every file in .. */
     }
     else {
       /* Same file system, look for d_ino matching sb.st_ino */
     }

> As Brent says, a "mounted on fileid" attribute would be another way to solve
> this. NFSv4 testing is going at connectathon this week, and it would be
> interesting to get experience before we rush in and add the attribute.

Well, whether or not the problem comes up depends on how you mount
things.  This is a low probability bug, depending on inumber
allocations, but will be really annoying when it occurs.

To see the bug, you would need to need to mount a file system in which
the inumber of the root equals the inumber of another sibling
directory in the parent file system.

David


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar  7 11:21:42 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id LAA03694
	for <nfsv4-archive@odin.ietf.org>; Tue, 7 Mar 2000 11:21:40 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA19673;
	Tue, 7 Mar 2000 08:21:03 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA13468;
	Tue, 7 Mar 2000 08:20:56 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.84.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with ESMTP id e27GKj904630
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 7 Mar 2000 08:20:45 -0800 (PST)
Received: from teal (awe171-92.AWE.Sun.COM [192.29.171.92])
	by jurassic.eng.sun.com (8.10.0.Gamma0+Sun/8.10.0.Gamma0) with SMTP id e27GKhL22922;
	Tue, 7 Mar 2000 08:20:44 -0800 (PST)
Date: Tue, 7 Mar 2000 08:23:39 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: Re: READDIR attributes ambiguity
To: David Mazieres <dm@reeducation-labor.lcs.mit.edu>
Cc: nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <200003071611.LAA07421@reeducation-labor.lcs.mit.edu>
Message-ID: <Roam.SIMC.2.0.6.952446219.31571.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> That's correct, and fileids are not unique across fsid's.  Software
> makes two assumptions:
> 
>    * st_ino's are unique within a given file system
>    * all files in a directory are in the same file system
> 
> An NFS4 client implementation cannot make these guarantees in constant
> space.  (It could maybe read the whole directory and make up unique
> fileids where the fsids do not match, but this will not work well on
> large directories.)

And by the way, the algorithm that getcwd() uses doesn't scale on large
directories, with or with out Brent's "fileid on mounted dir." attribute.

getcwd() needs to enter the 21st century.

> > Someday, and that day may even be today with W2k, non-UNIX systems are going
> > to mount drives in arbitrary places, and aren't necessarily going to adhere
> > to UNIX semantics. The time is nigh for getcwd to adapt.
> 
> Can't you already mount drives in arbitrary places in UNIX?  Certainly
> it's easy for the server to make up fileid's in software for each
> mount point, since the server knows about all the mount points.

Yes you can, and UNIX local file systems will preserve the semantics that
getcwd() wants. I'm saying that non-UNIX systems might not, and if so,
then what? The "fileid on mounted dir." attribute buys you absolutely
nohting, especially since non-UNIX systems often routinely fake fileids
for READDIR and GETATTR.

> To see the bug, you would need to need to mount a file system in which
> the inumber of the root equals the inumber of another sibling
> directory in the parent file system.

In UNIX land, isn't the fileid of root always equal to 2, and the fileid
of any other directory not euqal to 2?

	-mre
> 
> David




From nfs4-wg-request@sunroof.eng.sun.com  Sun Mar 12 00:57:52 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id AAA06500
	for <nfsv4-archive@odin.ietf.org>; Sun, 12 Mar 2000 00:57:51 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id WAA06659;
	Sat, 11 Mar 2000 22:57:16 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id VAA27290;
	Sat, 11 Mar 2000 21:56:59 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2C5ulw08463;
	Sat, 11 Mar 2000 21:56:47 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id VAA20631;
	Sat, 11 Mar 2000 21:56:47 -0800 (PST)
Received: from mega.telekom.com.my ([202.188.127.66])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id VAA11869;
	Sat, 11 Mar 2000 21:56:45 -0800 (PST)
Received: from putra ([202.188.127.65])
	by mega.telekom.com.my (8.9.3/8.8.6) with SMTP id NAA18917;
	Sun, 12 Mar 2000 13:56:52 +0800 (SGT)
Message-Id: <200003120556.NAA18917@mega.telekom.com.my>
Received: from pool-208-161-7-182.loa.com ([208.161.7.182]) by putra.telekom.com.my; Sun, 12 Mar 2000 13:53:44 +0000 (SGT)
From: "Andy" <bkp99@newmail.net>
Subject: Have You Seen...
To: new8j@mega.telekom.com.my
X-Mailer: Mozilla 4.70 [en] (Win95; I)
Mime-Version: 1.0
Date: Sat, 11 Mar 2000 23:36:31 -0500
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by ietf.org id AAA06500

FREE E-COMMERCE WHEN YOU HOST WITH US!!

Tired of expensive e-commerce software, set up fees and leasing
contracts?
Here is the deal: You host your site with us and you get free E
-Commerce,
including a merchant account, real-time software and shopping cart.

NO ONE CAN BEAT OUR PRICE! IF YOU FIND A BETTER DEAL FOR OUR PACKAGE
ANYWHERE ELSE, WE WILL MATCH OUR COMPETITOR'S PRICE PLUS GIVE YOU THE
FIRST MONTH FOR FREE. 

While others charge you hundreds of dollars to get a merchant account
or
put you on a 48 months non-cancelable lease agreement we charge you
NOTHING for E-commerce when you sign up for our e-commerce hosting
plan. If you wish to stay with your current hosting company you still
can get the same deal. 
Check it out first and make an informed decision. 

You have never seen a package deal like this before:

* Your own merchant account with one of the lowest rates in the
industry
* Real-Time software to accept VISA, MASTERCARD, AMEX,
DISCOVER/NOVUS, DINERSCLUB/CARTE BLANCHE, JCB
* Direct deposit within 48 hrs into your checking account
* Shopping Cart store front software with an easy to use web based
interface
* Real-Time Credit Card Processing software
* Virtual terminal for phone/fax/mail orders
* Automated E-mail receipts to your clients
* Recurring billing feature with batch uploads
* Password generator for membership sites
* Automatic batch closing
* Address verification system (AVS)
* Back office to 24/7 access account history
* 50 MB (megabytes) of disk space
* 30 GB (gigabyte) of data transfer per month
* 25 POP3 E-mail accounts
* Unlimited alias E-mail addresses
* Live web site statistics
* Unlimited FTP uploads
* Anonymous FTP
* CGI directory for your own scripts
* Site control panel
* Installation included
* Tech support included

All this and more when you sign up for our E-Commerce Hosting plan
for ONLY $69.95 per month and a one time set up fee of $199.00.  That
's right. NO ADDITIONAL SET UP FEES or application fees for your
merchant account
real-time software or shopping cart storefront. A one-stop E-Commerce
solution. And the best is:

NO LEASING, NO LONG TERM COMMITMENT. YOU CAN CANCEL ANYTIME.

THIS PRICE APPLIES TO U.S. BASED COMPANIES OR INDIVIDUALS ONLY! 
BUT WE ALSO HAVE A SOLUTION FOR INTERNATIONAL MERCHANTS! 

Please reply to:

mailto:wrkv@pplmail.com?subject=INFO-PLEASE
to receive our FREE information package without obligations.



 
*********************************************************
Remove at mailto:kwwk@uymail.com?subject=remove 
*********************************************************





From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar 13 06:46:49 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id GAA24235
	for <nfsv4-archive@odin.ietf.org>; Mon, 13 Mar 2000 06:46:47 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id DAA06377;
	Mon, 13 Mar 2000 03:45:39 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA15526;
	Mon, 13 Mar 2000 03:45:27 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2DBjFw09082
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 03:45:16 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA24039
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 03:45:15 -0800 (PST)
Received: from web3703.mail.yahoo.com (web3703.mail.yahoo.com [204.71.203.132])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id EAA10214
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 04:45:14 -0700 (MST)
Message-ID: <20000313114514.29300.qmail@web3703.mail.yahoo.com>
Received: from [202.54.64.130] by web3703.mail.yahoo.com; Mon, 13 Mar 2000 11:45:13 GMT
Date: Mon, 13 Mar 2000 11:45:13 +0000 (GMT)
From: =?iso-8859-1?q?kvs=20sivak?= <kvs_sivak@yahoo.co.uk>
Subject: subscribe to nfs v4
To: nfsv4-wg@sunroof.eng.sun.com
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
Content-Transfer-Encoding: 8bit

SUBSCRIBE
____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar 13 10:12:47 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA11701
	for <nfsv4-archive@odin.ietf.org>; Mon, 13 Mar 2000 10:12:46 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA23740;
	Mon, 13 Mar 2000 07:12:16 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA29461;
	Mon, 13 Mar 2000 07:11:59 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2DFBfw09169
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 07:11:42 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA08294
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 07:11:42 -0800 (PST)
Received: from mx01-ext.netapp.com (mx01-ext.netapp.com [198.95.224.34])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id IAA05402
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 08:11:40 -0700 (MST)
Received: (qmail 18847 invoked from network); 13 Mar 2000 15:18:13 -0000
Received: from herra.netapp.com (HELO herra.corp.netapp.com) (198.95.224.184)
  by mx01-ext.netapp.com with SMTP; 13 Mar 2000 15:18:13 -0000
Received: from tahoe.corp.netapp.com (tahoe.netapp.com [10.10.10.112])
	by herra.corp.netapp.com (8.9.3/8.9.3/NTAP-1.0) with ESMTP id HAA27755;
	Mon, 13 Mar 2000 07:11:33 -0800 (PST)
Received: by tahoe.corp.netapp.com with Internet Mail Service (5.5.2650.21)
	id <F56QCAJD>; Mon, 13 Mar 2000 07:11:33 -0800
Message-ID: <F6C5585BF0CED311B58D009027C2299C47C016@tahoe.corp.netapp.com>
From: "Noveck, Dave" <dave.noveck@netapp.com>
To: "'David Mazieres'" <dm@reeducation-labor.lcs.mit.edu>, mre@eng.sun.com
Cc: nfsv4-wg@sunroof.eng.sun.com
Subject: RE: attributes of renamed file
Date: Mon, 13 Mar 2000 07:11:33 -0800
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2650.21)
Content-Type: text/plain;
	charset="iso-8859-1"

I think that in this case COMPOUND solves the problem, despite
the lack of atomicity, at least when handles are persistent.

Suppose you always follow a RENAME by a LOOKUP of the new name
(and then a GETFH, GETATTR after that).  If you use the 
information you get back properly, the lack of atomicity 
means that you may not know for sure what file got renamed
but you nonetheless have enough information to properly
update any client name and attribute caches.

Assume, without loss of generality, that everything is happening
in a single directory.  Suppose client 1 opens a file A and that
that file had handle h0.  You are going to cache the mapping of 
the name A to handle h0 (or more properly, the vnode associated 
with handle h0) and also cache attributes associated with that
vnode.  Suppose that at some later time, you do a rename of 
A to B which is followed by a LOOKUP of B and then a GETFH
and GETATTR.

We can now update the name and attribute caches as follows:

     If the LOOKUP of B found the handle h0, then we
     can update the cached attributes associated with h0
     and update the name cache by deleting the entry for
     A and adding one for B.  We will be in this case most
     often if in fact the RENAME renamed what we thought
     we renamed, but not always (see below).

     If the LOOKUP of B found a handle other h0 (call it h1), 
     then we update any attribute cache entry we have for
     h1 to reflect the new attributes.  We may also, if we
     choose, create a new attribute cache entry for h1 if
     we don't already have one.  We purge any name cache 
     entries that point to h0 (since we have no idea what
     h0 is named) and also should purge the attributes
     cached for h0, since it was renamed by someone and
     we don't know when.

     If the lookup failed, we also purge the name cache
     and attribute cache entries associated with h0.

The lack of atomcity between the RENAME and LOOKUP means
that even in the first case, we don't know for sure that
h0 was the file which was RENAMED.  We could have had the
following scenario:

     We opened A (and go back the handle h0).

     Another client renamed A to be X.
   
     That client renamed another file (with handle h2, say)
     to be A.

     We did our RENAME with resulted in h2 being called B.

     After out RENAME but before our LOOKUP, come other
     client renamed X (which has handle h0) to be B.

     Our LOOKUP found that the handle corresponding to 
     A was h0, just as it would have been if our RENAME
     had in fact renamed h0 from A to B.

The fact that we don't know what file our RENAME renamed,
doesn't matter.  We know that h0 was RENAMED, if not by
us than by someone else and we also know the handle that
corresponds to the name B at a point after the RENAME,
and the associated attributes, and that is enough.

Now what the above won't do is update or purge the
attribute cache for h2, so accessing that file's attributes
somehow will get a stale ctime, but I don't see that as
a real problem.  NFS's attribute caching has never been 
coherent and is not in V4, either.  Clients typically 
update their own caches to reflect changes they themself
make, to avoid internal inconsistencies.  But in this
case, even though the update of the ctime of h2 is done
by our own RENAME, I can't see that not updating that
ctime poses any problems that wouldn't have happened
anyway given multiple clients would have to be updating
ctimes with their own RENAME's.
     

> -----Original Message-----
> From: David Mazieres [mailto:dm@reeducation-labor.lcs.mit.edu]
> Sent: Monday, March 06, 2000 6:16 PM
> To: mre@eng.sun.com
> Cc: nfsv4-wg@sunroof.eng.sun.com
> Subject: Re: attributes of renamed file
> 
> 
> > Date: Mon, 6 Mar 2000 15:04:43 -0800 (PST)
> > From: Mike Eisler <mre@eng.sun.com>
> > 
> > > It would be extremely useful if NFS4 servers could, after a RENAME
> > > operation, atomically return the file handle and 
> change_info4 of the
> > > file actually being renamed.  In many implementations the 
> server will
> > > already have this information handy.  The client could use this
> > > information to invalidate cached attributes without 
> exposing itself to
> > > a race condition as it must currently do.
> > 
> > Could you describe the race condition? The NFSv3 RENAME 
> procedure didn't
> > include the equivalent of change_info4 on the target file, 
> just from source and target directories?
> > 
> > If the client has never cached any data on the file being 
> renamed, why should
> > client and network be forced to bear the burden of 
> extraneous information?
> > 
> > If the information is handy, COMPOUND can be used to get it.
> 
> Is a COMPOUND operation atomic?  Suppose the client renames a file and
> then does a LOOKUP.  If someone else gets in there and renames the
> file again, the client will end up thinking it renamed the wrong
> file.
> 
> Suppose the client is caching the attributes for file A, and then
> RENAMEs file A but thinks it renamed file B (because of a non-atomic
> compound operation).  If it doesn't flush the attributes for file A,
> it may return the wrong ctime in a stat system call.
> 
> This can actually be pretty annoying in applications that rename a
> file then stat it.  If they get a stale ctime, the next time they stat
> the file they will think it has changed, even though it hasn't changed
> since the rename.
> 
> David
> 


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar 13 12:24:52 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id MAA04080
	for <nfsv4-archive@odin.ietf.org>; Mon, 13 Mar 2000 12:24:51 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id JAA07459;
	Mon, 13 Mar 2000 09:24:14 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id JAA19926;
	Mon, 13 Mar 2000 09:23:53 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.88.31])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2DHNew09327
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 09:23:41 -0800 (PST)
Received: from terra.eng.sun.com (terra.Eng.Sun.COM [129.146.86.99])
	by jurassic.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2DHNfQ878663
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 13 Mar 2000 09:23:41 -0800 (PST)
Received: (from brent@localhost)
	by terra.eng.sun.com (8.9.3+Sun/8.9.3) id JAA02667
	for nfsv4-wg@sunroof.eng.sun.com; Mon, 13 Mar 2000 09:23:37 -0800 (PST)
Date: Mon, 13 Mar 2000 09:23:37 -0800 (PST)
From: Brent Callaghan <Brent.Callaghan@eng.sun.com>
Message-Id: <200003131723.JAA02667@terra.eng.sun.com>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: NFSv4 WG agenda for 47th IETF ?
X-Sun-Charset: US-ASCII


This week I need to submit the agenda for the NFSv4 working group
meetings to be held at the 47th IETF meeting in Adelaide March 26th -
31st.  For info on the meeting, see:

	http://www.ietf.org/meetings/IETF-47.html

We have two sessions: Monday March 26th at 7:30 for 2 hours and
Tues afternoon at 5pm for 1 hour.

Whether or not you're planning on attending, I'd appreciate some ideas
on protocol topics that should be aired at this meeting. A transcript
of the meeting will be published in the meeting proceedings
( see http://www.ietf.org/proceedings/directory.html ).

If you are coming to the meeting and would like to make a short
presentation, then let me know what you want to talk about, and
how long you need to present it.

Otherwise, I'd appreciate some suggestions as to topics we need
to discuss further at the meeting.

	Thanks
		Brent


From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar 14 22:15:45 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id WAA22888
	for <nfsv4-archive@odin.ietf.org>; Tue, 14 Mar 2000 22:15:44 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id TAA00976;
	Tue, 14 Mar 2000 19:15:22 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id TAA02097;
	Tue, 14 Mar 2000 19:15:03 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2F3ENw10656
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 14 Mar 2000 19:14:23 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id TAA13731
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 14 Mar 2000 19:14:23 -0800 (PST)
Received: from note.orchestra.cse.unsw.EDU.AU (note.orchestra.cse.unsw.EDU.AU [129.94.242.29])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id UAA15268
	for <nfsv4-wg@sunroof.eng.sun.com>; Tue, 14 Mar 2000 20:14:00 -0700 (MST)
Received: From elephant With LocalMail ; Wed, 15 Mar 2000 14:10:41 +1100 
From: "Neil F. Brown" <neilb@cse.unsw.edu.au>
To: Hans Reiser <reiser@idiom.com>
Date: Wed, 15 Mar 2000 14:10:39 +1100 (EST)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Message-ID: <14542.65327.914162.656778@elephant.orchestra.cse.unsw.EDU.AU>
Cc: nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: reiserfs and knfsd and NFSv4 and volatile file handles 
In-Reply-To: message from Hans Reiser on Thursday March 2
References: <Pine.LNX.4.10.10003011505180.21646-100000@aviro.devel.redhat.com>
	<20000301231200.A4689@gruyere.muc.suse.de>
	<38BE9AC5.B293B2A2@idiom.com>
X-Mailer: VM 6.62 under Emacs 20.3.1
Content-Transfer-Encoding: 7bit

On Thursday March 2, Hans Reiser wrote to linux-kernel (and others) :
> Andi Kleen wrote:
> 
> > 
> > [NFSv4 has volatile file handles that require the client to store the
> > path and relookup when needed, but of course the
> > end result will be even farther away from POSIX semantics as current NFS
> > is already]
> 
> If I am correct in guessing what a volatile file handle is, it sounds like the
> right answer to me, that and changing the posix semantics.  What exactly is a
> volatile file handle?  Does it allow a file handle to go bad and then just
> relookup?  Is it an attempt to cure stale file handles?
> 

and later, Hans Reiser wrote:
> Currently having to find files by something other than a dentry or a filename
> (or a key) uglifies our design.  Even the use of a 64 bit number forces us to
> use fixed length keys which forces us to use hashing which by destroying sorting
> makes it impossible to use stem compression in our directories.  (This affects
> one of our web search engine sponsors who would like for 30 million entry
> directories to fit into RAM in our next major version of reiserfs.) If knfsd
> goes to using dentries to talk to reiserfs, we will be very happy.

I've Cc:ed this to the nfsv4 working group as well.

Maybe I can shed a bit of light.

knfsd cannot just used dentries (internal structures accessed by path
name) to talk to reiserfs as NFS requires it to use "file handles"
which have a maximum length.  To support NFSv2 or v3 you will need to
provide a way to map from a fix-size identifier to a file, that is
stable across rename, write, truncate, reboot.

The volatile filehandles of NFSv4 aim to get around this restriction,
and if you will (one day) be happy to only support NFSv4, not v2 or v3
(once the spec if finalised and the implementations are done and
clients are common...)  then you have more flexability in talking to
NFS.

The NFS client only *needs* a file handle to be stable while it has
the file open.  Having it stable while the client does not have the
file open is at best a convenience for caching.

NFSv4 allows the client to "open" and subsequently "close" a file -
abstractions that absent from NFSv2,3.

NFSv4 allows the server to assert that file handles are stable
(non-volatile, persistant) while a file is open, but that it will
provide no guarantees at other times.

This can work quite well for an MSDOS style filesystem which can use
filehandles based on the file name (E.g. disc address of directory
entry) and which disallows hard links, and disallows unlink or rename
while a file is open.

This should be able to be made to work fairly well for reiserfs too.

As I understand reiserfs (which isn't very deeply), it has an emphasis
on efficient support for lots of small files, and so likes to keep
meta-data and some or all of the data associated with a file in the
directory entry that references the file.
I can imaging that this would mean changing the size of the file,
renaming the file, or even adding files to the directory could all
change the physical location of the meta-data on disc, making it hard
to have a fixed-length, stable index to a file, as needed by NFSv2,3.

A simple minded approach to providing presistant-only-when-open
file handles for reiserfs might be to allocate sequential file handles
and to keep a cache of "filehandle to metadata-disc-address"
mappings. This cache would have to be kept up-to-date whenever a file's
metadata moved.
When a file was opened, the mapping would be marked as 'persistant'
and be logged to stable storage.  On the last close, the mapping could
have the presistant flag removed.

Then the cache could be regularly cleaned of non-persistant mappings,
in an LRU fashion, and any filehandle that is presented which is not
in the cache gets an "NFS4ERR_FHEXPIRED" response.

The logging to stable storage is required so that in the event of a
reboot, the server will still honour open file handles.

As this approach requires logging all opens to disc, it is very likely
to be a performance nightmare.

If we can assume that while the disc address of metadata can change,
it doesn't change very often, then a suitable alternative might be:

- Store a uniquifier in the metadata for each file - an essentally
  random 32-64 bit number.
- Make file handles out of disc-address+uniquifier.
- When an open file has the disc address of its metadata changed, cache
  the old filehandle and the new address both in memory and on stable
  storage.

Then, when a file handle is received, first check the cache.  If it
isn't there, check to see if valid metadata exists at the disc address
and has the given uniquifier.  If it doesn't only then give a
NFS4ERR_FHEXPIRED.

On reboot, you would need to prime the cache from the stable-storage
log.

This should provide the client with the stability it needs, and not
incur too much performance overhead (or does the address of metadata
change a lot?)

I would like the server to be able to tell the client that a
filehandle needs to be updated, and for the client to be able to ask
for an updated copy of a given filehandle - so that entries in the
old-to-new cache could be discarded even while a file was still open,
but that proposal wasn't accepted (yet).

NeilBrown


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 15 08:23:39 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id IAA16543
	for <nfsv4-archive@odin.ietf.org>; Wed, 15 Mar 2000 08:23:39 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id FAA21893;
	Wed, 15 Mar 2000 05:22:02 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id FAA10097;
	Wed, 15 Mar 2000 05:21:56 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2FDLgw10849
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 05:21:42 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id FAA02018
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 05:21:40 -0800 (PST)
Received: from Cantor.suse.de (Cantor.suse.de [194.112.123.193])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id GAA25968
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 06:21:39 -0700 (MST)
Received: from Hermes.suse.de (Hermes.suse.de [194.112.123.136])
	by Cantor.suse.de (Postfix) with ESMTP
	id 403FA1E0DB; Wed, 15 Mar 2000 14:21:37 +0100 (MET)
Received: from gruyere.muc.suse.de (gruyere.muc.suse.de [10.23.1.2])
	by Hermes.suse.de (Postfix) with ESMTP
	id AE92D10A035; Wed, 15 Mar 2000 14:21:35 +0100 (MET)
Received: by gruyere.muc.suse.de (Postfix, from userid 14446)
	id 0CA932F36B; Wed, 15 Mar 2000 14:21:30 +0100 (MET)
Date: Wed, 15 Mar 2000 14:21:30 +0100
From: "Andi Kleen" <ak@suse.de>
To: "Neil F. Brown" <neilb@cse.unsw.edu.au>
Cc: Hans Reiser <reiser@idiom.com>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
Message-ID: <20000315142130.A2422@gruyere.muc.suse.de>
References: <Pine.LNX.4.10.10003011505180.21646-100000@aviro.devel.redhat.com> <20000301231200.A4689@gruyere.muc.suse.de> <38BE9AC5.B293B2A2@idiom.com> <14542.65327.914162.656778@elephant.orchestra.cse.unsw.EDU.AU>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 1.0i
In-Reply-To: <14542.65327.914162.656778@elephant.orchestra.cse.unsw.EDU.AU>; from neilb@cse.unsw.edu.au on Wed, Mar 15, 2000 at 02:10:39PM +1100
Sender: ak@suse.de

On Wed, Mar 15, 2000 at 02:10:39PM +1100, Neil F. Brown wrote:
> 
> As I understand reiserfs (which isn't very deeply), it has an emphasis
> on efficient support for lots of small files, and so likes to keep
> meta-data and some or all of the data associated with a file in the
> directory entry that references the file.
> I can imaging that this would mean changing the size of the file,
> renaming the file, or even adding files to the directory could all
> change the physical location of the meta-data on disc, making it hard
> to have a fixed-length, stable index to a file, as needed by NFSv2,3.

Reiserfs has a stable index to a file. It is currently 64bit (32 bit object
ID + ID of the directory). Hans apparently plans to go for longer variable
size keys in the future, although that may not work out given the NFS
limitations. If the 32bit directory key is not available searching the
file is very expensive.


-Andi


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 15 23:30:16 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id XAA12872
	for <nfsv4-archive@odin.ietf.org>; Wed, 15 Mar 2000 23:30:14 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA08013;
	Wed, 15 Mar 2000 20:29:40 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA29350;
	Wed, 15 Mar 2000 20:29:30 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2G4T1w11787
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:29:07 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA10773
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:28:28 -0800 (PST)
Received: from web3705.mail.yahoo.com (web3705.mail.yahoo.com [204.71.203.134])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id UAA10546
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:28:12 -0800 (PST)
Message-ID: <20000316042812.25173.qmail@web3705.mail.yahoo.com>
Received: from [202.54.64.130] by web3705.mail.yahoo.com; Thu, 16 Mar 2000 04:28:12 GMT
Date: Thu, 16 Mar 2000 04:28:12 +0000 (GMT)
From: =?iso-8859-1?q?kvs=20sivak?= <kvs_sivak@yahoo.co.uk>
Subject: clarification on OPEN delegation
To: nfsv4-wg@sunroof.eng.sun.com
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
Content-Transfer-Encoding: 8bit

hi,
a clarification as to how initially a delegation gets
granted to a client

NFS v4 draft 3: 

section 9.4 reads 

   When an open delegation is 

requested and granted,  : is a request made by client
?

 the response to the
   OPEN contains an open delegation structure which
specifies the
   following:

   o    the type of delegation (read or write)

   o    space limitation information to control
flushing of data on
        close (write open delegation only, see the
section "Open
        Delegation and Data Caching")

   o    an nfsace4 specifying read and write
permissions

   o    a stateid to represent the delegation for READ
and WRITE


draft 6  
the corresponding section reads :

 When an open delegation is 

          made,     : made arbitrarily by the server ?

the response to the OPEN contains an
   open delegation structure which specifies the
following:

   o    the type of delegation (read or write)

   o    space limitation information to control
flushing of data on
        close (write open delegation only, see the
section "Open
        Delegation and Data Caching")

   o    an nfsace4 specifying read and write
permissions

   o    a stateid to represent the delegation for READ
and WRITE  

Is the granting of a delegation done only when a
client requests one Or is it done by the server
whenever possible so that the client MUST support
delegation handling ?
if a client can request delegation where is the
request made to the server (which RPC operation !)
how ?

kvs_sivak


____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 15 23:33:07 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id XAA14201
	for <nfsv4-archive@odin.ietf.org>; Wed, 15 Mar 2000 23:33:07 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA08593;
	Wed, 15 Mar 2000 20:32:40 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA11217;
	Wed, 15 Mar 2000 20:32:32 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2G4WMw11792
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:32:23 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id UAA29583
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:32:22 -0800 (PST)
Received: from idiom.com (idiom.com [216.240.32.1])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id UAA11788
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 20:32:21 -0800 (PST)
Received: from idiom.com (reiser.dial.idiom.com [216.240.37.24])
	by idiom.com (8.9.3/8.9.3) with ESMTP id UAA30338;
	Wed, 15 Mar 2000 20:31:53 -0800 (PST)
Sender: root@idiom.com
Message-ID: <38CFCAC0.D71EA60B@idiom.com>
Date: Wed, 15 Mar 2000 20:39:12 +0300
From: Hans Reiser <reiser@idiom.com>
Reply-To: hans@reiser.to
Organization: Namesys
X-Mailer: Mozilla 4.7 [en] (X11; I; Linux 2.2.13 i686)
X-Accept-Language: en, ru
MIME-Version: 1.0
To: "Neil F. Brown" <neilb@cse.unsw.edu.au>
CC: nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: reiserfs and knfsd and NFSv4 and volatile file handles
References: <Pine.LNX.4.10.10003011505180.21646-100000@aviro.devel.redhat.com>
		<20000301231200.A4689@gruyere.muc.suse.de>
		<38BE9AC5.B293B2A2@idiom.com> <14542.65327.914162.656778@elephant.orchestra.cse.unsw.EDU.AU>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

"Neil F. Brown" wrote:
> 
> On Thursday March 2, Hans Reiser wrote to linux-kernel (and others) :
> > Andi Kleen wrote:
> >
> > >
> > > [NFSv4 has volatile file handles that require the client to store the
> > > path and relookup when needed, but of course the
> > > end result will be even farther away from POSIX semantics as current NFS
> > > is already]
> >
> > If I am correct in guessing what a volatile file handle is, it sounds like the
> > right answer to me, that and changing the posix semantics.  What exactly is a
> > volatile file handle?  Does it allow a file handle to go bad and then just
> > relookup?  Is it an attempt to cure stale file handles?
> >
> 
> and later, Hans Reiser wrote:
> > Currently having to find files by something other than a dentry or a filename
> > (or a key) uglifies our design.  Even the use of a 64 bit number forces us to
> > use fixed length keys which forces us to use hashing which by destroying sorting
> > makes it impossible to use stem compression in our directories.  (This affects
> > one of our web search engine sponsors who would like for 30 million entry
> > directories to fit into RAM in our next major version of reiserfs.) If knfsd
> > goes to using dentries to talk to reiserfs, we will be very happy.
> 
> I've Cc:ed this to the nfsv4 working group as well.
> 
> Maybe I can shed a bit of light.
> 
> knfsd cannot just used dentries (internal structures accessed by path
> name) to talk to reiserfs as NFS requires it to use "file handles"
> which have a maximum length.  To support NFSv2 or v3 you will need to
> provide a way to map from a fix-size identifier to a file, that is
> stable across rename, write, truncate, reboot.
> 
> The volatile filehandles of NFSv4 aim to get around this restriction,
> and if you will (one day) be happy to only support NFSv4, not v2 or v3
> (once the spec if finalised and the implementations are done and
> clients are common...)  then you have more flexability in talking to
> NFS.
> 
> The NFS client only *needs* a file handle to be stable while it has
> the file open.  Having it stable while the client does not have the
> file open is at best a convenience for caching.
> 
> NFSv4 allows the client to "open" and subsequently "close" a file -
> abstractions that absent from NFSv2,3.
> 
> NFSv4 allows the server to assert that file handles are stable
> (non-volatile, persistant) while a file is open, but that it will
> provide no guarantees at other times.
> 
> This can work quite well for an MSDOS style filesystem which can use
> filehandles based on the file name (E.g. disc address of directory
> entry) and which disallows hard links, and disallows unlink or rename
> while a file is open.
> 
> This should be able to be made to work fairly well for reiserfs too.
> 
> As I understand reiserfs (which isn't very deeply), it has an emphasis
> on efficient support for lots of small files,

Yes

> and so likes to keep
> meta-data and some or all of the data associated with a file in the
> directory entry that references the file.
>
Not true at the moment, and not the issue.  The issue is that we don't have
on-disk inodes and we don't have inode numbers.  This means that we don't have
fixed allocations of space for inodes, and we can't do lookups by 32bit numbers
for files.

We do have keys, but these are currently 16 bytes and soon will be of variable
length.

Currently we hash filenames as part of constructing keys of fixed length, but
this is ugly and mostly motivated by NFS.

It hurts our performance, and makes directories difficult to compress since stem
compression doesn't work on randomly ordered entries.  Directory entries are
ordered by the hash of the filename currently.  This is bad for performance for
directories too big to fit into RAM, or even moderately large ones.

 I can imaging that this would mean changing the size of the file,
> renaming the file, or even adding files to the directory could all
> change the physical location of the meta-data on disc, making it hard
> to have a fixed-length, stable index to a file, as needed by NFSv2,3.
> 
> A simple minded approach to providing presistant-only-when-open
> file handles for reiserfs might be to allocate sequential file handles
> and to keep a cache of "filehandle to metadata-disc-address"
> mappings. This cache would have to be kept up-to-date whenever a file's
> metadata moved.
> When a file was opened, the mapping would be marked as 'persistant'
> and be logged to stable storage.  On the last close, the mapping could
> have the presistant flag removed.
> 
> Then the cache could be regularly cleaned of non-persistant mappings,
> in an LRU fashion, and any filehandle that is presented which is not
> in the cache gets an "NFS4ERR_FHEXPIRED" response.
> 
> The logging to stable storage is required so that in the event of a
> reboot, the server will still honour open file handles.
> 
> As this approach requires logging all opens to disc, it is very likely
> to be a performance nightmare.
> 
> If we can assume that while the disc address of metadata can change,
> it doesn't change very often, then a suitable alternative might be:
> 
> - Store a uniquifier in the metadata for each file - an essentally
>   random 32-64 bit number.
> - Make file handles out of disc-address+uniquifier.
> - When an open file has the disc address of its metadata changed, cache
>   the old filehandle and the new address both in memory and on stable
>   storage.
> 
> Then, when a file handle is received, first check the cache.  If it
> isn't there, check to see if valid metadata exists at the disc address
> and has the given uniquifier.  If it doesn't only then give a
> NFS4ERR_FHEXPIRED.
> 
> On reboot, you would need to prime the cache from the stable-storage
> log.
> 
> This should provide the client with the stability it needs, and not
> incur too much performance overhead (or does the address of metadata
> change a lot?)
> 
> I would like the server to be able to tell the client that a
> filehandle needs to be updated, and for the client to be able to ask

This would definitely be a cleaner architecture that would allow repackers to
not disrupt NFS if they change the key.  We have a repacker in progress.  I can
easily imagine your getting lots of NFS troubles every time the repacker changes
things without having a way to tell NFS that it was changed.

> for an updated copy of a given filehandle - so that entries in the
> old-to-new cache could be discarded even while a file was still open,
> but that proposal wasn't accepted (yet).
> 
> NeilBrown
> 

Thanks much Neil.
> -
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.rutgers.edu
> Please read the FAQ at http://www.tux.org/lkml/

-- 
You can get ReiserFS at http://devlinux.org/namesys, and customizations and
industrial grade support at reiser@idiom.com.


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 01:41:16 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id BAA04023
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 01:41:11 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id WAA28514;
	Wed, 15 Mar 2000 22:40:48 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id WAA08132;
	Wed, 15 Mar 2000 22:40:42 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2G6eLw11835
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 22:40:22 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id WAA16317
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 22:40:19 -0800 (PST)
Received: from math.psu.edu (leibniz.math.psu.edu [146.186.130.2])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id WAA19210
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 22:40:15 -0800 (PST)
Received: from weyl.math.psu.edu (weyl.math.psu.edu [146.186.130.226])
	by math.psu.edu (8.9.3/8.9.3) with ESMTP id BAA29805;
	Thu, 16 Mar 2000 01:40:04 -0500 (EST)
Received: from localhost (viro@localhost)
	by weyl.math.psu.edu (8.9.3/8.9.3) with ESMTP id BAA03433;
	Thu, 16 Mar 2000 01:40:04 -0500 (EST)
X-Authentication-Warning: weyl.math.psu.edu: viro owned process doing -bs
Date: Thu, 16 Mar 2000 01:40:04 -0500 (EST)
From: Alexander Viro <viro@math.psu.edu>
To: Andi Kleen <ak@suse.de>
cc: "Neil F. Brown" <neilb@cse.unsw.edu.au>, Hans Reiser <reiser@idiom.com>,
        nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
In-Reply-To: <20000315142130.A2422@gruyere.muc.suse.de>
Message-ID: <Pine.GSO.4.10.10003160114290.13531-100000@weyl.math.psu.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII



On Wed, 15 Mar 2000, Andi Kleen wrote:

> On Wed, Mar 15, 2000 at 02:10:39PM +1100, Neil F. Brown wrote:
> > 
> > As I understand reiserfs (which isn't very deeply), it has an emphasis
> > on efficient support for lots of small files, and so likes to keep
> > meta-data and some or all of the data associated with a file in the
> > directory entry that references the file.
> > I can imaging that this would mean changing the size of the file,
> > renaming the file, or even adding files to the directory could all
> > change the physical location of the meta-data on disc, making it hard
> > to have a fixed-length, stable index to a file, as needed by NFSv2,3.
> 
> Reiserfs has a stable index to a file. It is currently 64bit (32 bit object
> ID + ID of the directory). Hans apparently plans to go for longer variable

Eh? Parse the last part of it, please. How the heck can it be stable upon
rename()? And how does it work with fs/reiserfs/namei.c::reiserfs_link()? 

If you mean that we need ID of parent for knfsd - see our discussion on
that stuff. VFS doesn't need to know parents of non-directories.

Let me ask again:
	a) is your "32 bit object ID" sufficient to
read/write/chmod/truncate/chown the file? Forget VFS, does the thing
contain enough information to do it in principle (aside of scanning the
whole tree, indeed)?
	b) if you have a directory, is its "32 bit object ID" sufficient to
find ID of its parent?
	c) <<---------------------------------------------------------->> to
find the entry of subdirectory with given ID?

If answer to all of those is positive - wonderful. If not - we got a
problem. If you can do it with s/32 bit/64 bit/ - not a big deal, provided
that ID is stable over rename() and depends only on file (== doesn't
depend on which link you are looking at). If you really need to know
parent to perform operations on opened file - you are _deep_ in trouble.

I assume that you _do_ support link(2) - if you don't I would really like
to know what reiserfs_link() does. As in: why it is there and what will
actually happen if you'll start calling it.
								Al



From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 02:18:34 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id CAA25596
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 02:18:34 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id XAA04074;
	Wed, 15 Mar 2000 23:18:16 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id XAA27796;
	Wed, 15 Mar 2000 23:18:08 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2G7Hrw11893
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 23:17:54 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id XAA18905
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 15 Mar 2000 23:17:53 -0800 (PST)
Received: from idiom.com (idiom.com [216.240.32.1])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id AAA28469
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 00:17:54 -0700 (MST)
Received: from idiom.com (reiser.dial.idiom.com [216.240.37.24])
	by idiom.com (8.9.3/8.9.3) with ESMTP id XAA65783;
	Wed, 15 Mar 2000 23:17:30 -0800 (PST)
Sender: root@idiom.com
Message-ID: <38CFF191.DAC18150@idiom.com>
Date: Wed, 15 Mar 2000 23:24:49 +0300
From: Hans Reiser <reiser@idiom.com>
Reply-To: hans@reiser.to
Organization: Namesys
X-Mailer: Mozilla 4.7 [en] (X11; I; Linux 2.2.13 i686)
X-Accept-Language: en, ru
MIME-Version: 1.0
To: Alexander Viro <viro@math.psu.edu>
CC: Andi Kleen <ak@suse.de>, "Neil F. Brown" <neilb@cse.unsw.edu.au>,
        nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
References: <Pine.GSO.4.10.10003160114290.13531-100000@weyl.math.psu.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

Alexander Viro wrote:
> 
> On Wed, 15 Mar 2000, Andi Kleen wrote:
> 
> > On Wed, Mar 15, 2000 at 02:10:39PM +1100, Neil F. Brown wrote:
> > >
> > > As I understand reiserfs (which isn't very deeply), it has an emphasis
> > > on efficient support for lots of small files, and so likes to keep
> > > meta-data and some or all of the data associated with a file in the
> > > directory entry that references the file.
> > > I can imaging that this would mean changing the size of the file,
> > > renaming the file, or even adding files to the directory could all
> > > change the physical location of the meta-data on disc, making it hard
> > > to have a fixed-length, stable index to a file, as needed by NFSv2,3.
> >
> > Reiserfs has a stable index to a file. It is currently 64bit (32 bit object
> > ID + ID of the directory). Hans apparently plans to go for longer variable
> 
> Eh? Parse the last part of it, please. How the heck can it be stable upon
> rename()? And how does it work with fs/reiserfs/namei.c::reiserfs_link()?

Not sure I understand your question, but I'll take a stab at it.  Currently the
first directory a file is created in stays its packing locality parent for the
life of the file.  The packing locality parent is the first key component.  So,
currently, if you know the parent directory id the file was created in you know
the first component of the key, and the last component of the key is the offset
which you can also know.  This leaves the middle of the key unknown.  

The immutability of keys is true merely because we don't yet have a repacker to
do re-optimize once a day, and it will change, but for now it is true.  The
first version of our repacker probably won't change keys, but clearly it should
eventually have that functionality.

The notion that keys/objectids should be immutable over the life of the object
is a notion I once believed in but have since conceded was wrong of me.

So, if you create a file in one directory and then access from another
directory, we are as inefficient as using conventional inodes.  At least until
the repacker that has not yet been authored gets written by us....
 
> 
> If you mean that we need ID of parent for knfsd - see our discussion on
> that stuff. VFS doesn't need to know parents of non-directories.
> 
> Let me ask again:
>         a) is your "32 bit object ID" sufficient to
> read/write/chmod/truncate/chown the file? Forget VFS, does the thing
> contain enough information to do it in principle (aside of scanning the
> whole tree, indeed)?
No, we need the directory id plus the objectid (plus the offset) to know what
the key is.
>         b) if you have a directory, is its "32 bit object ID" sufficient to
> find ID of its parent?

directories are their own parents as far as constructing keys is concerned in
plan A which is our next version, key construction for the current version puts
directories in the parent of the directory which is an ~10% performance losing
notion of a former project member, sigh.  If 2.4 had been another month or two
out we would have fixed it, such is life....  it will wait for 2.6.

>         c) <<---------------------------------------------------------->> to
> find the entry of subdirectory with given ID?
> 
> If answer to all of those is positive - wonderful. If not - we got a
> problem. If you can do it with s/32 bit/64 bit/ - not a big deal, provided
> that ID is stable over rename() and depends only on file (== doesn't
> depend on which link you are looking at). If you really need to know
> parent to perform operations on opened file - you are _deep_ in trouble.

If you know the parent it was created in you know the first 32 bits and only
need to know another 32 (plus the offset in the file).  Otherwise you need 64
bits plus the offset.  Note that we already have potential sponsors saying that
4 billion files isn't enough, and that they need more bits for objectids.

> 
> I assume that you _do_ support link(2) - if you don't I would really like
> to know what reiserfs_link() does. As in: why it is there and what will
> actually happen if you'll start calling it.

link works.:-)  I think I explained the difficult part above, if you need more
detail ask.

>                                                                 Al

Hans
-- 
You can get ReiserFS at http://devlinux.org/namesys, and customizations and
industrial grade support at reiser@idiom.com.


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 03:11:06 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id DAA17093
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 03:10:57 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id AAA13472;
	Thu, 16 Mar 2000 00:10:29 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id AAA14234;
	Thu, 16 Mar 2000 00:10:23 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2G8A6w11903
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 00:10:06 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id AAA14223
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 00:10:08 -0800 (PST)
Received: from math.psu.edu (leibniz.math.psu.edu [146.186.130.2])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id BAA13850
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 01:10:06 -0700 (MST)
Received: from weyl.math.psu.edu (weyl.math.psu.edu [146.186.130.226])
	by math.psu.edu (8.9.3/8.9.3) with ESMTP id DAA09564;
	Thu, 16 Mar 2000 03:10:02 -0500 (EST)
Received: from localhost (viro@localhost)
	by weyl.math.psu.edu (8.9.3/8.9.3) with ESMTP id DAA03573;
	Thu, 16 Mar 2000 03:10:02 -0500 (EST)
X-Authentication-Warning: weyl.math.psu.edu: viro owned process doing -bs
Date: Thu, 16 Mar 2000 03:10:01 -0500 (EST)
From: Alexander Viro <viro@math.psu.edu>
To: hans@reiser.to
cc: Andi Kleen <ak@suse.de>, "Neil F. Brown" <neilb@cse.unsw.edu.au>,
        nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
In-Reply-To: <38CFF191.DAC18150@idiom.com>
Message-ID: <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII



On Wed, 15 Mar 2000, Hans Reiser wrote:

> Not sure I understand your question, but I'll take a stab at it.  Currently the
> first directory a file is created in stays its packing locality parent for the
> life of the file.  The packing locality parent is the first key component.  So,
> currently, if you know the parent directory id the file was created in you know
> the first component of the key, and the last component of the key is the offset
> which you can also know.  This leaves the middle of the key unknown.  

Ouch. What happens if you
	mkdir foo
	create foo/bar
	rename foo/bar baz/bar
	rmdir foo
and ditto for
	mkdir foo
	create foo/bar
	open foo/bar
	unlink foo/bar
	rmdir foo
- where does your packing locality <whatever> go?

Another question: how does your write_inode() interact with readdir() and
friends on parent? Do they need any sort of exclusion? What kind of
metadata is stored in the directory and is it affected by notify_change()?

One more: suppose you've got
	create foo/bar
	link foo/bar baz/bar
	unlink foo/bar
	create foo/quux		unlink baz/bar
Do the last two of them need any sort of exclusion? VFS _does_ allow the
last two happen at the same time. You have big lock, but if one of them
blocks (and you are very unlikely to avoid that) - that's it.

The reason why I'm asking is that I've done a filesystem with metadata in
directory and I know what kind of PITA it can become. _And_ I've dealt
with a monster that keeps metadata in directory trying to support links.
In case if you wonder - it's AFFS. It's racey as hell and basically I'm
trying to figure out how did you solve the same set of problems. 

> The immutability of keys is true merely because we don't yet have a repacker to
> do re-optimize once a day, and it will change, but for now it is true.  The
> first version of our repacker probably won't change keys, but clearly it should
> eventually have that functionality.

And how do you expect NFS to handle that?

> The notion that keys/objectids should be immutable over the life of the object
> is a notion I once believed in but have since conceded was wrong of me.

	Unfortunately, NFS can't survive without that. POSIX also requires
constant inumbers, BTW.

> So, if you create a file in one directory and then access from another
> directory, we are as inefficient as using conventional inodes.  At least until
> the repacker that has not yet been authored gets written by us....
>  
> > 
> > If you mean that we need ID of parent for knfsd - see our discussion on
> > that stuff. VFS doesn't need to know parents of non-directories.
> > 
> > Let me ask again:
> >         a) is your "32 bit object ID" sufficient to
> > read/write/chmod/truncate/chown the file? Forget VFS, does the thing
> > contain enough information to do it in principle (aside of scanning the
> > whole tree, indeed)?
> No, we need the directory id plus the objectid (plus the offset) to know what
> the key is.

What's the size of key?

> >         b) if you have a directory, is its "32 bit object ID" sufficient to
> > find ID of its parent?
> 
> directories are their own parents as far as constructing keys is concerned in
> plan A which is our next version, key construction for the current version puts
> directories in the parent of the directory which is an ~10% performance losing
> notion of a former project member, sigh.  If 2.4 had been another month or two
> out we would have fixed it, such is life....  it will wait for 2.6.

Wait a minute. Assume that somebody gave you the key of directory. Can you
find the key of its current parent? Notice that it could very well be
renamed since the moment of its cretion.

> > I assume that you _do_ support link(2) - if you don't I would really like
> > to know what reiserfs_link() does. As in: why it is there and what will
> > actually happen if you'll start calling it.
> 
> link works.:-)  I think I explained the difficult part above, if you need more
> detail ask.

Erm... I need details on the locking you use within your tree. This scheme 
has a huge potential for hidden (and hard to hit unless you know what you
are hunting for) races, unless you are very accurate with that stuff. One
more thing that began to scare me - readdir() and offsets in directory.
How do you do them?
								Al



From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 06:03:40 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id GAA11480
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 06:03:39 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id DAA00797;
	Thu, 16 Mar 2000 03:03:13 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA27639;
	Thu, 16 Mar 2000 03:03:05 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2GB2ow11994
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 03:02:50 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA12909
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 03:02:48 -0800 (PST)
Received: from Cantor.suse.de (Cantor.suse.de [194.112.123.193])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id EAA11208
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 04:02:47 -0700 (MST)
Received: from Hermes.suse.de (Hermes.suse.de [194.112.123.136])
	by Cantor.suse.de (Postfix) with ESMTP
	id 74B731E1BB; Thu, 16 Mar 2000 12:02:46 +0100 (MET)
Received: from gruyere.muc.suse.de (gruyere.muc.suse.de [10.23.1.2])
	by Hermes.suse.de (Postfix) with ESMTP
	id 862D010A02C; Thu, 16 Mar 2000 12:02:44 +0100 (MET)
Received: by gruyere.muc.suse.de (Postfix, from userid 14446)
	id 5EF342F375; Thu, 16 Mar 2000 12:02:39 +0100 (MET)
Date: Thu, 16 Mar 2000 12:02:39 +0100
From: "Andi Kleen" <ak@suse.de>
To: Alexander Viro <viro@math.psu.edu>
Cc: hans@reiser.to, Andi Kleen <ak@suse.de>,
        "Neil F. Brown" <neilb@cse.unsw.edu.au>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
Message-ID: <20000316120239.A18464@gruyere.muc.suse.de>
References: <38CFF191.DAC18150@idiom.com> <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 1.0i
In-Reply-To: <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu>; from viro@math.psu.edu on Thu, Mar 16, 2000 at 03:10:01AM -0500
Sender: ak@suse.de

On Thu, Mar 16, 2000 at 03:10:01AM -0500, Alexander Viro wrote:
> 
> 
> On Wed, 15 Mar 2000, Hans Reiser wrote:
> 
> > Not sure I understand your question, but I'll take a stab at it.  Currently the
> > first directory a file is created in stays its packing locality parent for the
> > life of the file.  The packing locality parent is the first key component.  So,
> > currently, if you know the parent directory id the file was created in you know
> > the first component of the key, and the last component of the key is the offset
> > which you can also know.  This leaves the middle of the key unknown.  
> 
> Ouch. What happens if you
> 	mkdir foo
> 	create foo/bar
> 	rename foo/bar baz/bar
> 	rmdir foo
> and ditto for
> 	mkdir foo
> 	create foo/bar
> 	open foo/bar
> 	unlink foo/bar
> 	rmdir foo
> - where does your packing locality <whatever> go?

The packing locality is saved in each directory entry and in the 
in core inode.

> 
> Another question: how does your write_inode() interact with readdir() and
> friends on parent? Do they need any sort of exclusion? What kind of
> metadata is stored in the directory and is it affected by notify_change()?

No metadata in directories (there are comments in the code that say
that they plan to change that in the future, but I have my doubts
if it is really a good idea) 


> 
> One more: suppose you've got
> 	create foo/bar
> 	link foo/bar baz/bar
> 	unlink foo/bar
> 	create foo/quux		unlink baz/bar
> Do the last two of them need any sort of exclusion? VFS _does_ allow the
> last two happen at the same time. You have big lock, but if one of them
> blocks (and you are very unlikely to avoid that) - that's it.
> 
> The reason why I'm asking is that I've done a filesystem with metadata in
> directory and I know what kind of PITA it can become. _And_ I've dealt
> with a monster that keeps metadata in directory trying to support links.
> In case if you wonder - it's AFFS. It's racey as hell and basically I'm
> trying to figure out how did you solve the same set of problems. 

reiserfs does not have metadata in directories. The directories are just
like ordinary unix directories being basically a special kind of file with
points to other objects in the tree.


> > The immutability of keys is true merely because we don't yet have a repacker to
> > do re-optimize once a day, and it will change, but for now it is true.  The
> > first version of our repacker probably won't change keys, but clearly it should
> > eventually have that functionality.
> 
> And how do you expect NFS to handle that?

He can't. Unix also cannot handle changing inodes (objectids in reiserfs speak).
Oh well, not all future plans work out.

> > > 
> > > Let me ask again:
> > >         a) is your "32 bit object ID" sufficient to
> > > read/write/chmod/truncate/chown the file? Forget VFS, does the thing
> > > contain enough information to do it in principle (aside of scanning the
> > > whole tree, indeed)?
> > No, we need the directory id plus the objectid (plus the offset) to know what
> > the key is.
> 
> What's the size of key?

Currently 12 bytes (packing locality, object id, offset). Offset is fixed
if you just want to find a file (and implicit in NFS anyways). It is also
fixed if you want to e.g. find the .. of a directory.  So the NFS 
fh needs to store 8 byte.


> 
> > >         b) if you have a directory, is its "32 bit object ID" sufficient to
> > > find ID of its parent?
> > 
> > directories are their own parents as far as constructing keys is concerned in
> > plan A which is our next version, key construction for the current version puts
> > directories in the parent of the directory which is an ~10% performance losing
> > notion of a former project member, sigh.  If 2.4 had been another month or two
> > out we would have fixed it, such is life....  it will wait for 2.6.
> 
> Wait a minute. Assume that somebody gave you the key of directory. Can you
> find the key of its current parent? Notice that it could very well be
> renamed since the moment of its cretion.

Sure. Just look for (parent, directoryid, DOT_DOT_OFFSET) and read the 
full parent key from the directory entry.  It is really like Unix in
this regard.


> 
> > > I assume that you _do_ support link(2) - if you don't I would really like
> > > to know what reiserfs_link() does. As in: why it is there and what will
> > > actually happen if you'll start calling it.
> > 
> > link works.:-)  I think I explained the difficult part above, if you need more
> > detail ask.
> 
> Erm... I need details on the locking you use within your tree. This scheme 
> has a huge potential for hidden (and hard to hit unless you know what you
> are hunting for) races, unless you are very accurate with that stuff. One
> more thing that began to scare me - readdir() and offsets in directory.
> How do you do them?

That is what they use all the ugly "has rescheduled" flags for. The entry
also has a "recently deleted" flag that is checked (hidden). When the tree
is rebalanced inbetween they catch that with a relookup (because offset
stays a fixed position). When you insert new entries before the current
filldir offset inbetween you lose (but standard ext2 is no better in that
as far as I can see). In the 2.3 version they use generation counts for
most things, so they can more easily find out if a object changed.
As far as I can see the reiserfs readdir handles all races the ext2
readdir handles.

[Note that I'm no reiserfs hacker, that just came from my own reading
of the source. Maybe it is better you apply the patch and do some
real RTFS ;]

-Andi 

P.S.: The loopback device in 2.3.51 seems to be still very unstable
when accessing block devices.  I get weird hangs all the time. It 
looks like it is leaking some important inode semaphore or similar, 
because all new processes hang and then the remaining processes
start to block one after another as they try to do file system
accesses.


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 06:09:34 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id GAA13303
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 06:09:33 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id DAA02339;
	Thu, 16 Mar 2000 03:09:07 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA24346;
	Thu, 16 Mar 2000 03:09:01 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2GB8qw12034
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 03:08:52 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA17699
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 03:08:51 -0800 (PST)
Received: from Cantor.suse.de (Cantor.suse.de [194.112.123.193])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id EAA13527
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 04:08:50 -0700 (MST)
Received: from Hermes.suse.de (Hermes.suse.de [194.112.123.136])
	by Cantor.suse.de (Postfix) with ESMTP
	id C66191E1BE; Thu, 16 Mar 2000 12:08:49 +0100 (MET)
Received: from gruyere.muc.suse.de (gruyere.muc.suse.de [10.23.1.2])
	by Hermes.suse.de (Postfix) with ESMTP
	id B37AF10A053; Thu, 16 Mar 2000 12:08:47 +0100 (MET)
Received: by gruyere.muc.suse.de (Postfix, from userid 14446)
	id 2BCD42F36C; Thu, 16 Mar 2000 12:08:43 +0100 (MET)
Date: Thu, 16 Mar 2000 12:08:43 +0100
From: "Andi Kleen" <ak@suse.de>
To: "Andi Kleen" <ak@suse.de>
Cc: Alexander Viro <viro@math.psu.edu>, hans@reiser.to,
        "Neil F. Brown" <neilb@cse.unsw.edu.au>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com
Subject: Re: (reiserfs) Re: reiserfs and knfsd and NFSv4 and volatile file handles
Message-ID: <20000316120843.A19360@gruyere.muc.suse.de>
References: <38CFF191.DAC18150@idiom.com> <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu> <20000316120239.A18464@gruyere.muc.suse.de>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 1.0i
In-Reply-To: <20000316120239.A18464@gruyere.muc.suse.de>; from ak@suse.de on Thu, Mar 16, 2000 at 12:02:39PM +0100
Sender: ak@suse.de

On Thu, Mar 16, 2000 at 12:02:39PM +0100, Andi Kleen wrote:
> Currently 12 bytes (packing locality, object id, offset). Offset is fixed
            ^^
This should be 16 bytes in the 2.3 version, because offset is 64bit.
2.2 has 12 bytes.


-Andi


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 10:53:35 2000
Received: from mercury.Sun.COM (mercury.Sun.COM [192.9.25.1])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA22493
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 10:53:30 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA05237;
	Thu, 16 Mar 2000 07:52:06 -0800 (PST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA07033;
	Thu, 16 Mar 2000 07:45:19 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2GFj3w12419
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 07:45:03 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA10680
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 07:45:03 -0800 (PST)
Received: from mx01-ext.netapp.com (mx01-ext.netapp.com [198.95.224.34])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id HAA07592
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 07:45:00 -0800 (PST)
Received: (qmail 28572 invoked from network); 16 Mar 2000 15:52:48 -0000
Received: from herra.netapp.com (HELO herra.corp.netapp.com) (198.95.224.184)
  by mx01-ext.netapp.com with SMTP; 16 Mar 2000 15:52:48 -0000
Received: from tahoe.corp.netapp.com (tahoe.netapp.com [10.10.10.112])
	by herra.corp.netapp.com (8.9.3/8.9.3/NTAP-1.0) with ESMTP id HAA25720;
	Thu, 16 Mar 2000 07:44:51 -0800 (PST)
Received: by tahoe.corp.netapp.com with Internet Mail Service (5.5.2650.21)
	id <F56QFCFX>; Thu, 16 Mar 2000 07:44:51 -0800
Message-ID: <F6C5585BF0CED311B58D009027C2299C47C020@tahoe.corp.netapp.com>
From: "Noveck, Dave" <dave.noveck@netapp.com>
To: "'kvs sivak'" <kvs_sivak@yahoo.co.uk>, nfsv4-wg@sunroof.eng.sun.com
Subject: RE: clarification on OPEN delegation
Date: Thu, 16 Mar 2000 07:44:48 -0800
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2650.21)
Content-Type: text/plain;
	charset="iso-8859-1"

 
> hi,
> a clarification as to how initially a delegation gets
> granted to a client
> 
> NFS v4 draft 3: 
> 
> section 9.4 reads 
> 
>    When an open delegation is 
> 
> requested and granted,  : is a request made by client
> ?

This text in draft 3, was left over from an earlier 
proposal in which the client did indeed have to 
specifically request the delegation as part of the
OPEN operation.
 
> 
>  the response to the
>    OPEN contains an open delegation structure which
> specifies the
>    following:
> 
>    o    the type of delegation (read or write)
> 
>    o    space limitation information to control
> flushing of data on
>         close (write open delegation only, see the
> section "Open
>         Delegation and Data Caching")
> 
>    o    an nfsace4 specifying read and write
> permissions
> 
>    o    a stateid to represent the delegation for READ
> and WRITE
> 
> 
> draft 6  
> the corresponding section reads :
> 
>  When an open delegation is 
> 
>           made,     : made arbitrarily by the server ?

It is up to the server to decide.  Page 82 of draft 6 
lists some conditions that servers might be expected to
use in making this decision.

> 
> the response to the OPEN contains an
>    open delegation structure which specifies the
> following:
> 
>    o    the type of delegation (read or write)
> 
>    o    space limitation information to control
> flushing of data on
>         close (write open delegation only, see the
> section "Open
>         Delegation and Data Caching")
> 
>    o    an nfsace4 specifying read and write
> permissions
> 
>    o    a stateid to represent the delegation for READ
> and WRITE  
> 
> Is the granting of a delegation done only when a
> client requests one Or is it done by the server
> whenever possible so that the client MUST support
> delegation handling ?

As the draft now stands, it can be done by the server
whenever possible but it is expected that servers
will adjust their behavior based on current conditions
and past behavior.  When there is a lot of sharing,
causing delegation recall, a server may choose not to
delegate.  When clients are not conflicting, more 
delegation may be done.  If clients do not respond
to delegation recall or they do so too slowly, causing
problems, a server may choose not to delegate or not
to delegate to particular clients.

Delegation is a performance optimization that the server
is best placed to decide upon.  The rate at which conflicts
will occur is something that the server can't predict
but he has a lot of previous experience to go on.  While
I can imagine cases in which an application might 
have some useful information about the chances that other
clients might reference the file, I don't expect that
the client issuing the OPEN request will normally have 
this information.

As far as a client having to support delegation, it
does have to respond to the delegation grant, but 
the support can be minimal.  If the client immediately
returns the delegation, and ignores all callbacks,
everything will work fine.  The server will probably
decide pretty quickly that granting delgations to
this client is a waste and life will go on.

> if a client can request delegation where is the
> request made to the server (which RPC operation !)
> how ?
 


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 14:33:57 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id OAA13110
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 14:33:56 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id MAA00354;
	Thu, 16 Mar 2000 12:32:12 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id LAA11403;
	Thu, 16 Mar 2000 11:31:39 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2GJVHw12552
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 11:31:17 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id LAA02376
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 11:31:16 -0800 (PST)
Received: from colorfullife.com (colorfullife.com [216.156.138.34])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id LAA01265
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 11:31:00 -0800 (PST)
Received: from clmsdev (localhost [127.0.0.1])
	by colorfullife.com (8.9.3/8.9.3) with SMTP id PAA12663;
	Thu, 16 Mar 2000 15:38:36 -0500
Message-ID: <00a301bf8f7e$799b10c0$0a1e17ac@local>
From: "Manfred Spraul" <manfreds@colorfullife.com>
To: <hans@reiser.to>, "Alexander Viro" <viro@math.psu.edu>
Cc: "Andi Kleen" <ak@suse.de>, "Neil F. Brown" <neilb@cse.unsw.edu.au>,
        <nfsv4-wg@sunroof.eng.sun.com>, <linux-kernel@vger.rutgers.edu>,
        <linux-fsdevel@vger.rutgers.edu>, <reiserfs@devlinux.com>
References: <Pine.GSO.4.10.10003160114290.13531-100000@weyl.math.psu.edu> <38CFF191.DAC18150@idiom.com>
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
Date: Thu, 16 Mar 2000 20:32:22 +0100
MIME-Version: 1.0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.00.2919.6700
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700
Content-Transfer-Encoding: 7bit

From: "Hans Reiser" <reiser@idiom.com>
> >
> > If you mean that we need ID of parent for knfsd - see our discussion on
> > that stuff. VFS doesn't need to know parents of non-directories.
> >
> > Let me ask again:
> >         a) is your "32 bit object ID" sufficient to
> > read/write/chmod/truncate/chown the file? Forget VFS, does the thing
> > contain enough information to do it in principle (aside of scanning the
> > whole tree, indeed)?
> No, we need the directory id plus the objectid (plus the offset) to know
what
> the key is.
I'm not sure if I understood your post:
does "directory id" mean the id of the directory the entry was initialy
created in? So the inode number of the current directory doesn't help?

knfsd currently stores the following members in the nfs handle: [fh_compose
in linux/fs/nfsd/nfsfh.c]

        fhp->fh_handle.fh_dirino = ino_t_to_u32(parent->d_inode->i_ino);
        fhp->fh_handle.fh_dev    = kdev_t_to_u32(parent->d_inode->i_dev);
        fhp->fh_handle.fh_xdev   = kdev_t_to_u32(exp->ex_dev);
        fhp->fh_handle.fh_xino   = ino_t_to_u32(exp->ex_ino);
        fhp->fh_handle.fh_ino = ino_t_to_u32(inode->i_ino);
        fhp->fh_handle.fh_generation = inode->i_generation;

fh_xino is needed internally to check the security
fh_dev is needed to find the superblock.
fh_dirino ==NULL is used internally by knfsd.
fh_ino is the inode number. IIRC POSIX mandates that the 32-bit number is
unique and never 0?
fh_xdev is unused [was used for the sun emulation]
fh_generation is for uniqueness.

What about adding an explicit "get_persistant_id()" function pointer to
inode_operation?
it returns an 80-bit block.
knfsd stores it instead of fh_xdev, fh_dirino, fh_generation in the handle.
It might be possible to extent it to 96 bits, I don't understand when
fh_dirino is set to NULL.

Each filesystem must support "from superblock to dentry/in-memory inode"
with that 80-bit block and the 32-bit inode number of the entry.


> >         b) if you have a directory, is its "32 bit object ID" sufficient
to
> > find ID of its parent?

given what? super block, in-memory inode?

If I'm correct, then a filesystem must
* get the parent of a directory [given the in-memory inode] with 0-bits
additional information.
* get the parent of a non-directory with the same 112 bits.

So VFS+knfsd need:
* super_block operation: go from 10 bytes + inode number to in-memory inodes
of both entry + it's parent.
* inode operation: get the 10-byte persistant id.
* inode operation, only supported for directories: get the parent.

I would prefer if VFS never uses the inode number for any lookups.

> >         b) if you have a directory, is its "32 bit object ID" sufficient
to
> > find ID of its parent?

where do you need that?
IMHO
    super_operations->get_dir_inode(dentry->inode->i_dirino)
is a bad idea,
    dentry->inode->i_ops->get_parent();

gives far more flexibility to the filesystem. get_parent returns -ENOTDIR if
you try to get the parent of a file.

--
    Manfred



From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 16 15:44:48 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id PAA09418
	for <nfsv4-archive@odin.ietf.org>; Thu, 16 Mar 2000 15:44:47 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id NAA00490;
	Thu, 16 Mar 2000 13:43:13 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA22090;
	Thu, 16 Mar 2000 12:42:55 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2GKfAw12711
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 12:41:13 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA26531
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 12:40:40 -0800 (PST)
Received: from math.psu.edu (leibniz.math.psu.edu [146.186.130.2])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id NAA28125
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 13:40:14 -0700 (MST)
Received: from weyl.math.psu.edu (weyl.math.psu.edu [146.186.130.226])
	by math.psu.edu (8.9.3/8.9.3) with ESMTP id PAA04487;
	Thu, 16 Mar 2000 15:40:01 -0500 (EST)
Received: from localhost (viro@localhost)
	by weyl.math.psu.edu (8.9.3/8.9.3) with ESMTP id PAA04807;
	Thu, 16 Mar 2000 15:40:00 -0500 (EST)
X-Authentication-Warning: weyl.math.psu.edu: viro owned process doing -bs
Date: Thu, 16 Mar 2000 15:39:59 -0500 (EST)
From: Alexander Viro <viro@math.psu.edu>
To: Andi Kleen <ak@suse.de>
cc: hans@reiser.to, "Neil F. Brown" <neilb@cse.unsw.edu.au>,
        nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: (reiserfs) reiserfs and knfsd and NFSv4 and volatile file handles
In-Reply-To: <20000316120239.A18464@gruyere.muc.suse.de>
Message-ID: <Pine.GSO.4.10.10003161529570.4547-100000@weyl.math.psu.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII



On Thu, 16 Mar 2000, Andi Kleen wrote:

> That is what they use all the ugly "has rescheduled" flags for. The entry
> also has a "recently deleted" flag that is checked (hidden). When the tree
> is rebalanced inbetween they catch that with a relookup (because offset
> stays a fixed position). When you insert new entries before the current
> filldir offset inbetween you lose (but standard ext2 is no better in that
> as far as I can see). In the 2.3 version they use generation counts for

ext2 relies on directory being locked during readdir(). I'm not sure that
I understand what you mean. Notice that ext2_readdir() used to have a
nasty race - it checked for ->i_version (which is constant), but failed to
check for ->f_version (which can change along with ->f_pos if somebody
does lseek() on descriptor of the same struct file). So it didn't redo the
sanity checks on ->f_pos if somebody did lseek() and that gave a fairly
nasty DoS - ext2 decided to remount the thing r/o, since it thought that
on-disk structure was fucked.

> most things, so they can more easily find out if a object changed.
> As far as I can see the reiserfs readdir handles all races the ext2
> readdir handles.
> 
> [Note that I'm no reiserfs hacker, that just came from my own reading
> of the source. Maybe it is better you apply the patch and do some
> real RTFS ;]

<shrug> if you know how to pack more than 100-odd working hours into the
week - share, lot of people will be very grateful.

> -Andi 
> 
> P.S.: The loopback device in 2.3.51 seems to be still very unstable
> when accessing block devices.  I get weird hangs all the time. It 
> looks like it is leaking some important inode semaphore or similar, 
> because all new processes hang and then the remaining processes
> start to block one after another as they try to do file system
> accesses.

Hmm... That's the path I didn't change at all. I'll look at it. Sigh...



From nfs4-wg-request@sunroof.eng.sun.com  Fri Mar 17 02:23:49 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id CAA02752
	for <nfsv4-archive@odin.ietf.org>; Fri, 17 Mar 2000 02:23:47 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id AAA26619;
	Fri, 17 Mar 2000 00:23:23 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id XAA10225;
	Thu, 16 Mar 2000 23:23:03 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2H7Mfw13230
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 23:22:42 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id XAA20903
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 23:22:41 -0800 (PST)
Received: from idiom.com (idiom.com [216.240.32.1])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id XAA04400
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 16 Mar 2000 23:22:41 -0800 (PST)
Received: from idiom.com (reiser.dial.idiom.com [216.240.37.24])
	by idiom.com (8.9.3/8.9.3) with ESMTP id XAA88054;
	Thu, 16 Mar 2000 23:22:13 -0800 (PST)
Sender: root@idiom.com
Message-ID: <38D14435.5598AC41@idiom.com>
Date: Thu, 16 Mar 2000 23:29:41 +0300
From: Hans Reiser <reiser@idiom.com>
Reply-To: hans@reiser.to
Organization: Namesys
X-Mailer: Mozilla 4.7 [en] (X11; I; Linux 2.2.13 i686)
X-Accept-Language: en, ru
MIME-Version: 1.0
To: Alexander Viro <viro@math.psu.edu>
CC: hans@reiser.to, Andi Kleen <ak@suse.de>,
        "Neil F. Brown" <neilb@cse.unsw.edu.au>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com
Subject: Re: (reiserfs) Re: reiserfs and knfsd and NFSv4 and volatile file 
 handles
References: <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

Alexander Viro wrote:
> 
> On Wed, 15 Mar 2000, Hans Reiser wrote:
> 
> > Not sure I understand your question, but I'll take a stab at it.  Currently the
> > first directory a file is created in stays its packing locality parent for the
> > life of the file.  The packing locality parent is the first key component.  So,
> > currently, if you know the parent directory id the file was created in you know
> > the first component of the key, and the last component of the key is the offset
> > which you can also know.  This leaves the middle of the key unknown.
> 
> Ouch. What happens if you
>         mkdir foo
>         create foo/bar
>         rename foo/bar baz/bar
>         rmdir foo

packing locality is foo.

> and ditto for
>         mkdir foo
>         create foo/bar
>         open foo/bar
>         unlink foo/bar
>         rmdir foo
> - where does your packing locality <whatever> go?

packing locality is foo

> 
> > The immutability of keys is true merely because we don't yet have a repacker to
> > do re-optimize once a day, and it will change, but for now it is true.  The
> > first version of our repacker probably won't change keys, but clearly it should
> > eventually have that functionality.
> 
> And how do you expect NFS to handle that?

I don't.  NFS v4 guys should listen to Neil.

> 
> > The notion that keys/objectids should be immutable over the life of the object
> > is a notion I once believed in but have since conceded was wrong of me.
> 
>         Unfortunately, NFS can't survive without that. POSIX also requires
> constant inumbers, BTW.

It is bad design to require it.  Currently we provide it, but it is bad design. 
It appears to be something fundamental that you cannot change access patterns,
and have a fixed id, and avoid adding a random I/O to a usage pattern that could
otherwise be optimized for by a clever repacker that could optimize that I/O
away by packing the object with other objects it is accessed with.  I was forced
to concede this many years ago by clever persons working for me.  I wanted
immutable objectids, they clean things up so nicely in the architecture. 
Mutable ids require what is effectively two way linking.  I lost the argument.

Thanks for being helpful to us despite a rocky start to our relationship.

I believe your other questions were answered in other emails, not all by me. 
Correct me if I err in this.

Hans
-- 
You can get ReiserFS at http://devlinux.org/namesys, and customizations and
industrial grade support at reiser@idiom.com.


From nfs4-wg-request@sunroof.eng.sun.com  Fri Mar 17 04:26:28 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id EAA22214
	for <nfsv4-archive@odin.ietf.org>; Fri, 17 Mar 2000 04:26:28 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id CAA12003;
	Fri, 17 Mar 2000 02:25:50 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id BAA28831;
	Fri, 17 Mar 2000 01:25:38 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2H9PDw13315;
	Fri, 17 Mar 2000 01:25:14 -0800 (PST)
Received: from mercury.Sun.COM (mercury.EBay.Sun.COM [129.150.69.1])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id BAA21975;
	Fri, 17 Mar 2000 01:25:11 -0800 (PST)
From: Search-Magic@mx.connectfree.co.uk
Received: from kadd.co.kr ([210.102.57.1])
	by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id BAA11081;
	Fri, 17 Mar 2000 01:25:08 -0800 (PST)
Message-Id: <200003170925.BAA11081@mercury.Sun.COM>
To: Magic@yahoo.com
Date: Fri, 17 Mar 00 00:15:35 EST
Subject: Search Engine Secrets Discovered

"Amazing Search Engine Secrets Discovered By A Computer
Illiterate Man in Massachusetts Can Practically Hand
You the Top Search Engine Positions...And Add 1,550 
Hits a Day to Web Site Overnight!"

Dear Friend,

Remember the first time you built a web site. You stayed up 
until the early morning working it out so that it would be 
just perfect. Then, you were finally done and you sat back 
and thought, "The World is Good."

After that, you've dreamed of all the visitors your site 
would have, how they would all see your ad and buy your 
product.  Then it hit you, like a ton of bricks....How was 
anyone going to find your web site?

You thought about it for a while and eventually thought you 
had the answer....submit your site to the search engines. 
But after you submitted your site you checked it out and 
couldn't find it.

So you waited a few days.....and still nothing

You couldn't even find your site if you looked up your own 
name!!!

Then, you got discouraged....after all that hard work 
NOTHING?!?!?

And this is where most people give up.....
BUT You Don't Have To...

You can achieve top 20 positioning for your web site...and 
the tens of thousands of hits which come with it...if you 
have the "Right" information available to you.

For Example, did you know:

* Infoseek, Alta Vista, and HotBot ban web sites which break 
their rules (many of the 'insider' techniques most experts
recommend will get you banned faster than you could imagine).

* Many search engines limit the number of pages you can 
submit from your domain (some only allow you to submit one 
page for best results), although we can show you a technique 
we use to get hundreds of our pages listed.

* Yahoo only lists about 1% of the web in their actual 
directory.  To even get your page listed, you may have to 
use the "backdoor".

* Using a so-called search engine submission software that 
submits your site to 1,000 or more search engines could 
actually get your page deleted from the major search engines.

* 95% of Internet traffic originates at one of the 10 major
search engines...If you're not listed, you might as well
not even have a web site!

* Choosing the most effective 'keywords' is one of the major
keys to a successful web site submission...Pick the right 
ones and your web site will look like Grand Central Station 
during rush hour!

It has taken us over 2 years to learn how to consistently and 
without fail place any type of web site in the top 20 of the 
major search engines.

Normally, we charge $500 per keyword that you want a top 
ranking on (plus a monthly fee of $150 for keeping that rank), 
but we have found we just don't have enough time for all of 
the clients that desperately need our services...

So, we have produced a "Search Engine Magic" interactive
CD-ROM that will show you step by step how to create pages
which storm the search engines and lay hold to the precious 
Top 20 positions that millions of people are trying to reach.

The Search Engine Magic CD-ROM consists of 21 interactive 
video and audio lessons that will run on any IBM compatible 
computer showing you the exact step-by-step process we use 
to traffic thousands of visitors to our web sites every 
single day.

You will learn:

* Three Different Methods We Use to Pick the Best Traffic 
Producing Keywords for any web site...and how you can have 
a list of hundreds of popular keywords in only a few minutes.

* How Quick and Easy it is to Create 'Doorway' and 'Hallway' 
pages for the search engines so that you could possibly have 
thousands of different pages on your domain all pulling in 
visitors for your site 24 hours a day 7 days a week.

* The Secret Weapon that gives you an "Unfair Advantage" over 
your competition...and virtually assures you will reach the 
top positions (don't let your competitors hear about this one 
first or you will be in trouble).

* How to Submit Your Pages to the Search Engines and assure 
that every single one of them gets listed. (if you listen to 
one of those amateurs tell you how to list your site,  you 
may just get banned for life).

* How to Use Pay-Per-Click search engines to receive over 
10,000 visitors for only $100

* The Infamous Yahoo backdoor...You can get listed and we 
will show you the quickest and easiest method for doing so!

* And much, much more...

Even Better, You'll Get the Same Results For A Fraction of 
What Everyone Else Had to Pay!

Listen: A lot of people all over the world are gonna be 
furious with me for sharing these "Insider Secrets" with 
you...especially since you won't be paying even part of what 
they had to shell out for one top positioning page!

That's just too bad.  It's been a secret for too long.  So,
let me tell you what the deal is....

Contact us today using the below Risk-Free Response Form 
and you can have all of our secrets for only $139.00.

This price wouldn't even buy you 10 minutes of our time at
our regular submission fees, but you can own the top search
engine positions for less than the cost of a few classified
ads!  You will be learning everything we know about top 
positioning!

That, my friend, is the bargain of a lifetime for a serious
Internet marketer like yourself.  What’s more, the money is
actually irrelevant, because...

You Also Get a 90 Day No-Risk 100% Money-Back Guarantee!

Here's how it works.  Order your personal copy of this
CD-ROM, and use it like you own it.  If...For any reason
or no reason at all, you aren't completely satisfied after
90 days (by which I had over 47 Top 20 positions for my
own web site), just send the CD-ROM back in any condition,
and I personally guarantee you to get a complete refund
of your purchase price.  No questions asked.  No problems
or forms to fill out.  No problems at all.

PLUS, You Will Also Receive What is Considered to be by
most experts as the "Ultimate Bonus!"

For the first 50 people who fill out the below response
form and send it in, you will also receive UNLIMITED
REPRINT AND REPRODUCTION RIGHTS to this 
CD-ROM for LIFE!

I am not going to allow this CD-ROM to become like many
of those over-advertised products you see out there,
so only the first 50 will receive these rights.

This means that you will be able to use this exact same
sales letter, copy the CD-ROM yourself, and sell it

For $139.00 a copy, one sell will have breaking even.  Sell 
two copies and you will be in profit.This isn't even 
counting what the CD-ROM package will do for you!

Since only 50 people are going to have these rights...
you must take action today!

Yours in Success,
Michael Burgess


To rush order this "Search Engine Magic CD-ROM" simply fill 
out the order form below and fax it to our 24 hour  order 
line at:

FAX ORDER LINE:
1 (212) 504-8032

Regular Mail to:
Financial Systems
P.O. Box 301
Orange, Ma 01364


ORDER FORM
--------------------------------------------------------
Please send to:


Your Name: _____________________________________________


Your Address: __________________________________________


Your City: _____________________________________________


State / Zip: ___________________________________________


Your Country: __________________________________________


Phone #: _______________________________________________
(For problems with your order only. No salesmen will call.)


Email Address: ___________________________________________


We Accept Checks or Money Orders along with all Major Credit 
Cards including Visa, MasterCard, American Express and 
Discover. (NOTE - We only ship to the address listed on the 
credit card)


(Please Fill Out Below Section and Make sure that the above 
name and address are listed as it appears on the card) for 
$144 ($139 + 5.00 Shipping)


Credit Card Number:________________________________


Expiration Date:___________________________


Signature:_________________________


Date:____________________


* Please check one of the following payment options:


[  ] I am faxing a check (Do not send original, we will make 
     a draft from the faxed check)

[  ] I am faxing or mailing my credit card number. (Note your 
     card will be charged for $144.00 and we only ship to the
     address on the card)

[  ] I am enclosing a check or money order for $144.00!


Note - If ordering outside continental US, please add 
$5 to S&H


P.S. If you send in your order and you are not one of the
first 50 to receive the Reprint and Reproduction Rights,
I will notify you immediately and give you the opportunity
to cancel your order.



_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
If you have received this message in error and would
like to be removed from future mailings, please reply
with the word remove in the subject. x
_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/




From nfs4-wg-request@sunroof.eng.sun.com  Fri Mar 17 10:37:35 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA14275
	for <nfsv4-archive@odin.ietf.org>; Fri, 17 Mar 2000 10:37:34 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA10766;
	Fri, 17 Mar 2000 08:36:04 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA02986;
	Fri, 17 Mar 2000 07:35:51 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.85.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2HFZZw13672
	for <nfsv4-wg@sunroof.eng.sun.com>; Fri, 17 Mar 2000 07:35:36 -0800 (PST)
Received: from eng.sun.com (dsl196-127.Eng.Sun.COM [129.146.196.127])
	by jurassic.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2HFZZQ685275;
	Fri, 17 Mar 2000 07:35:35 -0800 (PST)
Sender: Spencer.Shepler@eng.sun.com
Message-ID: <38D25025.F50DE1EF@eng.sun.com>
Date: Fri, 17 Mar 2000 09:32:53 -0600
From: Spencer Shepler <shepler@eng.sun.com>
Organization: Sun Microsystems, Inc.
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.6 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: "nfsv4-wg@sunroof.eng.sun.com" <nfsv4-wg@sunroof.eng.sun.com>
Subject: Latest status of the NFSv4 protocol draft
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit


All,

As you know, the IETF last call for the NFSv4 protocol draft
ended on March 6th.

I believe all of the issues that were raised during the last call
have been resolved such that there are no updates needed to the
latest draft (-nfsv4-06.txt).  From here our area advisor, Vern Paxson,
will be working his final review for presentation to the IESG.

Again, thanks to all for the help with the draft.

Spencer


From nfs4-wg-request@sunroof.eng.sun.com  Fri Mar 17 11:30:19 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id LAA07445
	for <nfsv4-archive@odin.ietf.org>; Fri, 17 Mar 2000 11:30:17 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id JAA13301;
	Fri, 17 Mar 2000 09:26:49 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id IAA04486;
	Fri, 17 Mar 2000 08:26:33 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.85.31] (may be forged))
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2HGQKw13737
	for <nfsv4-wg@sunroof.eng.sun.com>; Fri, 17 Mar 2000 08:26:21 -0800 (PST)
Received: from eng.sun.com (awe195-180.AWE.Sun.COM [192.29.195.180])
	by jurassic.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2HGQKQ694109;
	Fri, 17 Mar 2000 08:26:20 -0800 (PST)
Sender: Brent.Callaghan@eng.sun.com
Message-ID: <38D25C50.B2154831@eng.sun.com>
Date: Fri, 17 Mar 2000 08:24:48 -0800
From: Brent <brent@eng.sun.com>
Organization: NFS Whackers
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.8 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: agenda@ietf.org
CC: nfsv4-wg@sunroof.eng.sun.com
Subject: Agenda for nfsv4 WG meeting @ 47th IETF
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit


Network File System Version 4 (nfsv4)
-------------------------------------
 
Chair(s):

    Brent Callaghan <brent@eng.sun.com>
    Brian Pawlowski <beepy@netapp.com>

Document Editor:

    Spencer Shepler <shepler@eng.sun.com>

 
AGENDA

  Monday March 27th: 7:30pm - 10:00 (2.5 hours) - Room 8&9

    Welcome and Introduction            (Callaghan)        5 min

    Overview of Updates to Spec         (Shepler)         30 min

    NFSv4 Implementation Choices RFC    (Shepler)         10 min

    Implementation Reqmts for Draft     (Shepler)          5 min

    NFSv4 @ Connectathon 2000           (Callaghan)        5 min

    Source code from Sun                (Crair)           20 min

    Open discussion                     (Pawlowski)       70 min

    Wrapup                              (Pawlowski)        5 min



  Tuesday March 28th: 5:00pm - 6:00 (1 hour) - Room 8&9

    Further open discussion             (Pawlowski)       60 min


From nfs4-wg-request@sunroof.eng.sun.com  Fri Mar 17 20:34:36 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id UAA10756
	for <nfsv4-archive@odin.ietf.org>; Fri, 17 Mar 2000 20:34:35 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id SAA28566;
	Fri, 17 Mar 2000 18:33:42 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id RAA11576;
	Fri, 17 Mar 2000 17:33:31 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2I1XHw14340
	for <nfsv4-wg@sunroof.eng.sun.com>; Fri, 17 Mar 2000 17:33:17 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id RAA18865
	for <nfsv4-wg@sunroof.eng.sun.com>; Fri, 17 Mar 2000 17:33:17 -0800 (PST)
Received: from math.psu.edu (leibniz.math.psu.edu [146.186.130.2])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id RAA15229
	for <nfsv4-wg@sunroof.eng.sun.com>; Fri, 17 Mar 2000 17:33:16 -0800 (PST)
Received: from weyl.math.psu.edu (weyl.math.psu.edu [146.186.130.226])
	by math.psu.edu (8.9.3/8.9.3) with ESMTP id UAA21432;
	Fri, 17 Mar 2000 20:32:34 -0500 (EST)
Received: from localhost (viro@localhost)
	by weyl.math.psu.edu (8.9.3/8.9.3) with ESMTP id UAA07970;
	Fri, 17 Mar 2000 20:32:33 -0500 (EST)
X-Authentication-Warning: weyl.math.psu.edu: viro owned process doing -bs
Date: Fri, 17 Mar 2000 20:32:33 -0500 (EST)
From: Alexander Viro <viro@math.psu.edu>
To: hans@reiser.to
cc: Andi Kleen <ak@suse.de>, "Neil F. Brown" <neilb@cse.unsw.edu.au>,
        nfsv4-wg@sunroof.eng.sun.com, linux-kernel@vger.rutgers.edu,
        linux-fsdevel@vger.rutgers.edu, reiserfs@devlinux.com
Subject: Re: (reiserfs) Re: reiserfs and knfsd and NFSv4 and volatile file 
 handles
In-Reply-To: <38D14435.5598AC41@idiom.com>
Message-ID: <Pine.GSO.4.10.10003172025100.4547-100000@weyl.math.psu.edu>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII



On Thu, 16 Mar 2000, Hans Reiser wrote:

> Alexander Viro wrote:
> > 
> > On Wed, 15 Mar 2000, Hans Reiser wrote:
> > 
> > > Not sure I understand your question, but I'll take a stab at it.  Currently the
> > > first directory a file is created in stays its packing locality parent for the
> > > life of the file.  The packing locality parent is the first key component.  So,
> > > currently, if you know the parent directory id the file was created in you know
> > > the first component of the key, and the last component of the key is the offset
> > > which you can also know.  This leaves the middle of the key unknown.
> > 
> > Ouch. What happens if you
> >         mkdir foo
> >         create foo/bar
> >         rename foo/bar baz/bar
> >         rmdir foo
> 
> packing locality is foo.

Even though inode of foo is gone? OK, fine with me. Do you mean that your
"locality" is roughly an equivalent of cylinder group on FFS?

> I believe your other questions were answered in other emails, not all by me. 
> Correct me if I err in this.

Umm... I'd still like to hear a description of your internal locking. In
particular, what do you lock/release upon reiserfs_find_entry()/pathrelse()?
When do you rebalance the tree? How do you do serialization between that
and things a-la write_inode()/readdir()/lookup()? Currently locking is
masked by the VFS one and that's one of the reasons why I want to see
cleaned variant.



From nfs4-wg-request@sunroof.eng.sun.com  Sat Mar 18 17:24:09 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id RAA01634
	for <nfsv4-archive@odin.ietf.org>; Sat, 18 Mar 2000 17:24:08 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA03191;
	Sat, 18 Mar 2000 15:23:35 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA03670;
	Sat, 18 Mar 2000 14:23:18 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.0+Sun/8.10.0) with ESMTP id e2IMN3w14676
	for <nfsv4-wg@sunroof.eng.sun.com>; Sat, 18 Mar 2000 14:23:03 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA29724
	for <nfsv4-wg@sunroof.eng.sun.com>; Sat, 18 Mar 2000 14:23:03 -0800 (PST)
Received: from idiom.com (idiom.com [216.240.32.1])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA03116
	for <nfsv4-wg@sunroof.eng.sun.com>; Sat, 18 Mar 2000 15:23:03 -0700 (MST)
Received: from idiom.com (reiser.dial.idiom.com [216.240.37.24])
	by idiom.com (8.9.3/8.9.3) with ESMTP id OAA85542;
	Sat, 18 Mar 2000 14:22:40 -0800 (PST)
Sender: root@idiom.com
Message-ID: <38D368B6.98E0CF6A@idiom.com>
Date: Sat, 18 Mar 2000 14:29:58 +0300
From: Hans Reiser <reiser@idiom.com>
Reply-To: hans@reiser.to
Organization: Namesys
X-Mailer: Mozilla 4.7 [en] (X11; I; Linux 2.2.13 i686)
X-Accept-Language: en, ru
MIME-Version: 1.0
To: Alexander Viro <viro@math.psu.edu>
CC: hans@reiser.to, Andi Kleen <ak@suse.de>,
        "Neil F. Brown" <neilb@cse.unsw.edu.au>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com, Alexander Zarochentcev <zam@programbank.ru>,
        Roman Pozlevich <roma@botik.ru>
Subject: Re: (reiserfs) Re: reiserfs and knfsd and NFSv4 and volatile file 
 handles
References: <Pine.GSO.4.10.10003172025100.4547-100000@weyl.math.psu.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

Alexander Viro wrote:
> 
> On Thu, 16 Mar 2000, Hans Reiser wrote:
> 
> > Alexander Viro wrote:
> > >
> > > On Wed, 15 Mar 2000, Hans Reiser wrote:
> > >
> > > > Not sure I understand your question, but I'll take a stab at it.  Currently the
> > > > first directory a file is created in stays its packing locality parent for the
> > > > life of the file.  The packing locality parent is the first key component.  So,
> > > > currently, if you know the parent directory id the file was created in you know
> > > > the first component of the key, and the last component of the key is the offset
> > > > which you can also know.  This leaves the middle of the key unknown.
> > >
> > > Ouch. What happens if you
> > >         mkdir foo
> > >         create foo/bar
> > >         rename foo/bar baz/bar
> > >         rmdir foo
> >
> > packing locality is foo.
> 
> Even though inode of foo is gone? OK, fine with me. Do you mean that your
> "locality" is roughly an equivalent of cylinder group on FFS?

The objects in the tree are fully ordered by their keys.  The packing locality
is the first component of the key.  The bitmap.c algorithms, when assigning
blocks to nodes of the tree, put new nodes in the first free block after the
block holding the left neighbor in this tree ordering of the new node.

> 
> > I believe your other questions were answered in other emails, not all by me.
> > Correct me if I err in this.
> 

I leave the below for Alexei and Vladimir to answer in detail.  Generally
speaking, we can only do clean effective SMP after implementing per buffer
seals.  I see that as unlikely to make it into 2.4 due to it requiring a per
buffer/page fs specific struct, but it is actively being coded by Zarochentcev
and Roma.  If 2.4 is slow enough in coming out, maybe we will submit it just in
case Linus will take it.  Our SMP will be poor until we have it.

> Umm... I'd still like to hear a description of your internal locking. In
> particular, what do you lock/release upon reiserfs_find_entry()/pathrelse()?
> When do you rebalance the tree? How do you do serialization between that
> and things a-la write_inode()/readdir()/lookup()? Currently locking is
> masked by the VFS one and that's one of the reasons why I want to see
> cleaned variant.

-- 
You can get ReiserFS at http://devlinux.org/namesys, and customizations and
industrial grade support at reiser@idiom.com.


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar 20 13:07:30 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id NAA22069
	for <nfsv4-archive@odin.ietf.org>; Mon, 20 Mar 2000 13:07:30 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA17857;
	Mon, 20 Mar 2000 10:57:35 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id JAA25089;
	Mon, 20 Mar 2000 09:57:11 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.81.144] (may be forged))
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2KHuvN15989
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 20 Mar 2000 09:56:57 -0800 (PST)
Received: from eng.sun.com (dsl196-127.Eng.Sun.COM [129.146.196.127])
	by jurassic.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2KHurj967299;
	Mon, 20 Mar 2000 09:56:53 -0800 (PST)
Sender: Spencer.Shepler@eng.sun.com
Message-ID: <38D665BE.4DA87F51@eng.sun.com>
Date: Mon, 20 Mar 2000 11:54:06 -0600
From: Spencer Shepler <shepler@eng.sun.com>
Organization: Sun Microsystems, Inc.
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.6 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: "nfsv4-wg@sunroof.eng.sun.com" <nfsv4-wg@sunroof.eng.sun.com>
Subject: [Fwd: Protocol Action: LIPKEY - A Low Infrastructure Public KeyMechanism 
 Using SPKM to Proposed Standard]
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit


Note below that LIPKEY (dependency for NFSv4) has been 
approved as a proposed standard.

Spencer

The IESG wrote:
> 
> The IESG has approved the Internet-Draft 'LIPKEY - A Low Infrastructure
> Public Key Mechanism Using SPKM' <draft-ietf-cat-lipkey-03.txt> as a
> Proposed Standard.  This document is the product of the Common
> Authentication Technology Working Group.  The IESG contact persons are
> Jeffrey Schiller and Marcus Leech.
> 
> 
> Technical Summary
> 
> The Simple Public Key Mechanism (SPKM) is a GSSAPI mechanism that
> makes use of public/private key pairs to provide authentication within
> the context of the GSSAPI. LIPKEY is an extension that requires only
> one side of the association (nominally the server) to have a public
> key certificate. The client side can use a password, which will be
> encrypted, for authentication. LIPKEY provides the GSSAPI equivalent
> of going to a Web Site via TLS and performing client authentication
> via a password (which is encrypted by TLS). This approach has the
> property that only servers have to obtain and deal with public key
> certificates.
> 
> Working Group Summary
> 
> The working group supports this document.
> 
> Protocol Quality
> 
> Jeff Schiller has reviewed this document for the IESG and found no
> flaws in the protocol.
> 
> Note to RFC Editor:
> 
> Please arrange with the IANA for the assignment of three OIDs
> under the IETF arc and edit this document (sections 2.1, 2.3.1, and 4.1) to
> include the newly assigned OIDs"
> 
> Also change the following references:
> 
> From:
> 
>     [RSA-IP]  Unidentified member of IETF's Public-Key Infrastructure
>               (X.509) Working Group (Undated, but no later than 1999).
>               "RSA's unofficial statement pertaining to PKIX."
>               http://www.ietf.org/ietf/IPR/PKIX-RSA
> 
> To:
> 
>     [RSA-IP]  All statements received by the IETF Secretariat are
>               places on-line in http://www.ietf.org/ipr.html.  Please
>               check this web page to see any IPR information received
>               about this and other technology.
> 
> From:
> 
>     [Young]   Young, E.A. (1997). "Index of /archives/net/Crypto/libeay."
>               http://ring.crl.go.jp/archives/net/Crypto/libeay/
> 
> To:
> 
>     [Young]   Young, E.A. (1997). Collected timing results from the SSLeay
>               source code distribution.


From nfs4-wg-request@sunroof.eng.sun.com  Mon Mar 20 13:25:15 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id NAA29616
	for <nfsv4-archive@odin.ietf.org>; Mon, 20 Mar 2000 13:25:13 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id LAA06404;
	Mon, 20 Mar 2000 11:22:34 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id KAA19816;
	Mon, 20 Mar 2000 10:22:16 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2KIM0N16013
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 20 Mar 2000 10:22:00 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id KAA19736
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 20 Mar 2000 10:21:58 -0800 (PST)
Received: from dukat.scot.redhat.com (dukat.scot.redhat.com [195.89.149.246])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id LAA05904
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 20 Mar 2000 11:21:54 -0700 (MST)
Received: (from sct@localhost)
	by dukat.scot.redhat.com (8.9.3/8.9.3) id SAA02886;
	Mon, 20 Mar 2000 18:21:19 GMT
Date: Mon, 20 Mar 2000 18:21:19 +0000
From: "Stephen C. Tweedie" <sct@scot.redhat.com>
To: hans@reiser.to
Cc: Alexander Viro <viro@math.psu.edu>, Andi Kleen <ak@suse.de>,
        "Neil F. Brown" <neilb@cse.unsw.edu.au>, nfsv4-wg@sunroof.eng.sun.com,
        linux-kernel@vger.rutgers.edu, linux-fsdevel@vger.rutgers.edu,
        reiserfs@devlinux.com, sct@redhat.com
Subject: Re: (reiserfs) Re: reiserfs and knfsd and NFSv4 and volatile file handles
Message-ID: <20000320182119.B2792@dukat.scot.redhat.com>
References: <Pine.GSO.4.10.10003160238260.13531-100000@weyl.math.psu.edu> <38D14435.5598AC41@idiom.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 1.0.1i
In-Reply-To: <38D14435.5598AC41@idiom.com>; from reiser@idiom.com on Thu, Mar 16, 2000 at 11:29:41PM +0300

On Thu, Mar 16, 2000 at 11:29:41PM +0300, Hans Reiser wrote:
> >         Unfortunately, NFS can't survive without that. POSIX also requires
> > constant inumbers, BTW.
> 
> It is bad design to require it.  Currently we provide it, but it is bad design. 

Unfortunately a lot of existing applications require it.  "cp" and "tar", 
for example: if you use a "cp -a" or a tar over hard links, it is the 
unique (filesystem, inode number) identifier for the file which allows
hard links to be identified.

If you abandon the existence of such an identifier, then how can tar 
maintain the current behaviour?

--Stephen



From nfs4-wg-request@sunroof.eng.sun.com  Tue Mar 21 01:57:19 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id BAA17338
	for <nfsv4-archive@odin.ietf.org>; Tue, 21 Mar 2000 01:57:18 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id XAA15501;
	Mon, 20 Mar 2000 23:56:55 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id WAA11556;
	Mon, 20 Mar 2000 22:56:41 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.84.31] (may be forged))
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2L6uVN16749
	for <nfsv4-wg@sunroof.eng.sun.com>; Mon, 20 Mar 2000 22:56:32 -0800 (PST)
Received: from eng.sun.com (dsl196-127.Eng.Sun.COM [129.146.196.127])
	by jurassic.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2L6uTj187231;
	Mon, 20 Mar 2000 22:56:29 -0800 (PST)
Sender: Spencer.Shepler@eng.sun.com
Message-ID: <38D71C75.BA63D6A8@eng.sun.com>
Date: Tue, 21 Mar 2000 00:53:41 -0600
From: Spencer Shepler <shepler@eng.sun.com>
Organization: Sun Microsystems, Inc.
X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.6 sun4u)
X-Accept-Language: en
MIME-Version: 1.0
To: eric kustarz <kustarze@engin.umich.edu>
CC: "nfsv4-wg@sunroof.eng.sun.com" <nfsv4-wg@sunroof.eng.sun.com>
Subject: Re: NFSV4: VERIFY
References: <Pine.SOL.4.02.10003201609390.25095-100000@x1.engin.umich.edu>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit

eric kustarz wrote:
> 
> Hi Spencer,
> 
> Maybe I am missing something but I'm not sure...
> 
> Why is there both a bitmap4 AND fattr4 in the arguments for VERIFY and
> NVERIFY? A fattr4 already has a bitmap4 in it, it seems like this is
> redudant information.

You are correct, Eric.  Both VERIFY and NVERIFY contain the additional
bitmap4.  This should be changed.  I have a couple of minor error code
return changes that need to be made and was hoping that it could be done
with minimal fuss but this change is a little larger. :-(


> Even the Synopsis seems to suggest the same thing:
>      (cfh), attrbits, attrvals -> -
> 
> Since a fattr4 has attrbits and attrvals in it.
> 
> thanx,
> eric


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 22 06:17:27 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id GAA01456
	for <nfsv4-archive@odin.ietf.org>; Wed, 22 Mar 2000 06:17:27 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id EAA24329;
	Wed, 22 Mar 2000 04:17:00 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA09775;
	Wed, 22 Mar 2000 03:16:37 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2MBGQN17678
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 03:16:27 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id DAA18954
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 03:16:25 -0800 (PST)
Received: from web3705.mail.yahoo.com (web3705.mail.yahoo.com [204.71.203.134])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id DAA08950
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 03:16:25 -0800 (PST)
Message-ID: <20000322111625.16392.qmail@web3705.mail.yahoo.com>
Received: from [202.54.64.130] by web3705.mail.yahoo.com; Wed, 22 Mar 2000 11:16:25 GMT
Date: Wed, 22 Mar 2000 11:16:25 +0000 (GMT)
From: =?iso-8859-1?q?kvs=20sivak?= <kvs_sivak@yahoo.co.uk>
Subject: Compound operations : NFS kernel support
To: nfsv4-wg@sunroof.eng.sun.com
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
Content-Transfer-Encoding: 8bit

hi,
 We are trying to implement NFS v4 support in Linux
Kernel 2.2.
It is needed that the VFS interface be coded to
support any required file system in Linux.Since the
VFS looks at each operation as an independent one
there seems to be no advantage in using Compound
except in adding the extra processing required.

for example the namei opreation looks up directories
at only one level. there is no multi-component
lookup.This would make it impossoible to use the
multi-component lookup of NFSv4.Thus the kernel would
request lookups only for a single component and there
is no way to determine a full pathname that may be
sent to the NFS server for multi-component lookup.
similarly for other procedures too.

Is this understanding of ours correct ?
Are there any other means by which compound opreations
can be used advantageously ?


K.Sivakumar
K.V.Subramanian

____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 22 09:20:49 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id JAA03659
	for <nfsv4-archive@odin.ietf.org>; Wed, 22 Mar 2000 09:20:48 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id HAA05943;
	Wed, 22 Mar 2000 07:20:09 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id GAA20995;
	Wed, 22 Mar 2000 06:19:52 -0800 (PST)
Received: from engmail1.Eng.Sun.COM (engmail1 [129.146.1.13])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2MEJcN17794
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 06:19:39 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id GAA20429
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 06:19:39 -0800 (PST)
Received: from mx01-ext.netapp.com (mx01-ext.netapp.com [198.95.224.34])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id GAA16031
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 06:19:37 -0800 (PST)
Received: (qmail 15254 invoked from network); 22 Mar 2000 14:30:03 -0000
Received: from herra.netapp.com (HELO herra.corp.netapp.com) (198.95.224.184)
  by mx01-ext.netapp.com with SMTP; 22 Mar 2000 14:30:03 -0000
Received: from tahoe.corp.netapp.com (tahoe.corp.netapp.com [10.10.22.112])
	by herra.corp.netapp.com (8.9.3/8.9.3/NTAP-1.0) with ESMTP id GAA16524;
	Wed, 22 Mar 2000 06:19:35 -0800 (PST)
Received: by tahoe.corp.netapp.com with Internet Mail Service (5.5.2650.21)
	id <HKXRVCXY>; Wed, 22 Mar 2000 06:19:26 -0800
Message-ID: <F6C5585BF0CED311B58D009027C2299C47C036@tahoe.corp.netapp.com>
From: "Noveck, Dave" <dave.noveck@netapp.com>
To: "'kvs sivak'" <kvs_sivak@yahoo.co.uk>, nfsv4-wg@sunroof.eng.sun.com
Subject: RE: Compound operations : NFS kernel support
Date: Wed, 22 Mar 2000 06:19:26 -0800
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2650.21)
Content-Type: text/plain;
	charset="iso-8859-1"

kvs sivak wrote:
>  We are trying to implement NFS v4 support in Linux
> Kernel 2.2.
> It is needed that the VFS interface be coded to
> support any required file system in Linux.Since the
> VFS looks at each operation as an independent one
> there seems to be no advantage in using Compound
> except in adding the extra processing required.

I don't know the details of the Linux VFS but there
may be cases in which you will want to compound
GETATTR with other operations, such as OPEN.  When
opening a file you are supposed to clear your data
cache if the file has been modified since the last 
time you opened it.  Doing a GETATTR compounded with
the OPEN is probably the best way to do that.

In cases where your VFS structure means that the 
information it would be convenient to get with 
COMPOUND is not required by the current operation,
you can still use caching to avoid RPC's.  If you
put the results of a GETATTR compounded with another
request in you attribute cache, it will be 
available when OS code, through the VFS, decides 
to ask for it, avoiding an RPC at that point.
Depending on the kinds of environments you are
targetting, you could extend this to other cases
in which the need for the attributes is probable
but not certain.  You could always add GETATTR
to LOOKUP on the grounds that it adds very little
cost and will often be required.  You could also
add READ to OPEN for read to get the first block 
of data and cache it.  There are lots of possibilities.
Some of them may even be desirable :-)

When latency is high, it might even be useful to
combine operations for unrelated files with an 
RPC tat you are doing anyway.  For example,
attribute and name cache entries that are being
used but are soon to time out, might be revalidated
by doing GETATTR's compounded to a totally unrelated
RPC.
 
> 
> for example the namei opreation looks up directories
> at only one level. there is no multi-component
> lookup.This would make it impossoible to use the
> multi-component lookup of NFSv4.Thus the kernel would
> request lookups only for a single component and there
> is no way to determine a full pathname that may be
> sent to the NFS server for multi-component lookup.

I don't see how you could use multi-component lookup.

> similarly for other procedures too.

For multi-component lookup, the V4 client code has no
way of knowing or effectively guessing what will be 
needed next.  In cases in which you can make a good
guess it may be possible to do operations in advance,
as long as those only interrogate file system state.
 
> Is this understanding of ours correct ?
> Are there any other means by which compound opreations
> can be used advantageously ?

I believe there are but this is just speculation.  I
think everyone is very interested to find out how useful
COMPOUND turns out to be in practice.
 


From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 22 10:26:31 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA27108
	for <nfsv4-archive@odin.ietf.org>; Wed, 22 Mar 2000 10:26:30 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA12239;
	Wed, 22 Mar 2000 08:24:16 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA24807;
	Wed, 22 Mar 2000 07:24:04 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.84.31] (may be forged))
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2MFNbN17825
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 07:23:37 -0800 (PST)
Received: from teal (awe8-115.Central.Sun.COM [129.147.8.115])
	by jurassic.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with SMTP id e2MFNZb135398;
	Wed, 22 Mar 2000 07:23:35 -0800 (PST)
Date: Wed, 22 Mar 2000 07:26:22 -0800 (PST)
From: Mike Eisler <mre@eng.sun.com>
Reply-To: Mike Eisler <mre@eng.sun.com>
Subject: RE: Compound operations : NFS kernel support
To: "Noveck, Dave" <dave.noveck@netapp.com>
Cc: "'kvs sivak'" <kvs_sivak@yahoo.co.uk>, nfsv4-wg@sunroof.eng.sun.com
In-Reply-To: "Your message with ID" <F6C5585BF0CED311B58D009027C2299C47C036@tahoe.corp.netapp.com>
Message-ID: <Roam.SIMC.2.0.6.953738782.10274.mre@eng.sun.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; CHARSET=US-ASCII

> kvs sivak wrote:
> >  We are trying to implement NFS v4 support in Linux
> > Kernel 2.2.
> > It is needed that the VFS interface be coded to
> > support any required file system in Linux.Since the
> > VFS looks at each operation as an independent one
> > there seems to be no advantage in using Compound
> > except in adding the extra processing required.
> 
> I don't know the details of the Linux VFS but there
> may be cases in which you will want to compound
> GETATTR with other operations, such as OPEN.  When
> opening a file you are supposed to clear your data
> cache if the file has been modified since the last 
> time you opened it.  Doing a GETATTR compounded with
> the OPEN is probably the best way to do that.

One may also want to compound OPEN with READ to get the first few bytes. This
is useful to optimize UNIX commands like "file" or GUI-based browsers that
like to show users little icons that describe the file content.

> > for example the namei opreation looks up directories
> > at only one level. there is no multi-component
> > lookup.This would make it impossoible to use the
> > multi-component lookup of NFSv4.Thus the kernel would
> > request lookups only for a single component and there
> > is no way to determine a full pathname that may be
> > sent to the NFS server for multi-component lookup.
> 
> I don't see how you could use multi-component lookup.

If kvs's client doesn't use multi-component lookup, mounts
are going to result in lots more operations. Perhaps kvs's
client will use COMPOUND to send a series of:

	LOOKUP "c1" ; LOOKUP "c2"; ... LOOKUP "cN" ; GETFH

To avoid multiple round trips.

Or perhaps the server side lookup routine could simple call namei in a loop
when it gets a multi-component lookup.

> > Is this understanding of ours correct ?
> > Are there any other means by which compound opreations
> > can be used advantageously ?
> 
> I believe there are but this is just speculation.  I
> think everyone is very interested to find out how useful
> COMPOUND turns out to be in practice.

The immediate usefulness of COMPOUND is that the any additional overheard is
made up for in streamlined code. For example file handle processing. Consider
models that export file systems to groups of hosts. In NFSv[23] one has to
extract the the file handle from one of dozens of different argument
structures.  In an NFSv4 server, extracting the current file handle is a
breeze, and so one deals with less code. The post op attribute processing is
another example, where in V3, code was needed in each client and server side
operation to deal with processing (or non-processing) of optional post of
attributes. Now it can be done in one place on the client and server. Going
back to one READDIR from two in NFSv3 is another example; cuts the code in
half. And of course COMPOUND or multi-component lookup eliminates the
MOUNT protocol. 

	-mre




From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 22 18:42:41 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA26890
	for <nfsv4-archive@odin.ietf.org>; Wed, 22 Mar 2000 18:42:40 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA18535;
	Wed, 22 Mar 2000 16:42:15 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA05144;
	Wed, 22 Mar 2000 15:42:00 -0800 (PST)
Received: from engmail3.Eng.Sun.COM (engmail3 [129.144.170.5])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2MNfhN18233
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 15:41:43 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA13888
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 15:41:43 -0800 (PST)
Received: from sgi.com (sgi.SGI.COM [192.48.153.1])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA20938
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 15:41:42 -0800 (PST)
Received: from cthulhu.engr.sgi.com (cthulhu.engr.sgi.com [192.26.80.2]) 
	by sgi.com (980327.SGI.8.8.8-aspam/980304.SGI-aspam:
       SGI does not authorize the use of its proprietary
       systems or networks for unsolicited or bulk email
       from the Internet.) 
	via ESMTP id PAA06659; Wed, 22 Mar 2000 15:41:32 -0800 (PST)
	mail_from (zamsden@clock.engr.sgi.com)
Received: from clock.engr.sgi.com (clock.engr.sgi.com [163.154.34.45])
	by cthulhu.engr.sgi.com (980427.SGI.8.8.8/970903.SGI.AUTOCF)
	via ESMTP id PAA43157;
	Wed, 22 Mar 2000 15:41:29 -0800 (PST)
	mail_from (zamsden@clock.engr.sgi.com)
Received: from clock.engr.sgi.com (localhost [127.0.0.1]) by clock.engr.sgi.com (980427.SGI.8.8.8/970903.SGI.AUTOCF) via ESMTP id PAA46763; Wed, 22 Mar 2000 15:48:59 -0800 (PST)
Message-Id: <200003222348.PAA46763@clock.engr.sgi.com>
X-Mailer: exmh version 2.0.2 2/24/98
To: =?iso-8859-1?q?kvs=20sivak?= <kvs_sivak@yahoo.co.uk>
Cc: nfsv4-wg@sunroof.eng.sun.com
Subject: Re: Compound operations : NFS kernel support 
From: Zachary Amsden <zamsden@cthulhu.engr.sgi.com>
In-Reply-To: Your message of "Wed, 22 Mar 2000 11:16:25 GMT."
             <20000322111625.16392.qmail@web3705.mail.yahoo.com> 
Date: Wed, 22 Mar 2000 15:48:59 -0800
Sender: zamsden@clock.engr.sgi.com

Compound operations should be a big advantage for doing GETATTR on all files 
in a directory, or similar batch tasks.

-- 
Zachary Amsden  zamsden@engr.sgi.com  3-6919  31-2-510  Core Protocols




From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 22 18:50:06 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id SAA29189
	for <nfsv4-archive@odin.ietf.org>; Wed, 22 Mar 2000 18:50:06 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA23373;
	Wed, 22 Mar 2000 16:49:33 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA08769;
	Wed, 22 Mar 2000 15:49:22 -0800 (PST)
Received: from nyday.eng.sun.com (nyday [129.146.86.69])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2MNnBN18243
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 22 Mar 2000 15:49:11 -0800 (PST)
Received: (from staubach@localhost)
	by nyday.eng.sun.com (8.9.3+Sun/8.9.3) id PAA142575;
	Wed, 22 Mar 2000 15:49:08 -0800 (PST)
Date: Wed, 22 Mar 2000 15:49:08 -0800 (PST)
From: Peter Staubach <Peter.Staubach@eng.sun.com>
Message-Id: <200003222349.PAA142575@nyday.eng.sun.com>
To: kvs_sivak@yahoo.co.uk, zamsden@cthulhu.engr.sgi.com
Subject: Re: Compound operations : NFS kernel support
Cc: nfsv4-wg@sunroof.eng.sun.com
X-Sun-Charset: US-ASCII


> 
> Compound operations should be a big advantage for doing GETATTR on all files 
> in a directory, or similar batch tasks.
> 

This would be true iff the client already has all of the file handles
for all of the entries in a directory, and, more interestingly, if the
client operating system has an interface or an implementation which can
take advantage of it.  I suppose that the client could send over a
compound request composed of LOOKUP operations, but it would still need
an interface or an implementation which would cause it do such an
operation.

I haven't heard about a system which contains support for such a bulk
operation, but I sure would like to if one exists.

	Thanx...

		ps


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 23 10:11:58 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id KAA09633
	for <nfsv4-archive@odin.ietf.org>; Thu, 23 Mar 2000 10:11:58 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id IAA23041;
	Thu, 23 Mar 2000 08:10:36 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA02205;
	Thu, 23 Mar 2000 07:10:20 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2NF9VN18705
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 07:09:31 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id HAA24186
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 07:09:32 -0800 (PST)
Received: from mx01-ext.netapp.com (mx01-ext.netapp.com [198.95.224.34])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with SMTP id HAA22157
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 07:09:31 -0800 (PST)
Received: (qmail 27084 invoked from network); 23 Mar 2000 15:20:24 -0000
Received: from herra.netapp.com (HELO herra.corp.netapp.com) (198.95.224.184)
  by mx01-ext.netapp.com with SMTP; 23 Mar 2000 15:20:24 -0000
Received: from tahoe.corp.netapp.com (tahoe.corp.netapp.com [10.10.22.112])
	by herra.corp.netapp.com (8.9.3/8.9.3/NTAP-1.0) with ESMTP id HAA14404;
	Thu, 23 Mar 2000 07:09:29 -0800 (PST)
Received: by tahoe.corp.netapp.com with Internet Mail Service (5.5.2650.21)
	id <HKXRV9S2>; Thu, 23 Mar 2000 07:09:29 -0800
Message-ID: <F6C5585BF0CED311B58D009027C2299C47C03B@tahoe.corp.netapp.com>
From: "Noveck, Dave" <dave.noveck@netapp.com>
To: "'Zachary Amsden'" <zamsden@cthulhu.engr.sgi.com>,
        kvs sivak
	 <kvs_sivak@yahoo.co.uk>
Cc: nfsv4-wg@sunroof.eng.sun.com
Subject: RE: Compound operations : NFS kernel support 
Date: Thu, 23 Mar 2000 07:09:28 -0800
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2650.21)
Content-Type: text/plain;
	charset="iso-8859-1"

 
> Compound operations should be a big advantage for doing 
> GETATTR on all files 
> in a directory, or similar batch tasks.
 
READDIR can do that for all files in a directory.  If you 
have a specific subset that you are interested in and
you know either the names or the handles, then COMPOUND
allows you to get the attributes for all of them.


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 23 12:45:11 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id MAA05054
	for <nfsv4-archive@odin.ietf.org>; Thu, 23 Mar 2000 12:45:10 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA12042;
	Thu, 23 Mar 2000 10:43:42 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id JAA22771;
	Thu, 23 Mar 2000 09:40:19 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2NHe1N18797
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 09:40:01 -0800 (PST)
Received: from lukla.Sun.COM (lukla.Central.Sun.COM [129.147.5.31])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id JAA29359
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 09:40:01 -0800 (PST)
Received: from ausmail1.austin.ibm.com (ausmail1.austin.ibm.com [192.35.232.12])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id KAA08953
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 10:39:56 -0700 (MST)
Received: from netmail3.austin.ibm.com (netmail3.austin.ibm.com [9.53.250.99])
	by ausmail1.austin.ibm.com (8.9.1/8.8.5) with ESMTP id LAA26636
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 11:40:21 -0600
Received: from agueybana.austin.ibm.com (agueybana.austin.ibm.com [9.53.155.20])
        by netmail3.austin.ibm.com (8.8.5/8.8.5) with ESMTP id LAA39654
        for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 11:39:50 -0600
Received: (from ajoglar@localhost) by agueybana.austin.ibm.com (AIX4.3/UCB 8.8.8/8.7-client1.01) id LAA27152; Thu, 23 Mar 2000 11:39:48 -0600
Date: Thu, 23 Mar 2000 11:39:48 -0600 (CST)
From: "Antonio L. Joglar" <ajoglar@austin.ibm.com>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: subscribe
Message-ID: <Pine.A32.3.91.1000323113856.26840A-100000@agueybana.austin.ibm.com>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII



Thanks,
Antonio

========================================================================
Antonio L. Joglar		          phone:  512-838-0674
IBM Corporation			   IBM tie line:  678-0674
RS/6000 Performance		       internet:  ajoglar@austin.ibm.com
11400 Burnet Road, Austin TX 78758     	          ajoglar@us.ibm.com   
========================================================================
Willoughby's Law: When you try to prove to someone that a machine won't 
		  work, it will.



From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 23 15:12:31 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id PAA01228
	for <nfsv4-archive@odin.ietf.org>; Thu, 23 Mar 2000 15:12:31 -0500 (EST)
Received: from engmail2.Eng.Sun.COM ([129.146.1.25])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id NAA29476;
	Thu, 23 Mar 2000 13:10:39 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA28052;
	Thu, 23 Mar 2000 12:10:13 -0800 (PST)
Received: from engmail2.Eng.Sun.COM (engmail2 [129.146.1.25])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2NK9wN18981
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 12:09:58 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail2.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id MAA27948
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 12:09:53 -0800 (PST)
Received: from cs.columbia.edu (cs.columbia.edu [128.59.16.20])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id MAA27603
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 12:09:50 -0800 (PST)
Received: from shekel.mcl.cs.columbia.edu (shekel.mcl.cs.columbia.edu [128.59.18.15])
	by cs.columbia.edu (8.9.3/8.9.3) with ESMTP id PAA26234;
	Thu, 23 Mar 2000 15:09:48 -0500 (EST)
Received: (from ezk@localhost)
	by shekel.mcl.cs.columbia.edu (8.9.3/8.9.3) id PAA27134;
	Thu, 23 Mar 2000 15:09:47 -0500 (EST)
Date: Thu, 23 Mar 2000 15:09:47 -0500 (EST)
Message-Id: <200003232009.PAA27134@shekel.mcl.cs.columbia.edu>
From: Erez Zadok <ezk@cs.columbia.edu>
To: =?iso-8859-1?q?kvs=20sivak?= <kvs_sivak@yahoo.co.uk>
Cc: nfsv4-wg@sunroof.eng.sun.com
Subject: Re: Compound operations : NFS kernel support 
In-reply-to: Your message of "Wed, 22 Mar 2000 11:16:25 GMT."
             <20000322111625.16392.qmail@web3705.mail.yahoo.com> 

In message <20000322111625.16392.qmail@web3705.mail.yahoo.com>, =?iso-8859-1?q?kvs=20sivak?= writes:
> hi,
>  We are trying to implement NFS v4 support in Linux
> Kernel 2.2.

I've worked w/ several VFSs and esp. the Linux vfs since 2.0 and up to the
latest 2.3.99-pre2 (a precursor to 2.4) implementing stackable templates.  I
would suggest that you look at the latest 2.3 VFS as well, b/c it is a lot
cleaner and saner than the 2.2 one; it's also different than 2.2, requiring
some porting work for any 2.2-based file system.  It's easier to work w/ the
latest 2.3 VFS than w/ 2.2.  Also, by the time you get your NFSv4 code
stable, Linux distributions will have probably moved to 2.4.  So it's better
to pay the cost of working w/ the 2.3 VFS now, instead of doing a major port
later.

> It is needed that the VFS interface be coded to
> support any required file system in Linux.Since the
> VFS looks at each operation as an independent one
> there seems to be no advantage in using Compound
> except in adding the extra processing required.

Another good reason to work w/ 2.3 is that you might have a chance to
convince people to make VFS changes such as multi-component lookup support.
Nothing like that will go into 2.2, and if you miss your chance in 2.3,
you'll have to wait several months for 2.5 to start.

Look at linux/fs/namei.c:lookup_dentry() the 2nd argument, "base".  You
might be able to [ab]use to do multi component lookup.  There's also a
"flags" field, which might be used to create a new flag to tell this routine
to do multi-component lookup; the advantage of this would be that you won't
be changing interfaces, just adding a new flag and code that will be
triggered only for that code.

The dentry structure in the linux VFS stores the component name.  You can
use it to reconstruct full paths.  There are kernel routines such as
d_path() and other contributed code (look for dentry_get_path) which do just
that.  So you might be able to use that in your special lookup function with
the right NFS4 RPC.  Although a better implementation would not break and
then reconstruct paths---meaning a VFS change to lookup_dentry().

> for example the namei opreation looks up directories
> at only one level. there is no multi-component
> lookup.This would make it impossoible to use the
> multi-component lookup of NFSv4.Thus the kernel would
> request lookups only for a single component and there
> is no way to determine a full pathname that may be
> sent to the NFS server for multi-component lookup.
> similarly for other procedures too.
> 
> Is this understanding of ours correct ?
> Are there any other means by which compound opreations
> can be used advantageously ?

BTW, if you have linux-VFS questions, you might consider [cross-]posting
them to the linux-fsdevel list.

> K.Sivakumar
> K.V.Subramanian
> 
> ____________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
> or your free @yahoo.ie address at http://mail.yahoo.ie

Good luck.

Erez.


From nfs4-wg-request@sunroof.eng.sun.com  Thu Mar 23 17:10:56 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id RAA10207
	for <nfsv4-archive@odin.ietf.org>; Thu, 23 Mar 2000 17:10:50 -0500 (EST)
Received: from engmail3.Eng.Sun.COM ([129.144.170.5])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA19338;
	Thu, 23 Mar 2000 15:10:17 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail3.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id OAA27132;
	Thu, 23 Mar 2000 14:09:53 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.89.31] (may be forged))
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2NM9cN19043
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 14:09:38 -0800 (PST)
Received: from terra.eng.sun.com (terra.Eng.Sun.COM [129.146.86.99])
	by jurassic.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2NM9bb381179
	for <nfsv4-wg@sunroof.eng.sun.com>; Thu, 23 Mar 2000 14:09:37 -0800 (PST)
Received: (from brent@localhost)
	by terra.eng.sun.com (8.9.3+Sun/8.9.3) id OAA11560
	for nfsv4-wg@sunroof.eng.sun.com; Thu, 23 Mar 2000 14:09:33 -0800 (PST)
Date: Thu, 23 Mar 2000 14:09:33 -0800 (PST)
From: Brent Callaghan <Brent.Callaghan@eng.sun.com>
Message-Id: <200003232209.OAA11560@terra.eng.sun.com>
To: nfsv4-wg@sunroof.eng.sun.com
Subject: Next NFSv4 bakeoff: July 11-13
X-Sun-Charset: US-ASCII


Last October we held an NFSv4 bakeoff in Santa Clara over 3 days.
There 5 vendors brought 6 implementations of v4 which we tested
for interoperability and debugged on a common network.  At Connectathon
a couple of weeks ago, we also took the opportunity to test NFS v4
implementations.

We're currently planning another bakeoff to be held:

	July 11-13 at Techmart in Santa Clara, California.

If you would like to participate, go to the NFSv4 website at:

	http://www.nfsv4.org

and let us know your interest by registering for the event.

	Thanks
		Brent


From nfs4-wg-request@sunroof.eng.sun.com  Sun Mar 26 20:14:43 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id UAA27799
	for <nfsv4-archive@odin.ietf.org>; Sun, 26 Mar 2000 20:14:42 -0500 (EST)
Received: from engmail4.Eng.Sun.COM ([129.144.134.6])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id QAA04201;
	Sun, 26 Mar 2000 16:22:54 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA08331;
	Sun, 26 Mar 2000 15:22:37 -0800 (PST)
Received: from engmail4.Eng.Sun.COM (engmail4 [129.144.134.6])
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2QNMJN20216;
	Sun, 26 Mar 2000 15:22:19 -0800 (PST)
Received: from venus.Sun.COM (venus.EBay.Sun.COM [129.150.69.5])
	by engmail4.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id PAA08319;
	Sun, 26 Mar 2000 15:22:21 -0800 (PST)
Received: from zenith.um.ruda-sl.pl ([195.116.19.97])
	by venus.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id PAA03658;
	Sun, 26 Mar 2000 15:22:19 -0800 (PST)
Received: from dhjejhd (cranston-ip-2-63.dynamic.ziplink.net [209.206.5.63])
	by zenith.um.ruda-sl.pl (8.8.8/8.8.8) with ESMTP id BAA26100;
	Mon, 27 Mar 2000 01:07:28 +0200
Message-Id: <200003262307.BAA26100@zenith.um.ruda-sl.pl>
From: "David" <drtp@newmail.net>
Subject: Make $$$ and Free Travel !
To: doit493o@zenith.um.ruda-sl.pl
X-Mailer: DiffondiCool V3.0 (W95/NT) Delfino Solutions (Build: Jun 14 1998)
Mime-Version: 1.0
Date: Sun, 26 Mar 2000 17:56:05 -0500
Content-Type: text/plain; charset="iso-8859-1"
Content-Transfer-Encoding: 8bit
X-MIME-Autoconverted: from quoted-printable to 8bit by ietf.org id UAA27799

If you could simply advertise an 800# and take orders
 from home could you spend 2 hours per day answering
 your phone?

 Each week our Directors are making $2-3000 using our
 simple system to sell the nation's #1 vacation
 package.

 You too can begin making $1000 on a $1295 sale and get
 free travel. Our reps are signing 3- 5 new members
 weekly.

 YOUR PROSPECTS CALL YOU!EVERYONE LOVES TO TRAVEL AND
 EVERYONE COULD USE SOME EXTRA $$$....

 So if you are serious about making $3000 per week
 starting in the next 30 days call us toll free.

 Call: 1 800 772 4876 toll free

 NOTE: FREE BONUS!! CALL NOW AND RECEIVE QUALITY
 FREE LEADS TO JUMP START YOUR BUSINESS!!!

 This is not a "GET RICH SCHEME" Serious Inquiries Only!!

/////////////////////////////////////////////////////////////////////
///
You can be removed from this list by replying to:
mailto:george4343@yahoo.com?subject=remove
/////////////////////////////////////////////////////////////////////
///





From nfs4-wg-request@sunroof.eng.sun.com  Wed Mar 29 20:51:28 2000
Received: from lukla.Sun.COM (lukla.Sun.COM [192.18.98.31])
	by ietf.org (8.9.1a/8.9.1a) with ESMTP id UAA26882
	for <nfsv4-archive@odin.ietf.org>; Wed, 29 Mar 2000 20:51:27 -0500 (EST)
Received: from engmail1.Eng.Sun.COM ([129.146.1.13])
	by lukla.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id SAA29678;
	Wed, 29 Mar 2000 18:50:56 -0700 (MST)
Received: from sunroof.eng.sun.com (sunroof.Eng.Sun.COM [129.146.168.88])
	by engmail1.Eng.Sun.COM (8.9.1b+Sun/8.9.1/ENSMAIL,v1.6) with ESMTP id RAA10059;
	Wed, 29 Mar 2000 17:50:40 -0800 (PST)
Received: from jurassic.eng.sun.com (jurassic [129.146.83.130] (may be forged))
	by sunroof.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2U1oQN23118
	for <nfsv4-wg@sunroof.eng.sun.com>; Wed, 29 Mar 2000 17:50:26 -0800 (PST)
Received: from jurassic.Eng.Sun.COM (pacrimapp2.Singapore.Sun.COM [129.158.124.41])
	by jurassic.eng.sun.com (8.10.1.Beta0+Sun/8.10.1.Beta0) with ESMTP id e2U1o2G254104;
	Wed, 29 Mar 2000 17:50:05 -0800 (PST)
From: Brent Callaghan <Brent.Callaghan@eng.sun.com>
Message-Id: <200003300150.e2U1o2G254104@jurassic.eng.sun.com>
Date: Wed, 29 Mar 2000 17:49:02 -0800
To: <sob@harvard.edu>, <vern@ee.lbl.gov>
Cc: <nfsv4-wg@sunroof.eng.sun.com>
Reply-To: <Brent.Callaghan@eng.sun.com>
Subject: Summary of NFSv4 WG Meetings @ IETF 47, Adelaide
X-Mailer: Sun NetMail 2.3
MIME-Version: 1.0
Content-Type: text/plain; charset="US-ASCII"
Content-Transfer-Encoding: 7bit
Content-Transfer-Encoding: 7bit



Summary of NFSv4 WG Meetings @ IETF 47, Adelaide
------------------------------------------------

The NFSv4 working group met in two sessions. The first
on Monday evening for 2 1/2 hours and the second on
Tuesday night for 1 hour.  The meetings were attended
by 20 people. The document editor, Spencer Shepler began
with a summary of the changes incorporated in draft 06 of
the protocol description (submitted to the IESG for
Proposed status). He then presented a proposal for a
new informational RFC that describes protocol implementation
choices and targeted at protocol developers.  While the
protocol specification attempts to be implementation-neutral,
the implementation RFC would be advisory in nature and
provide useful implementation hints, e.g. how to handle
mounts on the client, or alternatives if the server
cannot support certain file attributes.

Brent Callaghan gave a short report on the protocol testing
at the recent Connectathon event, followed by Bev Crair of
Sun who presented a list of the binary and source code offerings
that Sun makes available for NFSv4. In particular, the TI-RPC
source code, including RPCSEC_GSS security, is now available
under the SISSL license.

For the rest of the meeting, Brian Pawlowski lead an open
discussion, begining with a question on hardware decoding
of NFS requests.  Constantine Sapuntzakis suggested the
protocol should include features to facilitate location of
large data blocks within the requests or responses.  The
consensus was to leave it alone for now. Neil Brown raised
a question about LIPKEY authentication for server callbacks.
Mike Eisler suggested that the server might provide a public
key for the client to use. There was some discussion of 
whether the changeid attribute should be a random or
incrementing value. Spencer will make this more clear in the spec.

The Tuesday night session contained more open discussion.
Neil Brown expressed enthusiasm for the use of LIPKEY in
a campus environment.  Brian lead a discussion on future
work for the this WG (or a successor WG) and enumerated
some work items before closing the meeting.

--------------------
More complete meeting minutes will follow - including a
pointer to the presentations.
--------------------



