draft-ietf-nfsv4-minorversion2-36.txt   draft-ietf-nfsv4-minorversion2-37.txt 
NFSv4 T. Haynes NFSv4 T. Haynes
Internet-Draft Primary Data Internet-Draft Primary Data
Intended status: Standards Track April 22, 2015 Intended status: Standards Track April 27, 2015
Expires: October 24, 2015 Expires: October 29, 2015
NFS Version 4 Minor Version 2 NFS Version 4 Minor Version 2
draft-ietf-nfsv4-minorversion2-36.txt draft-ietf-nfsv4-minorversion2-37.txt
Abstract Abstract
This Internet-Draft describes NFS version 4 minor version two, This Internet-Draft describes NFS version 4 minor version two,
describing the protocol extensions made from NFS version 4 minor describing the protocol extensions made from NFS version 4 minor
version 1. Major extensions introduced in NFS version 4 minor version 1. Major extensions introduced in NFS version 4 minor
version two include: Server Side Copy, Application I/O Advise, Space version two include: Server Side Copy, Application I/O Advise, Space
Reservations, Sparse Files, Application Data Blocks, and Labeled NFS. Reservations, Sparse Files, Application Data Blocks, and Labeled NFS.
Requirements Language Requirements Language
skipping to change at page 1, line 40 skipping to change at page 1, line 40
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on October 24, 2015. This Internet-Draft will expire on October 29, 2015.
Copyright Notice Copyright Notice
Copyright (c) 2015 IETF Trust and the persons identified as the Copyright (c) 2015 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
skipping to change at page 4, line 11 skipping to change at page 4, line 11
for a File System . . . . . . . . . . . . . . . . . . . 57 for a File System . . . . . . . . . . . . . . . . . . . 57
15. NFSv4.2 Operations . . . . . . . . . . . . . . . . . . . . . 59 15. NFSv4.2 Operations . . . . . . . . . . . . . . . . . . . . . 59
15.1. Operation 59: ALLOCATE - Reserve Space in A Region of a 15.1. Operation 59: ALLOCATE - Reserve Space in A Region of a
File . . . . . . . . . . . . . . . . . . . . . . . . . . 59 File . . . . . . . . . . . . . . . . . . . . . . . . . . 59
15.2. Operation 60: COPY - Initiate a server-side copy . . . . 60 15.2. Operation 60: COPY - Initiate a server-side copy . . . . 60
15.3. Operation 61: COPY_NOTIFY - Notify a source server of a 15.3. Operation 61: COPY_NOTIFY - Notify a source server of a
future copy . . . . . . . . . . . . . . . . . . . . . . 64 future copy . . . . . . . . . . . . . . . . . . . . . . 64
15.4. Operation 62: DEALLOCATE - Unreserve Space in a Region 15.4. Operation 62: DEALLOCATE - Unreserve Space in a Region
of a File . . . . . . . . . . . . . . . . . . . . . . . 66 of a File . . . . . . . . . . . . . . . . . . . . . . . 66
15.5. Operation 63: IO_ADVISE - Application I/O access pattern 15.5. Operation 63: IO_ADVISE - Application I/O access pattern
hints . . . . . . . . . . . . . . . . . . . . . . . . . 68 hints . . . . . . . . . . . . . . . . . . . . . . . . . 67
15.6. Operation 64: LAYOUTERROR - Provide Errors for the 15.6. Operation 64: LAYOUTERROR - Provide Errors for the
Layout . . . . . . . . . . . . . . . . . . . . . . . . . 73 Layout . . . . . . . . . . . . . . . . . . . . . . . . . 73
15.7. Operation 65: LAYOUTSTATS - Provide Statistics for the 15.7. Operation 65: LAYOUTSTATS - Provide Statistics for the
Layout . . . . . . . . . . . . . . . . . . . . . . . . . 76 Layout . . . . . . . . . . . . . . . . . . . . . . . . . 76
15.8. Operation 66: OFFLOAD_CANCEL - Stop an Offloaded 15.8. Operation 66: OFFLOAD_CANCEL - Stop an Offloaded
Operation . . . . . . . . . . . . . . . . . . . . . . . 78 Operation . . . . . . . . . . . . . . . . . . . . . . . 78
15.9. Operation 67: OFFLOAD_STATUS - Poll for Status of 15.9. Operation 67: OFFLOAD_STATUS - Poll for Status of
Asynchronous Operation . . . . . . . . . . . . . . . . . 79 Asynchronous Operation . . . . . . . . . . . . . . . . . 79
15.10. Operation 68: READ_PLUS - READ Data or Holes from a File 80 15.10. Operation 68: READ_PLUS - READ Data or Holes from a File 80
15.11. Operation 69: SEEK - Find the Next Data or Hole . . . . 85 15.11. Operation 69: SEEK - Find the Next Data or Hole . . . . 85
15.12. Operation 70: WRITE_SAME - WRITE an ADB Multiple Times 15.12. Operation 70: WRITE_SAME - WRITE an ADB Multiple Times
to a File . . . . . . . . . . . . . . . . . . . . . . . 86 to a File . . . . . . . . . . . . . . . . . . . . . . . 86
15.13. Operation 71: CLONE - Clone a file . . . . . . . . . . . 90 15.13. Operation 71: CLONE - Clone a range of file into another
file . . . . . . . . . . . . . . . . . . . . . . . . . . 90
16. NFSv4.2 Callback Operations . . . . . . . . . . . . . . . . . 91 16. NFSv4.2 Callback Operations . . . . . . . . . . . . . . . . . 91
16.1. Operation 15: CB_OFFLOAD - Report results of an 16.1. Operation 15: CB_OFFLOAD - Report results of an
asynchronous operation . . . . . . . . . . . . . . . . . 91 asynchronous operation . . . . . . . . . . . . . . . . . 92
17. Security Considerations . . . . . . . . . . . . . . . . . . . 93 17. Security Considerations . . . . . . . . . . . . . . . . . . . 93
18. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 93 18. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 93
19. References . . . . . . . . . . . . . . . . . . . . . . . . . 93 19. References . . . . . . . . . . . . . . . . . . . . . . . . . 93
19.1. Normative References . . . . . . . . . . . . . . . . . . 93 19.1. Normative References . . . . . . . . . . . . . . . . . . 93
19.2. Informative References . . . . . . . . . . . . . . . . . 94 19.2. Informative References . . . . . . . . . . . . . . . . . 94
Appendix A. Acknowledgments . . . . . . . . . . . . . . . . . . 95 Appendix A. Acknowledgments . . . . . . . . . . . . . . . . . . 96
Appendix B. RFC Editor Notes . . . . . . . . . . . . . . . . . . 96 Appendix B. RFC Editor Notes . . . . . . . . . . . . . . . . . . 97
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 97 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 97
1. Introduction 1. Introduction
1.1. The NFS Version 4 Minor Version 2 Protocol 1.1. The NFS Version 4 Minor Version 2 Protocol
The NFS version 4 minor version 2 (NFSv4.2) protocol is the third The NFS version 4 minor version 2 (NFSv4.2) protocol is the third
minor version of the NFS version 4 (NFSv4) protocol. The first minor minor version of the NFS version 4 (NFSv4) protocol. The first minor
version, NFSv4.0, is described in [RFC7530] and the second minor version, NFSv4.0, is described in [RFC7530] and the second minor
version, NFSv4.1, is described in [RFC5661]. version, NFSv4.1, is described in [RFC5661].
skipping to change at page 45, line 29 skipping to change at page 45, line 29
| | NFS4ERR_OPENMODE, NFS4ERR_OP_NOT_IN_SESSION, | | | NFS4ERR_OPENMODE, NFS4ERR_OP_NOT_IN_SESSION, |
| | NFS4ERR_REP_TOO_BIG, | | | NFS4ERR_REP_TOO_BIG, |
| | NFS4ERR_REP_TOO_BIG_TO_CACHE, | | | NFS4ERR_REP_TOO_BIG_TO_CACHE, |
| | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, | | | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, |
| | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, | | | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, |
| | NFS4ERR_STALE, NFS4ERR_SYMLINK, | | | NFS4ERR_STALE, NFS4ERR_SYMLINK, |
| | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE | | | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE |
| CLONE | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, | | CLONE | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, |
| | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, | | | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, |
| | NFS4ERR_DEADSESSION, NFS4ERR_DELAY, | | | NFS4ERR_DEADSESSION, NFS4ERR_DELAY, |
| | NFS4ERR_DELEG_REVOKED, NFS4ERR_EXPIRED, | | | NFS4ERR_DELEG_REVOKED, NFS4ERR_DQUOT, |
| | NFS4ERR_FBIG, NFS4ERR_FHEXPIRED, NFS4ERR_GRACE, | | | NFS4ERR_EXPIRED, NFS4ERR_FBIG, |
| | NFS4ERR_INVAL, NFS4ERR_IO, NFS4ERR_ISDIR, | | | NFS4ERR_FHEXPIRED, NFS4ERR_GRACE, NFS4ERR_INVAL, |
| | NFS4ERR_MOVED, NFS4ERR_NOFILEHANDLE, | | | NFS4ERR_IO, NFS4ERR_ISDIR, NFS4ERR_MOVED, |
| | NFS4ERR_NOTSUPP, NFS4ERR_NOSPC, | | | NFS4ERR_NOFILEHANDLE, NFS4ERR_NOTSUPP, |
| | NFS4ERR_OLD_STATEID, NFS4ERR_OPENMODE, | | | NFS4ERR_NOSPC, NFS4ERR_OLD_STATEID, |
| | NFS4ERR_OP_NOT_IN_SESSION, NFS4ERR_REP_TOO_BIG, | | | NFS4ERR_OPENMODE, NFS4ERR_OP_NOT_IN_SESSION, |
| | NFS4ERR_REP_TOO_BIG, |
| | NFS4ERR_REP_TOO_BIG_TO_CACHE, | | | NFS4ERR_REP_TOO_BIG_TO_CACHE, |
| | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, | | | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, |
| | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, | | | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, |
| | NFS4ERR_STALE, NFS4ERR_SYMLINK, | | | NFS4ERR_STALE, NFS4ERR_SYMLINK, |
| | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE | | | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE, |
| | NFS4ERR_XDEV |
| COPY | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, | | COPY | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, |
| | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, | | | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, |
| | NFS4ERR_DEADSESSION, NFS4ERR_DELAY, | | | NFS4ERR_DEADSESSION, NFS4ERR_DELAY, |
| | NFS4ERR_DELEG_REVOKED, NFS4ERR_DQUOT, | | | NFS4ERR_DELEG_REVOKED, NFS4ERR_DQUOT, |
| | NFS4ERR_EXPIRED, NFS4ERR_FBIG, | | | NFS4ERR_EXPIRED, NFS4ERR_FBIG, |
| | NFS4ERR_FHEXPIRED, NFS4ERR_GRACE, NFS4ERR_INVAL, | | | NFS4ERR_FHEXPIRED, NFS4ERR_GRACE, NFS4ERR_INVAL, |
| | NFS4ERR_IO, NFS4ERR_ISDIR, NFS4ERR_LOCKED, | | | NFS4ERR_IO, NFS4ERR_ISDIR, NFS4ERR_LOCKED, |
| | NFS4ERR_METADATA_NOTSUPP, NFS4ERR_MOVED, | | | NFS4ERR_MOVED, NFS4ERR_NOFILEHANDLE, |
| | NFS4ERR_NOFILEHANDLE, NFS4ERR_NOSPC, | | | NFS4ERR_NOSPC, NFS4ERR_OFFLOAD_DENIED, |
| | NFS4ERR_OFFLOAD_DENIED, NFS4ERR_OLD_STATEID, | | | NFS4ERR_OLD_STATEID, NFS4ERR_OPENMODE, |
| | NFS4ERR_OPENMODE, NFS4ERR_OP_NOT_IN_SESSION, | | | NFS4ERR_OP_NOT_IN_SESSION, |
| | NFS4ERR_PARTNER_NO_AUTH, | | | NFS4ERR_PARTNER_NO_AUTH, |
| | NFS4ERR_PARTNER_NOTSUPP, NFS4ERR_PNFS_IO_HOLE, | | | NFS4ERR_PARTNER_NOTSUPP, NFS4ERR_PNFS_IO_HOLE, |
| | NFS4ERR_PNFS_NO_LAYOUT, NFS4ERR_REP_TOO_BIG, | | | NFS4ERR_PNFS_NO_LAYOUT, NFS4ERR_REP_TOO_BIG, |
| | NFS4ERR_REP_TOO_BIG_TO_CACHE, | | | NFS4ERR_REP_TOO_BIG_TO_CACHE, |
| | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, | | | NFS4ERR_REQ_TOO_BIG, NFS4ERR_RETRY_UNCACHED_REP, |
| | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, | | | NFS4ERR_ROFS, NFS4ERR_SERVERFAULT, |
| | NFS4ERR_STALE, NFS4ERR_SYMLINK, | | | NFS4ERR_STALE, NFS4ERR_SYMLINK, |
| | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE | | | NFS4ERR_TOO_MANY_OPS, NFS4ERR_WRONG_TYPE |
| COPY_NOTIFY | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, | | COPY_NOTIFY | NFS4ERR_ACCESS, NFS4ERR_ADMIN_REVOKED, |
| | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, | | | NFS4ERR_BADXDR, NFS4ERR_BAD_STATEID, |
skipping to change at page 61, line 34 skipping to change at page 61, line 34
15.2.3. DESCRIPTION 15.2.3. DESCRIPTION
The COPY operation is used for both intra-server and inter-server The COPY operation is used for both intra-server and inter-server
copies. In both cases, the COPY is always sent from the client to copies. In both cases, the COPY is always sent from the client to
the destination server of the file copy. The COPY operation requests the destination server of the file copy. The COPY operation requests
that a range in the file specified by SAVED_FH is copied to a range that a range in the file specified by SAVED_FH is copied to a range
in the file specified by CURRENT_FH. in the file specified by CURRENT_FH.
Both SAVED_FH and CURRENT_FH must be regular files. If either Both SAVED_FH and CURRENT_FH must be regular files. If either
SAVED_FH or CURRENT_FH are not regular files, the operation MUST fail SAVED_FH or CURRENT_FH is not a regular file, the operation MUST fail
and return NFS4ERR_WRONG_TYPE. and return NFS4ERR_WRONG_TYPE.
SAVED_FH and CURRENT_FH must be different files. If SAVED_FH and SAVED_FH and CURRENT_FH must be different files. If SAVED_FH and
CURRENT_FH refer to the same file, the operation will fail with CURRENT_FH refer to the same file, the operation MUST fail with
NFS4ERR_INVAL. NFS4ERR_INVAL.
In order to set SAVED_FH to the source file handle, the compound
procedure requesting the COPY will include a sub-sequence of
operations such as
PUTFH source-fh
SAVEFH
If the request is for an inter-server-to-server copy, the source-fh If the request is for an inter-server-to-server copy, the source-fh
is a filehandle from the source server and the compound procedure is is a filehandle from the source server and the compound procedure is
being executed on the destination server. In this case, the source- being executed on the destination server. In this case, the source-
fh is a foreign filehandle on the server receiving the COPY request. fh is a foreign filehandle on the server receiving the COPY request.
If either PUTFH or SAVEFH checked the validity of the filehandle, the If either PUTFH or SAVEFH checked the validity of the filehandle, the
operation would likely fail and return NFS4ERR_STALE. operation would likely fail and return NFS4ERR_STALE.
If a server supports the inter-server-to-server COPY feature, a PUTFH If a server supports the inter-server-to-server COPY feature, a PUTFH
followed by a SAVEFH MUST NOT return NFS4ERR_STALE for either followed by a SAVEFH MUST NOT return NFS4ERR_STALE for either
operation. These restrictions do not pose substantial difficulties operation. These restrictions do not pose substantial difficulties
for servers. CURRENT_FH and SAVED_FH may be validated in the context for servers. CURRENT_FH and SAVED_FH may be validated in the context
of the operation referencing them and an NFS4ERR_STALE error returned of the operation referencing them and an NFS4ERR_STALE error returned
for an invalid file handle at that point. for an invalid file handle at that point.
skipping to change at page 62, line 43 skipping to change at page 62, line 35
NFS operations (e.g., OPEN with OPEN4_SHARE_DENY_WRITE or mandatory NFS operations (e.g., OPEN with OPEN4_SHARE_DENY_WRITE or mandatory
byte range locks) to protect against concurrent modifications if the byte range locks) to protect against concurrent modifications if the
client is concerned about this. If the source file's end of file is client is concerned about this. If the source file's end of file is
being modified in parallel with a copy that specifies a count of 0 being modified in parallel with a copy that specifies a count of 0
(zero) bytes, the amount of data copied is implementation dependent (zero) bytes, the amount of data copied is implementation dependent
(clients may guard against this case by specifying a non-zero count (clients may guard against this case by specifying a non-zero count
value or preventing modification of the source file as mentioned value or preventing modification of the source file as mentioned
above). above).
If the source offset or the source offset plus count is greater than If the source offset or the source offset plus count is greater than
the size of the source file, the operation will fail with the size of the source file, the operation MUST fail with
NFS4ERR_INVAL. The destination offset or destination offset plus NFS4ERR_INVAL. The destination offset or destination offset plus
count may be greater than the size of the destination file. This count may be greater than the size of the destination file. This
allows for the client to issue parallel copies to implement allows for the client to issue parallel copies to implement
operations such as operations such as
<CODE BEGINS> <CODE BEGINS>
% cat file1 file2 file3 file4 > dest % cat file1 file2 file3 file4 > dest
<CODE ENDS> <CODE ENDS>
skipping to change at page 90, line 5 skipping to change at page 90, line 5
15.12.3.2. Error Handling of a Partially Complete WRITE_SAME 15.12.3.2. Error Handling of a Partially Complete WRITE_SAME
WRITE_SAME will clone adb_block_count copies of the given ADB in WRITE_SAME will clone adb_block_count copies of the given ADB in
consecutive order in the file starting at adb_offset. An error can consecutive order in the file starting at adb_offset. An error can
occur after writing the Nth ADB to the file. WRITE_SAME MUST appear occur after writing the Nth ADB to the file. WRITE_SAME MUST appear
to populate the range of the file as if the client used WRITE to to populate the range of the file as if the client used WRITE to
transfer the instantiated ADBs. I.e., the contents of the range will transfer the instantiated ADBs. I.e., the contents of the range will
be easy for the client to determine in case of a partially complete be easy for the client to determine in case of a partially complete
WRITE_SAME. WRITE_SAME.
15.13. Operation 71: CLONE - Clone a file 15.13. Operation 71: CLONE - Clone a range of file into another file
15.13.1. ARGUMENT 15.13.1. ARGUMENT
<CODE BEGINS> <CODE BEGINS>
struct CLONE4args { struct CLONE4args {
/* SAVED_FH: source file */ /* SAVED_FH: source file */
/* CURRENT_FH: destination file */ /* CURRENT_FH: destination file */
stateid4 cl_src_stateid; stateid4 cl_src_stateid;
stateid4 cl_dst_stateid; stateid4 cl_dst_stateid;
skipping to change at page 90, line 37 skipping to change at page 90, line 37
struct CLONE4res { struct CLONE4res {
nfsstat4 cl_status; nfsstat4 cl_status;
}; };
<CODE ENDS> <CODE ENDS>
15.13.3. DESCRIPTION 15.13.3. DESCRIPTION
The CLONE operation is used to clone file content from a source file The CLONE operation is used to clone file content from a source file
specified by the SAVED_FH value into a destination file specified by specified by the SAVED_FH value into a destination file specified by
CURRENT_FH without actually copying the data, e.g., by using a copy CURRENT_FH without actually copying the data, e.g., by using a copy-
on write mechanism. on-write mechanism.
Both SAVED_FH and CURRENT_FH must be regular files. If either Both SAVED_FH and CURRENT_FH must be regular files. If either
SAVED_FH or CURRENT_FH are not regular files, the operation MUST fail SAVED_FH or CURRENT_FH is not a regular file, the operation MUST fail
and return NFS4ERR_WRONG_TYPE. and return NFS4ERR_WRONG_TYPE.
SAVED_FH and CURRENT_FH must be different files. If SAVED_FH and SAVED_FH and CURRENT_FH must be different files. If SAVED_FH and
CURRENT_FH refer to the same file, the operation will fail with CURRENT_FH refer to the same file, the operation MUST fail with
NFS4ERR_INVAL. NFS4ERR_INVAL.
In order to set SAVED_FH to the source file handle, the compound
procedure requesting the CLONE will include a sub-sequence of
operations such as
PUTFH source-fh
SAVEFH
The ca_dst_stateid MUST refer to a stateid that is valid for a WRITE The ca_dst_stateid MUST refer to a stateid that is valid for a WRITE
operation and follows the rules for stateids in Sections 8.2.5 and operation and follows the rules for stateids in Sections 8.2.5 and
18.32.3 of [RFC5661]. The ca_src_stateid MUST refer to a stateid 18.32.3 of [RFC5661]. The ca_src_stateid MUST refer to a stateid
that is valid for a READ operations and follows the rules for that is valid for a READ operations and follows the rules for
stateids in Sections 8.2.5 and 18.22.3 of [RFC5661]. If either stateids in Sections 8.2.5 and 18.22.3 of [RFC5661]. If either
stateid is invalid, then the operation MUST fail. stateid is invalid, then the operation MUST fail.
The cl_src_offset is the offset within the source file from which the The cl_src_offset is the starting offset within the source file from
data will be read, the cl_dst_offset is the offset within the which the data to be cloned will be obtained and the cl_dst_offset is
destination file to which the data will be written, and the cl_count the starting offset of the target region into which the cloned data
is the number of bytes that will be cloned. An offset of 0 (zero) will be placed. An offset of 0 (zero) indicates the start of the
specifies the start of the file. A count of 0 (zero) requests that respective file. The number of bytes to be cloned is obtained from
all bytes from ca_src_offset through EOF be cloned to the cl_count, except that a cl_count of 0 (zero) indicates that the
destination. Both cl_src_offset and cl_dst_offset must be aligned to number of bytes to be cloned is the count of bytes between
the clone block size Section 12.2.1. cl_count must be aligned to the cl_src_offset and the EOF of the source file. Both cl_src_offset and
clone block size, unless cl_src_offset + cl_count are equal to the cl_dst_offset must be aligned to the clone block size Section 12.2.1.
source file size. The number of bytes to be cloned must be a multiple of the clone
block size, except in the case in which cl_src_offset plus the number
of bytes to be cloned is equal to the source file size.
If the source offset or the source offset plus count is greater than If the source offset or the source offset plus count is greater than
the size of the source file, the operation will fail with the size of the source file, the operation MUST fail with
NFS4ERR_INVAL. The destination offset or destination offset plus NFS4ERR_INVAL. The destination offset or destination offset plus
count may be greater than the size of the destination file. count may be greater than the size of the destination file.
If the CLONE wrote past the end of the file on the destination, then If the target area of the clone operation ends beyond the end of the
the last byte written to will determine the new file size. The destination file, the offset at the end of the target area will
contents of any block not written to and past the original size of determine the new size of the destination file. The contents of any
the file will be as if a normal WRITE extended the file. block not part of the target area will be the same as if the file
size were extended by a WRITE.
The CLONE operation is atomic, that is either all changes or no If the area to be cloned is not a multiple of the clone block size
changes are seen by the client or other clients. and the size of the destination file is past the end of the target
area, the area between the end of the target area and the next
multiple o the clone block size wlll be zeroed.
The CLONE operation is atomic in that other operations may not see
see any intermediate states between the state of the two files before
the operation and that after the operation. READs of the destination
file will never see some blocks of the target area cloned without all
of them being cloned. WRITEs of the source area will either have no
effect on the data of the target file or be fully reflected in the
target area of the destination file.
The completion status of the operation is indicated by cr_status. The completion status of the operation is indicated by cr_status.
16. NFSv4.2 Callback Operations 16. NFSv4.2 Callback Operations
16.1. Operation 15: CB_OFFLOAD - Report results of an asynchronous 16.1. Operation 15: CB_OFFLOAD - Report results of an asynchronous
operation operation
16.1.1. ARGUMENT 16.1.1. ARGUMENT
<CODE BEGINS> <CODE BEGINS>
struct write_response4 { struct write_response4 {
stateid4 wr_callback_id<1>; stateid4 wr_callback_id<1>;
length4 wr_count; length4 wr_count;
stable_how4 wr_committed; stable_how4 wr_committed;
verifier4 wr_writeverf; verifier4 wr_writeverf;
}; };
union offload_info4 switch (nfsstat4 coa_status) { union offload_info4 switch (nfsstat4 coa_status) {
case NFS4_OK: case NFS4_OK:
write_response4 coa_resok4; write_response4 coa_resok4;
 End of changes. 26 change blocks. 
61 lines changed or deleted 63 lines changed or added

This html diff was produced by rfcdiff 1.42. The latest version is available from http://tools.ietf.org/tools/rfcdiff/