rfc9754.original.xml   rfc9754.xml 
<?xml version='1.0' encoding='utf-8'?> <?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE rfc SYSTEM "rfc2629-xhtml.ent">
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt"?>
<rfc <!DOCTYPE rfc [
category="std" <!ENTITY nbsp "&#160;">
docName="draft-ietf-nfsv4-delstid-08" <!ENTITY zwsp "&#8203;">
ipr="trust200902" <!ENTITY nbhy "&#8209;">
obsoletes="" <!ENTITY wj "&#8288;">
scripts="Common,Latin" ]>
sortRefs="true" <rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="std" docName="draft-ie
submissionType="IETF" tf-nfsv4-delstid-08" number="9754" ipr="trust200902" obsoletes="" updates="" sor
symRefs="true" tRefs="true" submissionType="IETF" consensus="true" symRefs="true" tocDepth="3"
tocDepth="3" tocInclude="true" version="3" xml:lang="en">
tocInclude="true"
version="3" <!-- [rfced] Please review the following questions regarding this
xml:lang="en"> document's title:
a) May we update "Extending" to "Extensions for"? Also, the abstract notes
that this document presents extensions for both opening and delegating files,
but the title only mentions opening of files. Should "Opening of Files" be
updated to "Opening and Delegating Files"?
Original:
Extending the Opening of Files in NFSv4.2
Perhaps:
Extensions for Opening and Delegating Files in NFSv4.2
b) How may we update the document's short title (which appears in the running
header of the PDF output) for consistency with the document title?
Original:
Deleg Stateid
Perhaps:
NFSv4.2 Extensions
Or:
Extending NFSv4.2
-->
<front> <front>
<title abbrev="Deleg Stateid"> <title abbrev="Deleg Stateid">Extending the Opening of Files in NFSv4.2</title
Extending the Opening of Files in NFSv4.2 >
</title> <seriesInfo name="RFC" value="9754"/>
<seriesInfo name="Internet-Draft" value="draft-ietf-nfsv4-delstid-08"/>
<author fullname="Thomas Haynes" initials="T." surname="Haynes"> <author fullname="Thomas Haynes" initials="T." surname="Haynes">
<organization abbrev="Hammerspace">Hammerspace</organization> <organization abbrev="Hammerspace">Hammerspace</organization>
<address> <address>
<email>loghyr@hammerspace.com</email> <email>loghyr@hammerspace.com</email>
</address> </address>
</author> </author>
<author fullname="Trond Myklebust" initials="T." surname="Myklebust"> <author fullname="Trond Myklebust" initials="T." surname="Myklebust">
<organization abbrev="Hammerspace">Hammerspace</organization> <organization abbrev="Hammerspace">Hammerspace</organization>
<address> <address>
<email>trondmy@hammerspace.com</email> <email>trondmy@hammerspace.com</email>
</address> </address>
</author> </author>
<date year="2024" month="October" day="02"/> <date year="2025" month="March"/>
<area>Transport</area> <area>WIT</area>
<workgroup>Network File System Version 4</workgroup> <workgroup>nfsv4</workgroup>
<keyword>NFSv4</keyword> <keyword>NFSv4</keyword>
<!-- [rfced] FYI - We updated "for both the opening and delegating of the file
to the client" as follows. Let us know any concerns.
Original:
This document presents several extensions for both
the opening and delegating of the file to the client.
Updated:
This document presents several extensions for both
opening the file and delegating it to the client.
-->
<abstract> <abstract>
<t> <t>
The Network File System v4 (NFSv4) allows a client to both open a The Network File System v4 (NFSv4) allows a client to both open a
file and be granted a delegation of that file. This delegation file and be granted a delegation of that file. This delegation
provides the client the right to authoritatively cache metadata provides the client the right to authoritatively cache metadata
on the file locally. This document presents several extensions on the file locally. This document presents several extensions
for both the opening and delegating of the file to for both opening the file and delegating it to
the client. This document extends NFSv4.2 (see RFC7863). the client. This document extends NFSv4.2 (see RFC 7863).
</t> </t>
</abstract> </abstract>
<note removeInRFC="true">
<t>
Discussion of this draft takes place
on the NFSv4 working group mailing list (nfsv4@ietf.org),
which is archived at
<eref target="https://mailarchive.ietf.org/arch/browse/nfsv4/"/>.
Working Group information can be found at
<eref target="https://datatracker.ietf.org/wg/nfsv4/about/"/>.
</t>
</note>
</front> </front>
<middle> <middle>
<section anchor="sec_intro" numbered="true" removeInRFC="false" toc="default"> <section anchor="sec_intro" numbered="true" toc="default">
<name>Introduction</name> <name>Introduction</name>
<!-- [rfced] This document contains some sentences that are difficult to
follow because they contain many parentheticals. Below are two examples
(but the document contains more):
Original:
A compound (see Section 2.3 of [RFC8881]) with a GETATTR (see
Section 18.7 of [RFC8881]) or READDIR (see Section 18.23 of
[RFC8881]) can report the file's attributes without bringing the file
online. However, either an OPEN or a LAYOUTGET (see Section 18.43 of
[RFC8881]) might cause the file server to retrieve the archived data
contents, bringing the file online.
...
Either type of
stateid is sufficient to enable the server to treat the file as if it
were open, which allows READ (See Section 18.25 of [RFC8881]), WRITE
(See Section 18.38 of [RFC8881]), LOCK (See Section 18.12 of
[RFC8881]), and LAYOUTGET (see Section 18.50 of [RFC8881]) operations
to proceed.
Many of these sentences include operations (e.g., GETATTR and READ), and the
parentheticals point to sections in RFC 8881 that define those operations. To
improve readability of sentences like this, we recommend adding the operations
to the Definitions section (i.e, Section 1.1) and then omitting the
parentheticals from the sentences.
You may also consider doing the same for other terminology from [RFC8881],
e.g., delegation, stateid, compound, parallel NFS (pNFS), change attribute,
time_metadata attribute, time_access attribute, time_modify attribute, and
NFS4ERR_DELAY.
Let us know your thoughts.
Perhaps (add to Section 1.1; sentence form with no section pointers):
The following operations are used in this document as defined in [RFC8881]:
CB_GETATTR, CLOSE, DELEGRETURN, GETATTR, LAYOUTGET, LOCK, OPEN,
READ, READDIR, SETATTR, and WRITE.
Or (add to Section 1.1; <dl> with section pointers):
The following operations are used in this document as defined in [RFC8881]:
CB_GETATTR: Section 20.1 of [RFC8881]
CLOSE: Section 18.2 of [RFC8881]
DELEGRETURN: Section 18.6 of [RFC8881]
GETATTR: Section 18.7 of [RFC8881]
LAYOUTGET: Section 18.43 of [RFC8881]
LOCK: Section 18.10 of [RFC8881]
OPEN: Section 18.16.1 of [RFC8881]
READ: Section 18.22 of [RFC8881]
READDIR: Section 18.23 of [RFC8881]
SETATTR: Section 18.30 of [RFC8881]
WRITE: Section 18.32 of [RFC8881]
-->
<t> <t>
In the Network File System version4 (NFSv4), a client may be granted In the Network File System version 4 (NFSv4), a client may be granted a
a delegation for a file (see Section 1.8.4 of <xref target="RFC8881" delegation for a file (see <xref target="RFC8881" section="1.8.4"
format="default" sectionFormat="of"/>). This allows the client to act as the sectionFormat="of"/>). This allows the client to act as the authority for
authority for the file's metadata and data. This document presents the file's data and metadata. This document presents a number of
a number of extensions which enhance the functionality of opens and extensions that enhance the functionality of opens and delegations. These
delegations. These allow the client to: allow the client to:
</t> </t>
<!-- [rfced] We moved the parenthetical to appear after "delegation stateid"
in this sentence. Section 8.2 of RFC 8881 defines stateids and mentions
both "delegation stateid" and "OPEN stateid". Let us know any concerns.
Original:
* during the OPEN procedure, retrieve either the open stateid (see
Section 8.2 of [RFC8881]) or delegation stateid, but not both
simultaneously.
Updated:
* retrieve either the open or delegation stateid (see
Section 8.2 of [RFC8881]), but not both simultaneously, during the OPEN
procedure; and
-->
<ul spacing="normal"> <ul spacing="normal">
<li> <li>detect an offline file, which may require significant effort to obtain;<
detect an offline file, which may require significant effort to obtain. /li>
</li>
<li> <li>determine which extensions of OPEN flags (see <xref target="RFC8881"
determine which extensions of OPEN (see Section 18.16 of <xref section="18.16" sectionFormat="of"/>) are supported by the server;</li>
target="RFC8881" format="default" sectionFormat="of"/>) flags are
supported by the server. <li>retrieve either the open or delegation stateid (see <xref target="RFC888
</li> 1"
<li> section="8.2" sectionFormat="of"/>), but not
during the OPEN procedure, retrieve either the open stateid both simultaneously, during the OPEN procedure; and</li>
(see Section 8.2 of <xref target="RFC8881"
format="default" sectionFormat="of"/>) or <li>cache both the access and modify timestamps, thereby reducing the
delegation stateid, but not both simultaneously. frequency with which the client must query the server for this
</li> information.
<li>
cache both the access and modify timestamps, thereby reducing
the frequency with which the client must query the server for
this information.
</li> </li>
</ul> </ul>
<t> <t>
Using the process detailed in <xref target="RFC8178" format="default" Using the process detailed in <xref target="RFC8178" format="default"
sectionFormat="of"/>, the revisions in this document become an sectionFormat="of"/>, the revisions in this document become an extension
extension of NFSv4.2 <xref target="RFC7862" format="default" of NFSv4.2 <xref target="RFC7862" format="default"
sectionFormat="of"/>. They are built on top of the external data sectionFormat="of"/>. They are built on top of the External Data
representation (XDR) <xref target="RFC4506" format="default" Representation (XDR) <xref target="RFC4506" format="default"
sectionFormat="of"/> generated from <xref target="RFC7863" sectionFormat="of"/> generated from <xref target="RFC7863"
format="default" sectionFormat="of"/>. format="default" sectionFormat="of"/>.
</t> </t>
<section anchor="sec_defs" numbered="true" removeInRFC="false" toc="default"> <section anchor="sec_defs" numbered="true" toc="default">
<name>Definitions</name> <name>Definitions</name>
<t>This document uses the following terminology:</t>
<dl newline="false" spacing="normal"> <dl newline="false" spacing="normal">
<dt>offline file:</dt> <dt>offline file:</dt>
<dd> <dd>
A file which exists on a device which is not connected to the A file that exists on a device that is not connected to the
server. There is typically a cost associated with bringing the server. There is typically a cost associated with bringing the
file to an online status. Historically this would be a file on file to an online status. Historically, this would be a file on
tape media and the cost would have been finding and loading the tape media, and the cost would have been finding and loading the
tape. A more modern interpretation is that the file is in the tape. A more modern interpretation is that the file is in the
cloud and the cost is a monetary one in downloading the file. cloud, and the cost is a monetary one in downloading the file.
</dd> </dd>
<dt>proxy:</dt> <dt>proxy:</dt>
<dd> <dd>
Proxying of attributes occurs when a client has the authority, as The proxying of attributes occurs when a client has the authority, as
granted by the appropriate delegation, to represent the attributes granted by the appropriate delegation, to represent the attributes
normally maintained by the server. For read attributes, this normally maintained by the server. For read attributes, this
occurs when the client has either a read or write delegations occurs when the client has either a read or write delegation
for the file. For write attributes, this occurs when the client for the file. For write attributes, this occurs when the client
has a write delegation for the file. The client having this has a write delegation for the file. The client having this
authority is the "proxy" for those attributes. authority is the "proxy" for those attributes.
</dd> </dd>
</dl> </dl>
</section> </section>
<section numbered="true" removeInRFC="false" toc="default"> <section numbered="true" toc="default">
<name>Requirements Language</name> <name>Requirements Language</name>
<t> <t>
The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>", The key words "<bcp14>MUST</bcp14>", "<bcp14>MUST NOT</bcp14>",
"<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL "<bcp14>REQUIRED</bcp14>", "<bcp14>SHALL</bcp14>", "<bcp14>SHALL NOT</bcp14>
NOT</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>", ",
"<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>", "<bcp14>SHOULD</bcp14>", "<bcp14>SHOULD NOT</bcp14>",
"<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this "<bcp14>RECOMMENDED</bcp14>", "<bcp14>NOT RECOMMENDED</bcp14>",
document are to be interpreted as described in BCP&nbsp;14 <xref "<bcp14>MAY</bcp14>", and "<bcp14>OPTIONAL</bcp14>" in this document are to
target="RFC2119" format="default" sectionFormat="of"/> <xref be
target="RFC8174" format="default" sectionFormat="of"/> when, interpreted as described in BCP&nbsp;14 <xref target="RFC2119"/> <xref
and only when, they appear in all capitals, as shown here. target="RFC8174"/> when, and only when, they appear in all capitals, as
</t> shown here.
</t>
</section> </section>
</section> </section>
<section anchor="sec_offline" numbered="true" removeInRFC="false" toc="default"> <section anchor="sec_offline" numbered="true" toc="default">
<name>Offline Files</name> <name>Offline Files</name>
<t> <t>
If a file is offline, then the server has immediate high-performance If a file is offline, then the server has immediate high-performance
access to the file's attributes, but not to the file's content. access to the file's attributes, but not to the file's content.
The action of retrieving the data content is expensive, to the extent The action of retrieving the data content is expensive, to the extent
that the content should only be retrieved if it is going to be used. that the content should only be retrieved if it is going to be used.
For example, a graphical file manager (such as OSX's Finder) may For example, a graphical file manager (such as Finder in Mac OS X) may
want to access the beginning of the file to preview it for an user want to access the beginning of the file to preview it for a user
who is hovering their pointer over the file name and not accessing who is hovering their pointer over the file name and not accessing
it otherwise. If the file is retrieved, it will most likely either it otherwise. If the file is retrieved, it will most likely be either
be immediately thrown away or returned. immediately thrown away or returned.
</t> </t>
<!-- [rfced] We updated the section numbers below for accuracy with RFC 8881.
Please review and confirm that these changes are correct.
Original:
Either type of stateid is sufficient to enable the server to treat the file
as if it were open, which allows READ (See Section 18.25 of [RFC8881]),
WRITE (See Section 18.38 of [RFC8881]), LOCK (See Section 18.12 of
[RFC8881]), and LAYOUTGET (see Section 18.50 of [RFC8881]) operations to
proceed.
Updated:
Either type of stateid is sufficient to enable the server to treat the file
as if it were open, which allows READ (see Section 18.22 of [RFC8881]), WRITE
(see Section 18.32 of [RFC8881]), LOCK (see Section 18.10 of
[RFC8881]), and LAYOUTGET (see Section 18.43 of [RFC8881]) operations
to proceed.
-->
<!-- [rfced] Is a word missing in "filehandle to the data content"?
Original:
For non-parallel NFS (pNFS)
systems (see Section 12 of [RFC8881]) , the OPEN operation requires a
filehandle to the data content.
Perhaps:
For non-parallel NFS
systems (see Section 12 of [RFC8881]), the OPEN operation requires a
filehandle to retrieve the data content.
-->
<t> <t>
A compound (see Section 2.3 of <xref target="RFC8881" format="default" A compound (see <xref target="RFC8881" section="2.3" sectionFormat="of"/>)
sectionFormat="of"/>) with a GETATTR (see Section 18.7 of <xref with a GETATTR (see <xref target="RFC8881" section="18.7"
target="RFC8881" format="default" sectionFormat="of"/>) or READDIR sectionFormat="of"/>) or READDIR (see <xref target="RFC8881"
(see Section 18.23 of <xref target="RFC8881" format="default" section="18.23" sectionFormat="of"/>) can report the file's attributes
sectionFormat="of"/>) can report the file's attributes without without bringing the file online. However, either an OPEN or a LAYOUTGET
bringing the file online. However, either an OPEN or a LAYOUTGET (see <xref target="RFC8881" section="18.43" sectionFormat="of"/>) might
(see Section 18.43 of <xref target="RFC8881" format="default" cause the file server to retrieve the archived data contents, bringing the
sectionFormat="of"/>) might cause the file server to retrieve the file online. For non-parallel NFS systems (see <xref
archived data contents, bringing the file online. For non-parallel target="RFC8881" section="12" sectionFormat="of"/>), the OPEN operation
NFS (pNFS) systems (see Section 12 of <xref target="RFC8881" requires a filehandle to the data content. For parallel NFS (pNFS) systems,
format="default" sectionFormat="of"/>) , the OPEN operation the
requires a filehandle to the data content. For pNFS systems, the filehandle retrieved from an OPEN need not cause the data content to be
filehandle retrieved from an OPEN need not cause the data content retrieved. However, when the LAYOUTGET operation is processed, a layout-type
to be retrieved. But when the LAYOUTGET operation is processed, -specific mapping
a layout type specific mapping will cause the data content to be will cause the data content to be retrieved from offline
retrieved from offline storage. storage.
</t> </t>
<t> <t>
If the client is not aware that the file is offline, it might If the client is not aware that the file is offline, it might
inadvertently open the file to determine what type of file it inadvertently open the file to determine what type of file it
is accessing. By interrogating the new attribute fattr4_offline, is accessing. By interrogating the new attribute fattr4_offline,
a client can predetermine the availability of the file, avoiding the a client can predetermine the availability of the file, avoiding the
need to open it at all. Being offline might also involve situations need to open it at all. Being offline might also involve situations
in which the file is archived in the cloud, i.e., there can be an in which the file is archived in the cloud, i.e., there can be an
expense in both retrieving the file to bring online and in sending expense in both retrieving the file to bring it online and in sending
the file back to offline status. the file back to offline status.
</t> </t>
<section anchor="ssec_offline_attr" numbered="true" removeInRFC="false" toc="d <section anchor="ssec_offline_attr" numbered="true" toc="default">
efault"> <name>XDR for the Offline Attribute</name>
<name>XDR for Offline Attribute</name>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="xdr" markers="true"><![CDATA[
/// ///
/// typedef bool fattr4_offline; /// typedef bool fattr4_offline;
/// ///
/// ///
/// const FATTR4_OFFLINE = 83; /// const FATTR4_OFFLINE = 83;
/// ///
]]> ]]></sourcecode>
</sourcecode>
</section> </section>
</section> </section>
<section anchor="ssec_open_xor_xdr" numbered="true" removeInRFC="false" toc="def ault"> <section anchor="ssec_open_xor_xdr" numbered="true" toc="default">
<name>Determining OPEN Feature Support</name> <name>Determining OPEN Feature Support</name>
<!-- [rfced] May we update "[RFC8178] (see Section 4.4.2)" as follows? Or do
you prefer the original?
Original:
[RFC8178] (see Section 4.4.2) allows for extending a particular minor
version of the NFSv4 protocol without requiring the definition of a
new minor version.
Perhaps:
Section 4.4.2 of [RFC8178] allows for extending a particular minor
version of the NFSv4 protocol without requiring the definition of a
new minor version.
-->
<t> <t>
<xref target="RFC8178" format="default" sectionFormat="of"/> <xref target="RFC8178" format="default" sectionFormat="of"/> (see Section <x
(see Section 4.4.2) allows for extending a particular minor ref
version of the NFSv4 protocol without requiring the definition target="RFC8178" section="4.4.2" sectionFormat="bare"/>) allows for
of a new minor version. The client can probe the capabilities of extending a particular minor version of the NFSv4 protocol without
the server and based on the result, determine if both it and the requiring the definition of a new minor version. The client can
server support optional features not previously specified as part probe the capabilities of the server and, based on the result, determine if
of the minor version. both it and the server support optional features not previously specified
as part of the minor version.
</t> </t>
<t> <t>
The fattr4_open_arguments attribute is a new XDR extension which The fattr4_open_arguments attribute is a new XDR extension that
provides helpful support when the OPEN procedure is extended in provides helpful support when the OPEN procedure is extended in
such a fashion. It models all of the parameters via bitmap4 data such a fashion. It models all of the parameters via bitmap4 data
structures, which allows for the addition of a new flag to any of structures, which allows for the addition of a new flag to any of
the OPEN arguments (see Section 18.16.1 of <xref target="RFC8881" the OPEN arguments (see <xref target="RFC8881" section="18.16.1" sectionForm
format="default" sectionFormat="of"/>). The scope of this attribute at="of"/>). The scope of this attribute
applies to all objects with a matching fsid. applies to all objects with a matching fsid.
</t> </t>
<t> <t>
Two new flags are provided: Two new flags are provided:
</t> </t>
<ul spacing="normal"> <ul spacing="normal">
<li> <li>
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION
(see <xref target="sec_open_xor" format="default" sectionFormat="of"/>) (see <xref target="sec_open_xor" format="default" sectionFormat="of"/>)
</li> </li>
<li> <li>
OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS
(see <xref target="sec_proxy" format="default" sectionFormat="of"/>) (see <xref target="sec_proxy" format="default" sectionFormat="of"/>)
</li> </li>
</ul> </ul>
<t> <t>
Subsequent extensions can use this framework when introducing new Subsequent extensions can use this framework when introducing new
<bcp14>OPTIONAL</bcp14> functionality to OPEN, by creating a new <bcp14>OPTIONAL</bcp14> functionality to OPEN by creating a new
flag for each <bcp14>OPTIONAL</bcp14> parameter. flag for each <bcp14>OPTIONAL</bcp14> parameter.
</t> </t>
<t> <t>
Since fattr4_open_arguments is a <bcp14>RECOMMENDED</bcp14> attribute, if th e Since fattr4_open_arguments is a <bcp14>RECOMMENDED</bcp14> attribute, if th e
server informs the client via NFS4ERR_ATTRNOTSUPP that it does not support t his new server informs the client via NFS4ERR_ATTRNOTSUPP that it does not support t his new
attribute, the client <bcp14>MUST</bcp14> take this to mean that attribute, the client <bcp14>MUST</bcp14> take this to mean that
the additional new <bcp14>OPTIONAL</bcp14> functionality to OPEN the additional new <bcp14>OPTIONAL</bcp14> functionality to OPEN
is also not supported. is also not supported.
</t> </t>
<t> <t>
Some other concerns are how to process both currently Some other concerns are how to process both currently
<bcp14>REQUIRED</bcp14> flags and <bcp14>OPTIONAL</bcp14> flags <bcp14>REQUIRED</bcp14> flags and <bcp14>OPTIONAL</bcp14> flags that
which become <bcp14>REQUIRED</bcp14> in the future. The server become <bcp14>REQUIRED</bcp14> in the future. The server
<bcp14>MUST</bcp14> mark <bcp14>REQUIRED</bcp14> flags as being supported. <bcp14>MUST</bcp14> mark <bcp14>REQUIRED</bcp14> flags as being supported.
Note that these flags <bcp14>MUST</bcp14> only change from Note that these flags <bcp14>MUST</bcp14> only change from
<bcp14>OPTIONAL</bcp14> to <bcp14>REQUIRED</bcp14> when the NFSv4 <bcp14>OPTIONAL</bcp14> to <bcp14>REQUIRED</bcp14> when the NFSv4 minor
minor version is incremented. version is incremented.
</t> </t>
<section anchor="ssec_open_xdr" numbered="true" removeInRFC="false" toc="defau lt"> <section anchor="ssec_open_xdr" numbered="true" toc="default">
<name>XDR for Open Arguments</name> <name>XDR for Open Arguments</name>
<sourcecode name="" type="" markers="true"><![CDATA[
<sourcecode name="" type="xdr" markers="true"><![CDATA[
/// ///
/// struct open_arguments4 { /// struct open_arguments4 {
/// bitmap4 oa_share_access; /// bitmap4 oa_share_access;
/// bitmap4 oa_share_deny; /// bitmap4 oa_share_deny;
/// bitmap4 oa_share_access_want; /// bitmap4 oa_share_access_want;
/// bitmap4 oa_open_claim; /// bitmap4 oa_open_claim;
/// bitmap4 oa_create_mode; /// bitmap4 oa_create_mode;
/// }; /// };
/// ///
/// ///
skipping to change at line 332 skipping to change at line 473
/// % * Determine what OPEN supports. /// % * Determine what OPEN supports.
/// % */ /// % */
/// const FATTR4_OPEN_ARGUMENTS = 86; /// const FATTR4_OPEN_ARGUMENTS = 86;
/// ///
/// ///
/// const OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION = 0x200000; /// const OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION = 0x200000;
/// ///
/// ///
/// const OPEN4_RESULT_NO_OPEN_STATEID = 0x00000010; /// const OPEN4_RESULT_NO_OPEN_STATEID = 0x00000010;
/// ///
]]> ]]></sourcecode>
</sourcecode>
</section> </section>
</section> </section>
<section anchor="sec_open_xor" numbered="true" removeInRFC="false" toc="default" <section anchor="sec_open_xor" numbered="true" toc="default">
> <name>OPEN Grants Only One of Open or Delegation Stateid</name>
<name>OPEN grants only one of Open or Delegation Stateid</name>
<t> <!-- [rfced] May we update "only one of" in the title of Section 4 as follows?
The OPEN (See Section 18.16 of <xref target="RFC8881" format="default"
sectionFormat="of"/>) procedure returns an open stateid to the Original:
client to reference the state of the file. The client could also 4. OPEN grants only one of Open or Delegation Stateid
request a delegation stateid in the OPEN arguments. The file can
be considered open for the client as long as the count of open Perhaps:
and delegated stateids is greater than 0. Either type of stateid 4. OPEN Grants Either an Open or a Delegation Stateid
is sufficient to enable the server to treat the file as if it were -->
open, which allows READ (See Section 18.25 of <xref target="RFC8881"
format="default" sectionFormat="of"/>), WRITE (See Section 18.38 <t>
of <xref target="RFC8881" format="default" sectionFormat="of"/>), The OPEN (see <xref target="RFC8881" section="18.16" sectionFormat="of"/>)
LOCK (See Section 18.12 of <xref target="RFC8881" format="default" procedure returns an open stateid to the client to reference the state of
sectionFormat="of"/>), and LAYOUTGET (see Section 18.50 of <xref the file. The client could also request a delegation stateid in the OPEN
target="RFC8881" format="default" sectionFormat="of"/>) operations arguments. The file can be considered open for the client as long as the
to proceed. If the client gets both an open and a delegation stateid count of open and delegated stateids is greater than 0. Either type of
as part of the OPEN, then it has to return them both to the server. A furth stateid is sufficient to enable the server to treat the file as if it were
er open, which allows READ (see <xref target="RFC8881" section="18.22"
consideration is that during each operation, the client can send sectionFormat="of"/>), WRITE (see <xref target="RFC8881" section="18.32"
a costly GETATTR (See Section 18.7 of <xref target="RFC8881" sectionFormat="of"/>), LOCK (see <xref target="RFC8881" section="18.10"
format="default" sectionFormat="of"/>). sectionFormat="of"/>), and LAYOUTGET (see <xref target="RFC8881"
section="18.43" sectionFormat="of"/>) operations to proceed. If the client
gets both an open and a delegation stateid as part of the OPEN, then it
has to return them both to the server. A further consideration is that
during each operation, the client can send a costly GETATTR (see <xref
target="RFC8881" section="18.7" sectionFormat="of"/>).
</t> </t>
<t> <t>
If the client knows that the server supports the If the client knows that the server supports the
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag (as determined by an OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag (as determined by an
earlier GETATTR operation which queried for the fattr4_open_arguments earlier GETATTR operation that queried for the fattr4_open_arguments
attribute), then the client can supply that flag during the OPEN attribute), then the client can supply that flag during the OPEN and
and only get either an open or delegation stateid. get either an open or a delegation stateid.
</t> </t>
<!-- [rfced] We do not see "OPEN4resok.stateid" in Section 18.16.2 of RFC 8811.
Should this be updated to "OPEN4resok"?
Original:
The open stateid field,
OPEN4resok.stateid (see Section 18.16.2 of [RFC8881]), MUST be set to
the special all zero stateid in this case.
Perhaps:
The open stateid field,
OPEN4resok (see Section 18.16.2 of [RFC8881]), MUST be set to
the special all-zero stateid in this case.
-->
<t> <t>
The client is already prepared to not get a delegation The client is already prepared to not get a delegation
stateid even if requested. In order to not send an open stateid, even if requested. In order to not send an open
stateid, the server <bcp14>MUST</bcp14> indicate that fact with the result stateid, the server <bcp14>MUST</bcp14> indicate that fact with the result
flag of OPEN4_RESULT_NO_OPEN_STATEID. The open stateid field, flag of OPEN4_RESULT_NO_OPEN_STATEID. The open stateid field,
OPEN4resok.stateid (see Section 18.16.2 of <xref target="RFC8881" OPEN4resok.stateid (see <xref target="RFC8881" section="18.16.2" sectionForm
format="default" sectionFormat="of"/>), <bcp14>MUST</bcp14> be set to the at="of"/>), <bcp14>MUST</bcp14> be set to the
special all zero stateid in this case. special all-zero stateid in this case.
</t> </t>
<t>
Note that the OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag <!-- [rfced] Would it be helpful to update "then the server has three options"
is a hint. The server might return both stateids. Consider in one of the following ways?
the scenario in which the client opens a file read-only (with
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set) and gets only Original:
an open stateid. If the client then opens the file for read-write If the client then opens the file for read-write (with
(with OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set), then OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set), then the server has
the server has three options: three options:
1. Only an open stateid with the correct seqid.
2. Only a delegation stateid with the open stateid now having an
incorrect seqid as it needs to be upgraded.
3. Both an open (which will be upgraded) and a delegation stateid.
Perhaps:
If the client then opens the file for read-write (with
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set), the server
can return one of the following three options:
1. Only an open stateid with the correct seqid.
2. Only a delegation stateid with the open stateid now having an
incorrect seqid as it needs to be upgraded.
3. Both an open stateid (which will be upgraded) and a delegation stateid.
Or:
If the client then opens the file for read-write (with
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set), then the server has
three options. The server can return:
1. only an open stateid with the correct seqid,
2. only a delegation stateid (with the open stateid now having an
incorrect seqid as it needs to be upgraded), or
3. both an open stateid (which will be upgraded) and a delegation
stateid.
-->
<t>
Note that the OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag is a
hint. The server might return both stateids. Consider the scenario in
which the client opens a file for read-only (with
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set) and only gets an open
stateid. If the client then opens the file for read-write (with
OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION set), then the server has
three options:
</t> </t>
<ol> <ol>
<li>Only an open stateid with the correct seqid.</li> <li>Only an open stateid with the correct seqid.</li>
<li>Only a delegation stateid with the open stateid now having an incorrect seqid as it needs to be upgraded.</li> <li>Only a delegation stateid with the open stateid now having an incorrect seqid as it needs to be upgraded.</li>
<li>Both an open (which will be upgraded) and a delegation stateid.</li> <li>Both an open stateid (which will be upgraded) and a delegation stateid.< /li>
</ol> </ol>
<t> <t>
In this scenario, returning just a delegation stateid would hide information In this scenario, returning just a delegation stateid would hide
from the client. If the client already has an open stateid, then the information from the client. If the client already has an open stateid,
server <bcp14>SHOULD</bcp14> ignore the OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DEL then the server <bcp14>SHOULD</bcp14> ignore the
EGATION OPEN4_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag and return both the open
flag and return both the open and delegation stateids. and delegation stateids.
</t> </t>
<section anchor="delstid_analysis" numbered="true" removeInRFC="false" toc="de
fault"> <section anchor="delstid_analysis" numbered="true" toc="default">
<name>Implementation Experience</name> <name>Implementation Experience</name>
<t> <t>
The CLOSE operation (see Section The CLOSE operation (see <xref target="RFC8881" section="18.2" sectionForm
18.2 of <xref target="RFC8881" format="default" sectionFormat="of"/>) at="of"/>)
neither explicitly nor implicitly releases any neither explicitly nor implicitly releases any
delegation stateids. This is not symmetrical with the OPEN operation, delegation stateids. This is not symmetrical with the OPEN operation,
which can grant both an open and a delegation stateid. This specification which can grant both an open and a delegation stateid. This specification
could have tried to extend the CLOSE operation to release both could have tried to extend the CLOSE operation to release both
stateids, but implementation experience shows that is more costly stateids, but implementation experience shows that is more costly
than the approach which has been proposed. than the approach that has been proposed.
</t> </t>
<!-- [rfced] Please review "That takes" in the second sentence below. Would
updating to "This involves" be an improvement? Also, would it be helpful
to update the long third sentence to be a bulleted list?
Original:
Consider a small workload of creating a file with content. That
takes 3 synchronous and 1 asynchronous operations with existing
implementations. The first synchronous one has to OPEN the file, the
second synchronous one performs the WRITE to the file, the third
synchronous one has to CLOSE the file, and the fourth asynchronous
one uses DELEGRETURN (see Section 18.6 of [RFC8881]) to return the
delegation stateid.
Perhaps:
Consider a small workload of creating a file with content. This
involves three synchronous operations and one asynchronous operation with exi
sting
implementations:
* The first synchronous operation has to OPEN the file.
* The second synchronous operation performs the WRITE to the file.
* The third synchronous operation has to CLOSE the file.
* The asynchronous operation uses DELEGRETURN (see Section 18.6 of [RFC8881])
to return
the delegation stateid.
-->
<t> <t>
Consider a small workload of creating a file with content. That Consider a small workload of creating a file with content. That takes thre
takes 3 synchronous and 1 asynchronous operations with existing e
implementations. The first synchronous one has to OPEN the file, synchronous operations and one asynchronous operation with existing
the second synchronous one performs the WRITE to the file, the third implementations.
synchronous one has to CLOSE the file, and the fourth asynchronous The first synchronous operation has to OPEN the file;
one uses DELEGRETURN (see Section the second synchronous one performs the WRITE to the file;
18.6 of <xref target="RFC8881" format="default" sectionFormat="of"/>) the third synchronous one has to CLOSE the file; and
to return the delegation stateid. the asynchronous one uses DELEGRETURN (see <xref target="RFC8881"
section="18.6" sectionFormat="of"/>) to return the delegation stateid.
</t> </t>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="" markers="true"><![CDATA[
SEQ PUTFH OPEN GETFH GETATTR SEQ PUTFH OPEN GETFH GETATTR
SEQ PUTFH WRITE GETATTR SEQ PUTFH WRITE GETATTR
SEQ PUTFH CLOSE SEQ PUTFH CLOSE
... ...
SEQ PUTFH DELEGRETURN SEQ PUTFH DELEGRETURN
]]> ]]></sourcecode>
</sourcecode>
<t> <t>
With the proposed approach of setting the With the proposed approach of setting the
OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag during OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION flag during
the OPEN, the number of operations is always 3. The first two the OPEN, the number of operations is always three. The first two
compounds are still synchronous, but the last is asynchronous. I.e., compounds are still synchronous, but the last is asynchronous. That is,
since the client no longer has to send a CLOSE operation, it can since the client no longer has to send a CLOSE operation, it can
delay the DELEGRETURN until either the server requests it back delay the DELEGRETURN until either the server requests it back
via delegation recall or garbage collection causes the client to via delegation recall or garbage collection causes the client to
return the stateid. return the stateid.
</t> </t>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="" markers="true"><![CDATA[
SEQ PUTFH OPEN(OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION) SEQ PUTFH OPEN(OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION)
GETFH GETATTR GETFH GETATTR
SEQ PUTFH WRITE GETATTR SEQ PUTFH WRITE GETATTR
... ...
SEQ PUTFH DELEGRETURN SEQ PUTFH DELEGRETURN
]]> ]]></sourcecode>
</sourcecode>
<t> <t>
This approach reduces the cost of synchronous operations by 33% This approach reduces the cost of synchronous operations by 33%
and the total number of operations by 25%. Contrast that against and the total number of operations by 25%. Contrast that with
the alternative proposal of having CLOSE return both stateids, the alternative proposal of having CLOSE return both stateids,
which would not reduce the number of synchronous operations. which would not reduce the number of synchronous operations.
</t> </t>
</section> </section>
</section> </section>
<section anchor="sec_proxy" numbered="true" removeInRFC="false" toc="default"> <section anchor="sec_proxy" numbered="true" toc="default">
<name>Proxying of Times</name> <name>Proxying of Times</name>
<t>
<!-- [rfced] For readability, may we adjust the text below as follows? In the
suggested text below, we moved the phrase "to notify...values" to the
beginning of the sentence and used a semicolon to split up the long
sentence.
Original:
While the client could send a compound of the form: SEQ, PUTFH,
SETATTR (time_modify | time_access), DELEGRETURN, to notify the
server of the proxied values, that SETATTR (see Section 18.30 of
[RFC8881]) operation would cause either or both of change (see
Section 5.8.1.4 of [RFC8881]) or time_metadata (see Section 5.8.2.42
of [RFC8881]) to be modified to the current time on the server.
Perhaps:
To notify the server of the proxied values, the client could send a
compound of the form SEQ, PUTFH, SETATTR (time_modify |
time_access), DELEGRETURN; however, the SETATTR operation (see
Section 18.30 of [RFC8881]) would cause either or both of the change
attribute (see Section 5.8.1.4 of [RFC8881]) or time_metadata
attribute (see Section 5.8.2.42 of [RFC8881]) to be modified to the
current time on the server.
-->
<!-- [rfced] Is "pass these times up" correct, or should this be updated to
"pass on these times"?
Original:
As a result, it can not pass
these times up to an application expecting POSIX compliance, as is
often necessary for correct operation.
Perhaps:
As a result, it cannot pass on
these times to an application expecting POSIX compliance, as is
often necessary for correct operation.
-->
<t>
When a client is granted a write delegation on a file, it becomes the When a client is granted a write delegation on a file, it becomes the
authority for the file contents and associated attributes. If the authority for the file contents and associated attributes. If the server
server queries the client as to the state of the file via a CB_GETATTR queries the client as to the state of the file via a CB_GETATTR (see <xref
(see Section 20.1 of <xref target="RFC8881" format="default" target="RFC8881" section="20.1" sectionFormat="of"/>), then according to
sectionFormat="of"/>), then, according to the unextended NFSv4 the unextended NFSv4 protocol, it can only determine the size of the file
protocol, it can only determine the size of the file and the change and the change attribute. In the case of the client holding the
attribute. In the case of the client holding the delegation, it has delegation, it has the current values of the access and modify times.
the current values of the access and modify times. There is no way There is no way that other clients can have access to these values. To
that other clients can have access to these values. While the notify the server of the proxied values, the client could send a compound
client could send a compound of the form: SEQ, PUTFH, of the form SEQ, PUTFH, SETATTR (time_modify | time_access), DELEGRETURN;
SETATTR (time_modify | time_access), DELEGRETURN, to notify however, the SETATTR operation (see <xref target="RFC8881" section="18.30"
the server of the proxied values, that SETATTR (see Section 18.30 of <xref t sectionFormat="of"/>) would cause either or both of the change attribute
arget="RFC8881" format="default" (see <xref target="RFC8881" sectionFormat="of" section="5.8.1.4"/>) or
sectionFormat="of"/>) operation would time_metadata attribute (see <xref target="RFC8881" section="5.8.2.42"
cause either or both of change (see Section 5.8.1.4 of <xref target="RFC8881 sectionFormat="of"/>) to be modified to the current time on the server.
" format="default"
sectionFormat="of"/>) or time_metadata (see Section 5.8.2.42 of <xref target There is no current provision to obtain these values before
="RFC8881" format="default" delegation return using CB_GETATTR. As a result, it cannot pass these
sectionFormat="of"/>) to times up to an application expecting POSIX compliance, as is often
be modified to the current time on the server. necessary for correct operation.
There is no current provision to obtain these values before delegation
return using CB_GETATTR. As a result, it can not pass these times up
to an application expecting POSIX compliance, as is often necessary
for correct operation.
</t> </t>
<t> <t>
With the addition of the new flag: With the addition of the new
OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS, the client and server can OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS flag, the client and server can
negotiate that the client will be the authority for these values and negotiate that the client will be the authority for these values, and upon
upon return of the delegation stateid via a DELEGRETURN (see section return of the delegation stateid via a DELEGRETURN (see <xref
18.6 of <xref target="RFC8881" format="default" sectionFormat="of"/>), target="RFC8881" section="18.6" sectionFormat="of"/>), the times will be
the times will be passed back to the server. If the server is queried passed back to the server. If the server is queried by another client for
by another client for either the size or the times, it will need to either the size or the times, it will need to use a CB_GETATTR to query
use a CB_GETATTR to query the client which holds the delegation the client that holds the delegation (see <xref target="RFC8881"
(see Section 20.1 of <xref target="RFC8881" format="default" section="20.1" sectionFormat="of"/>).
sectionFormat="of"/>).
</t> </t>
<!-- [rfced] May we update this sentence as follows to improve clarity? Note
that the suggested text a) clarifies what "it" refers to, b) revises
"fattr4_time_deleg_access attribute and fattr4_time_deleg_modify
attribute changes", and c) updates "or reject" to ", or it MUST reject".
Original:
Further, when it gets a SETATTR with those attributes being set, then
it MUST accept those fattr4_time_deleg_access attribute and
fattr4_time_deleg_modify attribute changes and derive the change time
or reject the changes with NFS4ERR_DELAY (see Section 15.1.1.3 of
[RFC8881]).
Perhaps:
Further, when a server gets a SETATTR with those attributes set, then
it MUST accept those changes in the fattr4_time_deleg_access and
fattr4_time_deleg_modify attributes and derive the change time,
or it MUST reject the changes with NFS4ERR_DELAY (see Section 15.1.1.3 of
[RFC8881]).
-->
<t> <t>
If a server informs the client via the fattr4_open_arguments attribute If a server informs the client via the fattr4_open_arguments attribute
that it supports OPEN_ARGS_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS and that it supports OPEN_ARGS_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS and it
it returns a valid delegation stateid for an OPEN operation which returns a valid delegation stateid for an OPEN operation that sets the
sets the OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS flag, then it OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS flag, then it <bcp14>MUST</bcp14>
<bcp14>MUST</bcp14> query the client via a CB_GETATTR for the query the client via a CB_GETATTR for the fattr4_time_deleg_access
fattr4_time_deleg_access (see <xref target="ssec_proxy_xdr"/>) attribute (see <xref target="ssec_proxy_xdr"/>) and the
attribute and fattr4_time_deleg_modify attribute (see <xref fattr4_time_deleg_modify attribute (see <xref
target="ssec_proxy_xdr"/>). (The change time can be derived from target="ssec_proxy_xdr"/>). (Note that the change time can be derived from
the modify time.) Further, when it gets a SETATTR with those the modify time.) Further, when it gets a SETATTR with those attributes
attributes being set, then it <bcp14>MUST</bcp14> accept those set, then it <bcp14>MUST</bcp14> accept those
fattr4_time_deleg_access attribute and fattr4_time_deleg_modify fattr4_time_deleg_access attribute and fattr4_time_deleg_modify
attribute changes and derive the change time or reject the changes attribute changes and derive the change time or reject the changes with
with NFS4ERR_DELAY (see Section 15.1.1.3 of <xref target="RFC8881" NFS4ERR_DELAY (see <xref target="RFC8881" section="15.1.1.3"
format="default" sectionFormat="of"/>). sectionFormat="of"/>).
</t> </t>
<!-- [rfced] We are having trouble parsing the text after "either". Please
clarify.
Original:
The SETATTR SHOULD either be in a
separate compound before the one containing the DELEGRETURN or when
in the same compound, as an operation before the DELEGRETURN.
Perhaps:
The SETATTR SHOULD be either 1) in a
separate compound before the one containing the DELEGRETURN or 2)
in the same compound as an operation before the DELEGRETURN.
-->
<t> <t>
These new attributes are invalid to be used with GETATTR, VERIFY, and NVERIF Y and These new attributes are invalid to be used with GETATTR, VERIFY, and NVERIF Y, and they
can only be used with CB_GETATTR and SETATTR by a client holding an can only be used with CB_GETATTR and SETATTR by a client holding an
appropriate delegation. The SETATTR <bcp14>SHOULD</bcp14> either be appropriate delegation. The SETATTR <bcp14>SHOULD</bcp14> either be
in a separate compound before the one containing the DELEGRETURN or in a separate compound before the one containing the DELEGRETURN or
when in the same compound, as an operation before the DELEGRETURN. when in the same compound, as an operation before the DELEGRETURN.
Failure to properly sequence the operations may lead to race conditions. Failure to properly sequence the operations may lead to race conditions.
</t> </t>
<t> <t>
A key prerequisite of this approach is that the server and client are A key prerequisite of this approach is that the server and client are in
in time synchronization with each other. Note that while the base time synchronization with each other. Note that while the base NFSv4.2
NFSv4.2 does not require such synchronization, the use of RPCSEC_GSS does not require such synchronization, the use of RPCSEC_GSS typically
typically makes such a requirement. When the client presents either makes such a requirement. When the client presents either the
fattr4_time_deleg_access or fattr4_time_deleg_modify attributes fattr4_time_deleg_access or the fattr4_time_deleg_modify attribute to the
to the server, the server <bcp14>MUST</bcp14> decide for both of server, the server <bcp14>MUST</bcp14> decide for both of them whether the t
them whether the time presented is before the corresponding ime presented is:</t>
time_access (see Section 5.8.2.37 of <xref target="RFC8881" format="default"
sectionFormat="of"/>) or time_modify (see Section 5.8.2.43 of <xref target=" <!-- [rfced] FYI - We have reworked the text below to be a bulleted list for
RFC8881" format="default" ease of the reader. Please review.
sectionFormat="of"/>) attribute
on the file or past the current server time. Original:
When the time presented is before the original time, then the update When the client presents either
is ignored. When the time presented is in the future, the server fattr4_time_deleg_access or fattr4_time_deleg_modify attributes to
can either clamp the new time to the current time, or it may return the server, the server MUST decide for both of them whether the time
NFS4ERR_DELAY to the client, allowing it to retry. Note that if the presented is before the corresponding time_access (see
clock skew is large, the delay approach would result in access to Section 5.8.2.37 of [RFC8881]) or time_modify (see Section 5.8.2.43
the file being denied until the clock skew is exceeded. of [RFC8881]) attribute on the file or past the current server time.
Current:
When the client presents either
the fattr4_time_deleg_access or the fattr4_time_deleg_modify
attributes to the server, the server MUST decide for both of them
whether the time presented is:
* before the corresponding time_access attribute (see Section 5.8.2.37 of
[RFC8881]) or time_modify attribute (see Section 5.8.2.43 of [RFC8881])
on the file, or
* past the current server time.
-->
<ul>
<li>before the corresponding time_access attribute (see <xref target="RFC8
881" section="5.8.2.37" sectionFormat="of"/>) or time_modify attribute
(see <xref target="RFC8881" section="5.8.2.43" sectionFormat="of"/>) on th
e file, or</li>
<li>past the current server time.</li>
</ul>
<t>When the time
presented is before the original time, then the update is ignored. When
the time presented is in the future, the server can either clamp the new
time to the current time or return NFS4ERR_DELAY to the client,
allowing it to retry. Note that if the clock skew is large, the delay
approach would result in access to the file being denied until the clock
skew is exceeded.
</t> </t>
<t> <t>
A change in the access time <bcp14>MUST NOT</bcp14> advance the change time, A change in the access time <bcp14>MUST NOT</bcp14> advance the change
also known as the time_metadata attribute (see Section 5.8.2.42 of time, also known as the time_metadata attribute (see <xref
<xref target="RFC8881" format="default" sectionFormat="of"/>), but a target="RFC8881" section="5.8.2.42" sectionFormat="of"/>). However, a
change in the modify time might advance the change time (and in turn change in the modify time might advance the change time (and in turn, the
the change attribute (See Section 5.8.1.4 of <xref target="RFC8881" change attribute; see <xref target="RFC8881" section="5.8.1.4"
format="default" sectionFormat="of"/>). If the modify time is greater sectionFormat="of"/>). If the modify time is greater than the change time
than the change time and before the current time, then the change time and before the current time, then the change time is adjusted to the
is adjusted to the modify time and not the current time (as is most modify time and not the current time (as is most likely done on most
likely done on most SETATTR calls that change the metadata). If the SETATTR calls that change the metadata). If the modify time is in the
modify time is in the future, it will be clamped to the current time. future, it will be clamped to the current time.
</t> </t>
<t> <t>
Note that each of the possible times, access, modify, and change, are Note that each of the possible times (access, modify, and change) are
compared to the current time. They should all be compared against compared to the current time. They should all be compared against
the same time value for the current time. I.e., do not retrieve the same time value for the current time (i.e., they do not retrieve
a different value of the current time for each calculation. a different value of the current time for each calculation).
</t> </t>
<t> <t>
If the client sets the OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS If the client sets the OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS
flag in an OPEN operation, then it <bcp14>MUST</bcp14> support flag in an OPEN operation, then it <bcp14>MUST</bcp14> support
the fattr4_time_deleg_access the fattr4_time_deleg_access
and fattr4_time_deleg_modify attributes both in the CB_GETATTR and fattr4_time_deleg_modify attributes in both the CB_GETATTR
and SETATTR operations. and SETATTR operations.
</t> </t>
<section anchor="ssec_proxy_use" numbered="true" removeInRFC="false" toc="defa <section anchor="ssec_proxy_use" numbered="true" toc="default">
ult"> <name>Use Case for NFSv3 Client Proxy</name>
<name>Use case: NFSv3 client proxy</name>
<t> <t>
Consider a NFSv3 client which wants to access data on a server Consider an NFSv3 client that wants to access data on a server
which only supports NFSv4.2. An implementation may introduce an that only supports NFSv4.2. An implementation may introduce an
NFSv3 server that functions as an NFSv4.2 client, serving as a NFSv3 server that functions as an NFSv4.2 client, serving as a
gateway between the two otherwise incompatible systems. As NFSv3 gateway between the two otherwise incompatible systems. As NFSv3
is a stateless protocol, the state is not kept on the client, but is a stateless protocol, the state is not kept on the client, but rather
rather the NFSv3 server. As the NFSv3 server is already managing the on the NFSv3 server. As the NFSv3 server is already managing the
state, it can proxy file delegations to avoid spurious GETATTRs. state, it can proxy file delegations to avoid spurious GETATTRs. That is,
I.e., as the client queries the NFSv3 server for the attributes, as the client queries the NFSv3 server for the attributes,
they can be served without the NFSv3 server sending a GETATTR to they can be served without the NFSv3 server sending a GETATTR to
the NFSv4.2 server. the NFSv4.2 server.
</t> </t>
</section> </section>
<section anchor="ssec_proxy_xdr" numbered="true" removeInRFC="false" toc="defa ult"> <section anchor="ssec_proxy_xdr" numbered="true" toc="default">
<name>XDR for Proxying of Times</name> <name>XDR for Proxying of Times</name>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="xdr" markers="true"><![CDATA[
/// ///
/// /* /// /*
/// * attributes for the delegation times being /// * attributes for the delegation times being
/// * cached and served by the "client" /// * cached and served by the "client"
/// */ /// */
/// typedef nfstime4 fattr4_time_deleg_access; /// typedef nfstime4 fattr4_time_deleg_access;
/// typedef nfstime4 fattr4_time_deleg_modify; /// typedef nfstime4 fattr4_time_deleg_modify;
/// ///
/// ///
/// %/* /// %/*
/// % * New RECOMMENDED Attribute for /// % * New RECOMMENDED Attribute for
/// % * delegation caching of times /// % * delegation caching of times
/// % */ /// % */
/// const FATTR4_TIME_DELEG_ACCESS = 84; /// const FATTR4_TIME_DELEG_ACCESS = 84;
/// const FATTR4_TIME_DELEG_MODIFY = 85; /// const FATTR4_TIME_DELEG_MODIFY = 85;
/// ///
/// ///
/// const OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS = 0x100000; /// const OPEN4_SHARE_ACCESS_WANT_DELEG_TIMESTAMPS = 0x100000;
/// ///
]]> ]]></sourcecode>
</sourcecode>
</section> </section>
</section> </section>
<section anchor="xdr_desc" numbered="true" removeInRFC="false" toc="default"> <section anchor="xdr_desc" numbered="true" toc="default">
<name>Extraction of XDR</name> <name>Extraction of XDR</name>
<t> <t>
This document contains the external data representation (XDR) This document contains the XDR <xref
<xref target="RFC4506" format="default" sectionFormat="of"/> description of target="RFC4506" format="default" sectionFormat="of"/> description of the
the new open new open flags for delegating the file to the client. The XDR description
flags for delegating the file to the client. is embedded in this document in a way that makes it simple for the reader
The XDR description is embedded in this to extract into a ready-to-compile form. The reader can feed this
document in a way that makes it simple for the reader to extract document into the following shell script to produce the machine-readable
into a ready-to-compile form. The reader can feed this document
into the following shell script to produce the machine readable
XDR description of the new flags: XDR description of the new flags:
</t> </t>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="" markers="true"><![CDATA[
#!/bin/sh #!/bin/sh
grep '^ *///' $* | sed 's?^ */// ??' | sed 's?^ *///$??' grep '^ *///' $* | sed 's?^ */// ??' | sed 's?^ *///$??'
]]> ]]></sourcecode>
</sourcecode>
<t> <t>
That is, if the above script is stored in a file called "extract.sh", and That is, if the above script is stored in a file called "extract.sh" and
this document is in a file called "spec.txt", then the reader can do: this document is in a file called "spec.txt", then the reader can do the
following:
</t> </t>
<sourcecode name="" type="" markers="true"><![CDATA[ <sourcecode name="" type="" markers="true"><![CDATA[
sh extract.sh < spec.txt > delstid_prot.x sh extract.sh < spec.txt > delstid_prot.x
]]> ]]></sourcecode>
</sourcecode>
<t> <t>
The effect of the script is to remove leading white space from each The effect of the script is to remove leading white space from each
line, plus a sentinel sequence of "///". XDR descriptions with the line, plus a sentinel sequence of "///". XDR descriptions with the
sentinel sequence are embedded throughout the document. sentinel sequence are embedded throughout the document.
</t> </t>
<t> <t>
Note that the XDR code contained in this document depends on types Note that the XDR code contained in this document depends on types
from the NFSv4.2 nfs4_prot.x file (generated from from the NFSv4.2 nfs4_prot.x file (generated from <xref target="RFC7863"
<xref target="RFC7863" format="default" sectionFormat="of"/>). format="default" sectionFormat="of"/>). This includes both nfs types that
This includes both nfs types that end with a 4, such as offset4, end with a 4 (such as offset4 and length4) as well as more generic
length4, etc., as well as more generic types such as uint32_t and types (such as uint32_t and uint64_t).
uint64_t.
</t> </t>
<t> <t>
While the XDR can be appended to that from While the XDR can be appended to that from
<xref target="RFC7863" format="default" sectionFormat="of"/>, <xref target="RFC7863" format="default" sectionFormat="of"/>,
the various code snippets belong in their respective areas of the various code snippets belong in their respective areas of
that XDR. that XDR.
</t> </t>
</section> </section>
<section anchor="sec_security" numbered="true" removeInRFC="false" toc="default" > <section anchor="sec_security" numbered="true" toc="default">
<name>Security Considerations</name> <name>Security Considerations</name>
<t> <t>
While we are extending some capabilities for client delegation, there are no While this document extends some capabilities for client delegation, there a
new security concerns. The client cannot be queried by other clients as to re
the cached attributes. The client could report false data for the cached no new security concerns. The client cannot be queried by other clients
attributes, but it already has this ability via a SETATTR operation (see Sec as to the cached attributes. The client could report false data for the
tion cached attributes, but it already has this ability via a SETATTR operation
18.30 of <xref target="RFC8881" format="default" sectionFormat="of"/>). (see <xref target="RFC8881" section="18.30" sectionFormat="of"/>).
</t> </t>
</section> </section>
<section anchor="sec_iana" numbered="true" removeInRFC="false" toc="default"> <section anchor="sec_iana" numbered="true" toc="default">
<name>IANA Considerations</name> <name>IANA Considerations</name>
<t> <t>This document has no IANA actions.</t>
There are no IANA considerations.
</t>
</section> </section>
</middle> </middle>
<back> <back>
<references> <references>
<name>References</name>
<references>
<name>Normative References</name> <name>Normative References</name>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.2119 xml"/>
.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.4506.
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" xml"/>
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.4506 <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7862.
.xml"/> xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.7863.
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.7862 xml"/>
.xml"/> <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" xml"/>
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.7863 <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8178.
.xml"/> xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" <xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8881.
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8174 xml"/>
.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8178
.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8881
.xml"/>
</references>
</references> </references>
<section numbered="true" removeInRFC="false" toc="default"> <section numbered="false" toc="default">
<name>Acknowledgments</name> <name>Acknowledgments</name>
<t> <t><contact fullname="Trond Myklebust"/>, <contact fullname="Tom
Trond Myklebust, Tom Haynes, and David Flynn Haynes"/>, and <contact fullname="David Flynn"/> all worked on the
all worked on the prototype at Hammerspace. prototype at Hammerspace.</t>
</t> <t><contact fullname="Dave Noveck"/>, <contact fullname="Chuck Lever"/>,
<t> <contact fullname="Rick Macklem"/>, and <contact fullname="Zaheduzzaman
Dave Noveck, Chuck Lever, Rick Macklem, and Zaheduzzaman Sarker Sarker"/> provided reviews of the document.</t>
provided reviews of the document. <t><contact fullname="Jeff Layton"/> provided experience from an
</t> implementation he authored.</t>
<t>
Jeff Layton provided experience from an implementation he authored.
</t>
</section> </section>
</back> </back>
<!-- [rfced] We updated the sourcecode type in Sections 2.1, 3.1, and 5.2 to
"xdr". Please confirm that this is correct.
Should the sourcecode type be set for the sourcecode in Sections 4.1 and 6?
Note that the current list of preferred values for "type" is available at
<https://www.rfc-editor.org/rpc/wiki/doku.php?id=sourcecode-types>.
If the current list does not contain an applicable type, feel free to
suggest additions for consideration. Note that it is also acceptable
to leave the "type" attribute not set.
-->
<!-- [rfced] Please review the "Inclusive Language" portion of the online
Style Guide <https://www.rfc-editor.org/styleguide/part2/#inclusive_language>
and let us know if any changes are needed. Updates of this nature typically
result in more precise language, which is helpful for readers.
For example, please consider whether "white space" should be updated in the
text below:
Original:
The effect of the script is to remove leading white space from each
line, plus a sentinel sequence of "///".
-->
</rfc> </rfc>
 End of changes. 101 change blocks. 
356 lines changed or deleted 708 lines changed or added

This html diff was produced by rfcdiff 1.48.