idnits 2.17.1 draft-ietf-nfsv4-flex-files-12.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 369 has weird spacing: '... loghyr staff...' == Line 1312 has weird spacing: '...stateid lor...' == Line 1567 has weird spacing: '...rs_hint ffl...' -- The document date (July 20, 2017) is 2465 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Possible downref: Non-RFC (?) normative reference: ref. 'LEGAL' ** Downref: Normative reference to an Informational RFC: RFC 1813 ** Obsolete normative reference: RFC 5661 (Obsoleted by RFC 8881) Summary: 2 errors (**), 0 flaws (~~), 4 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 NFSv4 B. Halevy 3 Internet-Draft 4 Intended status: Standards Track T. Haynes 5 Expires: January 21, 2018 Primary Data 6 July 20, 2017 8 Parallel NFS (pNFS) Flexible File Layout 9 draft-ietf-nfsv4-flex-files-12.txt 11 Abstract 13 The Parallel Network File System (pNFS) allows a separation between 14 the metadata (onto a metadata server) and data (onto a storage 15 device) for a file. The flexible file layout type is defined in this 16 document as an extension to pNFS which allows the use of storage 17 devices in a fashion such that they require only a quite limited 18 degree of interaction with the metadata server, using already 19 existing protocols. Client side mirroring is also added to provide 20 replication of files. 22 Status of This Memo 24 This Internet-Draft is submitted in full conformance with the 25 provisions of BCP 78 and BCP 79. 27 Internet-Drafts are working documents of the Internet Engineering 28 Task Force (IETF). Note that other groups may also distribute 29 working documents as Internet-Drafts. The list of current Internet- 30 Drafts is at http://datatracker.ietf.org/drafts/current/. 32 Internet-Drafts are draft documents valid for a maximum of six months 33 and may be updated, replaced, or obsoleted by other documents at any 34 time. It is inappropriate to use Internet-Drafts as reference 35 material or to cite them other than as "work in progress." 37 This Internet-Draft will expire on January 21, 2018. 39 Copyright Notice 41 Copyright (c) 2017 IETF Trust and the persons identified as the 42 document authors. All rights reserved. 44 This document is subject to BCP 78 and the IETF Trust's Legal 45 Provisions Relating to IETF Documents 46 (http://trustee.ietf.org/license-info) in effect on the date of 47 publication of this document. Please review these documents 48 carefully, as they describe your rights and restrictions with respect 49 to this document. Code Components extracted from this document must 50 include Simplified BSD License text as described in Section 4.e of 51 the Trust Legal Provisions and are provided without warranty as 52 described in the Simplified BSD License. 54 Table of Contents 56 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 57 1.1. Definitions . . . . . . . . . . . . . . . . . . . . . . . 3 58 1.2. Difference Between a Data Server and a Storage Device . . 5 59 1.3. Requirements Language . . . . . . . . . . . . . . . . . . 6 60 2. Coupling of Storage Devices . . . . . . . . . . . . . . . . . 6 61 2.1. LAYOUTCOMMIT . . . . . . . . . . . . . . . . . . . . . . 6 62 2.2. Fencing Clients from the Storage Device . . . . . . . . . 6 63 2.2.1. Implementation Notes for Synthetic uids/gids . . . . 7 64 2.2.2. Example of using Synthetic uids/gids . . . . . . . . 8 65 2.3. State and Locking Models . . . . . . . . . . . . . . . . 9 66 2.3.1. Loosely Coupled Locking Model . . . . . . . . . . . . 9 67 2.3.2. Tighly Coupled Locking Model . . . . . . . . . . . . 11 68 3. XDR Description of the Flexible File Layout Type . . . . . . 12 69 3.1. Code Components Licensing Notice . . . . . . . . . . . . 13 70 4. Device Addressing and Discovery . . . . . . . . . . . . . . . 14 71 4.1. ff_device_addr4 . . . . . . . . . . . . . . . . . . . . . 15 72 4.2. Storage Device Multipathing . . . . . . . . . . . . . . . 16 73 5. Flexible File Layout Type . . . . . . . . . . . . . . . . . . 17 74 5.1. ff_layout4 . . . . . . . . . . . . . . . . . . . . . . . 18 75 5.1.1. Error Codes from LAYOUTGET . . . . . . . . . . . . . 21 76 5.1.2. Client Interactions with FF_FLAGS_NO_IO_THRU_MDS . . 22 77 5.2. Interactions Between Devices and Layouts . . . . . . . . 22 78 5.3. Handling Version Errors . . . . . . . . . . . . . . . . . 22 79 6. Striping via Sparse Mapping . . . . . . . . . . . . . . . . . 23 80 7. Recovering from Client I/O Errors . . . . . . . . . . . . . . 23 81 8. Mirroring . . . . . . . . . . . . . . . . . . . . . . . . . . 24 82 8.1. Selecting a Mirror . . . . . . . . . . . . . . . . . . . 25 83 8.2. Writing to Mirrors . . . . . . . . . . . . . . . . . . . 25 84 8.2.1. Single Storage Device Updates Mirrors . . . . . . . . 25 85 8.2.2. Single Storage Device Updates Mirrors . . . . . . . . 26 86 8.2.3. Handling Write Errors . . . . . . . . . . . . . . . . 26 87 8.2.4. Handling Write COMMITs . . . . . . . . . . . . . . . 27 88 8.3. Metadata Server Resilvering of the File . . . . . . . . . 27 89 9. Flexible Files Layout Type Return . . . . . . . . . . . . . . 27 90 9.1. I/O Error Reporting . . . . . . . . . . . . . . . . . . . 29 91 9.1.1. ff_ioerr4 . . . . . . . . . . . . . . . . . . . . . . 29 92 9.2. Layout Usage Statistics . . . . . . . . . . . . . . . . . 29 93 9.2.1. ff_io_latency4 . . . . . . . . . . . . . . . . . . . 30 94 9.2.2. ff_layoutupdate4 . . . . . . . . . . . . . . . . . . 30 95 9.2.3. ff_iostats4 . . . . . . . . . . . . . . . . . . . . . 31 96 9.3. ff_layoutreturn4 . . . . . . . . . . . . . . . . . . . . 32 98 10. Flexible Files Layout Type LAYOUTERROR . . . . . . . . . . . 33 99 11. Flexible Files Layout Type LAYOUTSTATS . . . . . . . . . . . 33 100 12. Flexible File Layout Type Creation Hint . . . . . . . . . . . 33 101 12.1. ff_layouthint4 . . . . . . . . . . . . . . . . . . . . . 34 102 13. Recalling a Layout . . . . . . . . . . . . . . . . . . . . . 34 103 13.1. CB_RECALL_ANY . . . . . . . . . . . . . . . . . . . . . 34 104 14. Client Fencing . . . . . . . . . . . . . . . . . . . . . . . 35 105 15. Security Considerations . . . . . . . . . . . . . . . . . . . 36 106 15.1. Kerberized File Access . . . . . . . . . . . . . . . . . 37 107 15.1.1. Loosely Coupled . . . . . . . . . . . . . . . . . . 37 108 15.1.2. Tightly Coupled . . . . . . . . . . . . . . . . . . 37 109 16. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 37 110 17. References . . . . . . . . . . . . . . . . . . . . . . . . . 38 111 17.1. Normative References . . . . . . . . . . . . . . . . . . 38 112 17.2. Informative References . . . . . . . . . . . . . . . . . 39 113 Appendix A. Acknowledgments . . . . . . . . . . . . . . . . . . 39 114 Appendix B. RFC Editor Notes . . . . . . . . . . . . . . . . . . 40 115 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 40 117 1. Introduction 119 In the parallel Network File System (pNFS), the metadata server 120 returns layout type structures that describe where file data is 121 located. There are different layout types for different storage 122 systems and methods of arranging data on storage devices. This 123 document defines the flexible file layout type used with file-based 124 data servers that are accessed using the Network File System (NFS) 125 protocols: NFSv3 [RFC1813], NFSv4.0 [RFC7530], NFSv4.1 [RFC5661], and 126 NFSv4.2 [RFC7862]. 128 To provide a global state model equivalent to that of the files 129 layout type, a back-end control protocol MAY be implemented between 130 the metadata server and NFSv4.1+ storage devices. It is out of scope 131 for this document to specify such a protocol, yet the requirements 132 for the protocol are specified in [RFC5661] and clarified in 133 [pNFSLayouts]. 135 1.1. Definitions 137 control protocol: is a set of requirements for the communication of 138 information on layouts, stateids, file metadata, and file data 139 between the metadata server and the storage devices (see 140 [pNFSLayouts]). 142 client-side mirroring: is when the client and not the server is 143 responsible for updating all of the mirrored copies of a layout 144 segment. 146 data file: is that part of the file system object which contains the 147 content. 149 data server (DS): is one of the pNFS servers which provides the 150 contents of a file system object which is a regular file. 151 Depending on the layout, there might be one or more data servers 152 over which the data is striped. Note that while the metadata 153 server is strictly accessed over the NFSv4.1+ protocol, depending 154 on the layout type, the data server could be accessed via any 155 protocol that meets the pNFS requirements. 157 fencing: is when the metadata server prevents the storage devices 158 from processing I/O from a specific client to a specific file. 160 file layout type: is a layout type in which the storage devices are 161 accessed via the NFS protocol (see Section 13 of [RFC5661]). 163 layout: informs a client of which storage devices it needs to 164 communicate with (and over which protocol) to perform I/O on a 165 file. The layout might also provide some hints about how the 166 storage is physically organized. 168 layout iomode: describes whether the layout granted to the client is 169 for read or read/write I/O. 171 layout segment: describes a sub-division of a layout. That sub- 172 division might be by the iomode (see Sections 3.3.20 and 12.2.9 of 173 [RFC5661]), a striping pattern (see Section 13.3 of [RFC5661]), or 174 requested byte range. 176 layout stateid: is a 128-bit quantity returned by a server that 177 uniquely defines the layout state provided by the server for a 178 specific layout that describes a layout type and file (see 179 Section 12.5.2 of [RFC5661]). Further, Section 12.5.3 of 180 [RFC5661] describes the difference between a layout stateid and a 181 normal stateid. 183 layout type: describes both the storage protocol used to access the 184 data and the aggregation scheme used to lay out the file data on 185 the underlying storage devices. 187 loose coupling: is when the metadata server and the storage devices 188 do not have a control protocol present. 190 metadata file: is that part of the file system object which 191 describes the object and not the content. E.g., it could be the 192 time since last modification, access, etc. 194 metadata server (MDS): is the pNFS server which provides metadata 195 information for a file system object. It also is responsible for 196 generating layouts for file system objects. Note that the MDS is 197 responsible for directory-based operations. 199 mirror: is a copy of a layout segment. Note that if one copy of the 200 mirror is updated, then all copies must be updated. 202 recalling a layout: is when the metadata server uses a back channel 203 to inform the client that the layout is to be returned in a 204 graceful manner. Note that the client has the opportunity to 205 flush any writes, etc., before replying to the metadata server. 207 revoking a layout: is when the metadata server invalidates the 208 layout such that neither the metadata server nor any storage 209 device will accept any access from the client with that layout. 211 resilvering: is the act of rebuilding a mirrored copy of a layout 212 segment from a known good copy of the layout segment. Note that 213 this can also be done to create a new mirrored copy of the layout 214 segment. 216 rsize: is the data transfer buffer size used for reads. 218 stateid: is a 128-bit quantity returned by a server that uniquely 219 defines the open and locking states provided by the server for a 220 specific open-owner or lock-owner/open-owner pair for a specific 221 file and type of lock. 223 storage device: is another term used almost interchangeably with 224 data server. See Section 1.2 for the nuances between the two. 226 tight coupling: is when the metadata server and the storage devices 227 do have a control protocol present. 229 wsize: is the data transfer buffer size used for writes. 231 1.2. Difference Between a Data Server and a Storage Device 233 We defined a data server as a pNFS server, which implies that it can 234 utilize the NFSv4.1+ protocol to communicate with the client. As 235 such, only the file layout type would currently meet this 236 requirement. The more generic concept is a storage device, which can 237 use any protocol to communicate with the client. The requirements 238 for a storage device to act together with the metadata server to 239 provide data to a client are that there is a layout type 240 specification for the given protocol and that the metadata server has 241 granted a layout to the client. Note that nothing precludes there 242 being multiple supported layout types (i.e., protocols) between a 243 metadata server, storage devices, and client. 245 As storage device is the more encompassing terminology, this document 246 utilizes it over data server. 248 1.3. Requirements Language 250 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 251 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 252 document are to be interpreted as described in [RFC2119]. 254 2. Coupling of Storage Devices 256 The coupling of the metadata server with the storage devices can be 257 either tight or loose. In a tight coupling, there is a control 258 protocol present to manage security, LAYOUTCOMMITs, etc. With a 259 loose coupling, the only control protocol might be a version of NFS. 260 As such, semantics for managing security, state, and locking models 261 MUST be defined. 263 2.1. LAYOUTCOMMIT 265 Regardless of the coupling model, the metadata server has the 266 responsibility, upon receiving a LAYOUTCOMMIT (see Section 18.42 of 267 [RFC5661]), of ensuring that the semantics of pNFS are respected (see 268 Section 12.5.4 of [RFC5661]). These do include a requirement that 269 data written to data storage device be stable before the occurrence 270 of the LAYOUTCOMMIT. 272 It is the responsibility of the client to make sure the data file is 273 stable before the metadata server begins to query the storage devices 274 about the changes to the file. If any WRITE to a storage device did 275 not result with stable_how equal to FILE_SYNC, a LAYOUTCOMMIT to the 276 metadata server MUST be preceded by a COMMIT to the storage devices 277 written to. Note that if the client has not done a COMMIT to the 278 storage device, then the LAYOUTCOMMIT might not be synchronized to 279 the last WRITE operation to the storage device. 281 2.2. Fencing Clients from the Storage Device 283 With loosely coupled storage devices, the metadata server uses 284 synthetic uids and gids for the data file, where the uid owner of the 285 data file is allowed read/write access and the gid owner is allowed 286 read only access. As part of the layout (see ffds_user and 287 ffds_group in Section 5.1), the client is provided with the user and 288 group to be used in the Remote Procedure Call (RPC) [RFC5531] 289 credentials needed to access the data file. Fencing off of clients 290 is achieved by the metadata server changing the synthetic uid and/or 291 gid owners of the data file on the storage device to implicitly 292 revoke the outstanding RPC credentials. A client presenting the 293 wrong credential for the deisred access will get a NFS4ERR_ACCESS 294 error. 296 With this loosely coupled model, the metadata server is not able to 297 fence off a single client, it is forced to fence off all clients. 298 However, as the other clients react to the fencing, returning their 299 layouts and trying to get new ones, the metadata server can hand out 300 a new uid and gid to allow access. 302 Note: it is recommended to implement common access control methods at 303 the storage device filesystem to allow only the metadata server root 304 (super user) access to the storage device, and to set the owner of 305 all directories holding data files to the root user. This approach 306 provides a practical model to enforce access control and fence off 307 cooperative clients, but it can not protect against malicious 308 clients; hence it provides a level of security equivalent to 309 AUTH_SYS. 311 With tightly coupled storage devices, the metadata server sets the 312 user and group owners, mode bits, and ACL of the data file to be the 313 same as the metadata file. And the client must authenticate with the 314 storage device and go through the same authorization process it would 315 go through via the metadata server. In the case of tight coupling, 316 fencing is the responsibility of the control protocol and is not 317 described in detail here. However, implementations of the tight 318 coupling locking model (see Section 2.3), will need a way to prevent 319 access by certain clients to specific files by invalidating the 320 corresponding stateids on the storage device. In such a scenario, 321 the client will be given an error of NFS4ERR_BAD_STATEID. 323 The client need not know the model used between the metadata server 324 and the storage device. It need only react consistently to any 325 errors in interacting with the storage device. It should both return 326 the layout and error to the metadata server and ask for a new layout. 327 At that point, the metadata server can either hand out a new layout, 328 hand out no layout (forcing the I/O through it), or deny the client 329 further access to the file. 331 2.2.1. Implementation Notes for Synthetic uids/gids 333 The selection method for the synthetic uids and gids to be used for 334 fencing in loosely coupled storage devices is strictly an 335 implementation issue. I.e., an administrator might restrict a range 336 of such ids available to the Lightweight Directory Access Protocol 337 (LDAP) 'uid' field [RFC4519]. She might also be able to choose an id 338 that would never be used to grant acccess. Then when the metadata 339 server had a request to access a file, a SETATTR would be sent to the 340 storage device to set the owner and group of the data file. The user 341 and group might be selected in a round robin fashion from the range 342 of available ids. 344 Those ids would be sent back as ffds_user and ffds_group to the 345 client. And it would present them as the RPC credentials to the 346 storage device. When the client was done accessing the file and the 347 metadata server knew that no other client was accessing the file, it 348 could reset the owner and group to restrict access to the data file. 350 When the metadata server wanted to fence off a client, it would 351 change the synthetic uid and/or gid to the restricted ids. Note that 352 using a restricted id ensures that there is a change of owner and at 353 least one id available that never gets allowed access. 355 Under an AUTH_SYS security model, synthetic uids and gids of 0 SHOULD 356 be avoided. These typically either grant super access to files on a 357 storage device or are mapped to an anonymous id. In the first case, 358 even if the data file is fenced, the client might still be able to 359 access the file. In the second case, multiple ids might be mapped to 360 the anonymous ids. 362 2.2.2. Example of using Synthetic uids/gids 364 The user loghyr creates a file "ompha.c" on the metadata server and 365 it creates a corresponding data file on the storage device. 367 The metadata server entry may look like: 369 -rw-r--r-- 1 loghyr staff 1697 Dec 4 11:31 ompha.c 371 On the storage device, it may be assigned some random synthetic uid/ 372 gid to deny access: 374 -rw-r----- 1 19452 28418 1697 Dec 4 11:31 data_ompha.c 376 When the file is opened on a client, since the layout knows nothing 377 about the user (and does not care), whether loghyr or garbo opens the 378 file does not matter. The owner and group are modified and those 379 values are returned. 381 -rw-r----- 1 1066 1067 1697 Dec 4 11:31 data_ompha.c 383 The set of synthetic gids on the storage device should be selected 384 such that there is no mapping in any of the name services used by the 385 storage device. I.e., each group should have no members. 387 If the layout segment has an iomode of LAYOUTIOMODE4_READ, then the 388 metadata server should return a synthetic uid that is not set on the 389 storage device. Only the synthetic gid would be valid. 391 The client is thus solely responsible for enforcing file permissions 392 in a loosely coupled model. To allow loghyr write access, it will 393 send an RPC to the storage device with a credential of 1066:1067. To 394 allow garbo read access, it will send an RPC to the storage device 395 with a credential of 1067:1067. The value of the uid does not matter 396 as long as it is not the synthetic uid granted it when getting the 397 layout. 399 While pushing the enforcement of permission checking onto the client 400 may seem to weaken security, the client may already be responsible 401 for enforcing permissions before modifications are sent to a server. 402 With cached writes, the client is always responsible for tracking who 403 is modifying a file and making sure to not coalesce requests from 404 multiple users into one request. 406 2.3. State and Locking Models 408 The choice of locking models is governed by the following rules: 410 o Storage devices implementing the NFSv3 and NFSv4.0 protocols are 411 always treated as loosely coupled. 413 o NFSv4.1+ storage devices that do not return the 414 EXCHGID4_FLAG_USE_PNFS_DS flag set to EXCHANGE_ID are indicating 415 that they are to be treated as loosely coupled. From the locking 416 viewpoint they are treated in the same way as NFSv4.0 storage 417 devices. 419 o NFSv4.1+ storage devices that do identify themselves with the 420 EXCHGID4_FLAG_USE_PNFS_DS flag set to EXCHANGE_ID are considered 421 tightly coupled. They would use a back-end control protocol to 422 implement the global stateid model as described in [RFC5661]. 424 2.3.1. Loosely Coupled Locking Model 426 When locking-related operations are requested, they are primarily 427 dealt with by the metadata server, which generates the appropriate 428 stateids. When an NFSv4 version is used as the data access protocol, 429 the metadata server may make stateid-related requests of the storage 430 devices. However, it is not required to do so and the resulting 431 stateids are known only to the metadata server and the storage 432 device. 434 Given this basic structure, locking-related operations are handled as 435 follows: 437 o OPENs are dealt with by the metadata server. Stateids are 438 selected by the metadata server and associated with the client id 439 describing the client's connection to the metadata server. The 440 metadata server may need to interact with the storage device to 441 locate the file to be opened, but no locking-related functionality 442 need be used on the storage device. 444 OPEN_DOWNGRADE and CLOSE only require local execution on the 445 metadata sever. 447 o Advisory byte-range locks can be implemented locally on the 448 metadata server. As in the case of OPENs, the stateids associated 449 with byte-range locks are assigned by the metadata server and only 450 used on the metadata server. 452 o Delegations are assigned by the metadata server which initiates 453 recalls when conflicting OPENs are processed. No storage device 454 involvement is required. 456 o TEST_STATEID and FREE_STATEID are processed locally on the 457 metadata server, without storage device involvement. 459 All I/O operations to the storage device are done using the anonymous 460 stateid. Thus the storage device has no information about the 461 openowner and lockowner responsible for issuing a particular I/O 462 operation. As a result: 464 o Mandatory byte-range locking cannot be supported because the 465 storage device has no way of distinguishing I/O done on behalf of 466 the lock owner from those done by others. 468 o Enforcement of share reservations is the responsibility of the 469 client. Even though I/O is done using the anonymous stateid, the 470 client must ensure that it has a valid stateid associated with the 471 openowner, that allows the I/O being done before issuing the I/O. 473 In the event that a stateid is revoked, the metadata server is 474 responsible for preventing client access, since it has no way of 475 being sure that the client is aware that the stateid in question has 476 been revoked. 478 As the client never receives a stateid generated by a storage device, 479 there is no client lease on the storage device and no prospect of 480 lease expiration, even when access is via NFSv4 protocols. Clients 481 will have leases on the metadata server. In dealing with lease 482 expiration, the metadata server may need to use fencing to prevent 483 revoked stateids from being relied upon by a client unaware of the 484 fact that they have been revoked. 486 2.3.2. Tighly Coupled Locking Model 488 When locking-related operations are requested, they are primarily 489 dealt with by the metadata server, which generates the appropriate 490 stateids. These stateids must be made known to the storage device 491 using control protocol facilities, the details of which are not 492 discussed in this document. 494 Given this basic structure, locking-related operations are handled as 495 follows: 497 o OPENs are dealt with primarily on the metadata server. Stateids 498 are selected by the metadata server and associated with the client 499 id describing the client's connection to the metadata server. The 500 metadata server needs to interact with the storage device to 501 locate the file to be opened, and to make the storage device aware 502 of the association between the metadata-sever-chosen stateid and 503 the client and openowner that it represents. 505 OPEN_DOWNGRADE and CLOSE are executed initially on the metadata 506 server but the state change made must be propagated to the storage 507 device. 509 o Advisory byte-range locks can be implemented locally on the 510 metadata server. As in the case of OPENs, the stateids associated 511 with byte-range locks, are assigned by the metadata server and are 512 available for use on the metadata server. Because I/O operations 513 are allowed to present lock stateids, the metadata server needs 514 the ability to make the storage device aware of the association 515 between the metadata-sever-chosen stateid and the corresponding 516 open stateid it is associated with. 518 o Mandatory byte-range locks can be supported when both the metadata 519 server and the storage devices have the appropriate support. As 520 in the case of advisory byte-range locks, these are assigned by 521 the metadata server and are available for use on the metadata 522 server. To enable mandatory lock enforcement on the storage 523 device, the metadata server needs the ability to make the storage 524 device aware of the association between the metadata-sever-chosen 525 stateid and the client, openowner, and lock (i.e., lockowner, 526 byte-range, lock-type) that it represents. Because I/O operations 527 are allowed to present lock stateids, this information needs to be 528 propagated to all storage devices to which I/O might be directed 529 rather than only to daya storage device that contain the locked 530 region. 532 o Delegations are assigned by the metadata server which initiates 533 recalls when conflicting OPENs are processed. Because I/O 534 operations are allowed to present delegation stateids, the 535 metadata server requires the ability to make the storage device 536 aware of the association between the metadata-server-chosen 537 stateid and the filehandle and delegation type it represents, and 538 to break such an association. 540 o TEST_STATEID is processed locally on the metadata server, without 541 storage device involvement. 543 o FREE_STATEID is processed on the metadata server but the metadata 544 server requires the ability to propagate the request to the 545 corresponding storage devices. 547 Because the client will possess and use stateids valid on the storage 548 device, there will be a client lease on the storage device and the 549 possibility of lease expiration does exist. The best approach for 550 the storage device is to retain these locks as a courtesy. However, 551 if it does not do so, control protocol facilities need to provide the 552 means to synchronize lock state between the metadata server and 553 storage device. 555 Clients will also have leases on the metadata server, which are 556 subject to expiration. In dealing with lease expiration, the 557 metadata server would be expected to use control protocol facilities 558 enabling it to invalidate revoked stateids on the storage device. In 559 the event the client is not responsive, the metadata server may need 560 to use fencing to prevent revoked stateids from being acted upon by 561 the storage device. 563 3. XDR Description of the Flexible File Layout Type 565 This document contains the external data representation (XDR) 566 [RFC4506] description of the flexible file layout type. The XDR 567 description is embedded in this document in a way that makes it 568 simple for the reader to extract into a ready-to-compile form. The 569 reader can feed this document into the following shell script to 570 produce the machine readable XDR description of the flexible file 571 layout type: 573 575 #!/bin/sh 576 grep '^ *///' $* | sed 's?^ */// ??' | sed 's?^ *///$??' 577 579 That is, if the above script is stored in a file called "extract.sh", 580 and this document is in a file called "spec.txt", then the reader can 581 do: 583 sh extract.sh < spec.txt > flex_files_prot.x 585 The effect of the script is to remove leading white space from each 586 line, plus a sentinel sequence of "///". 588 The embedded XDR file header follows. Subsequent XDR descriptions, 589 with the sentinel sequence are embedded throughout the document. 591 Note that the XDR code contained in this document depends on types 592 from the NFSv4.1 nfs4_prot.x file [RFC5662]. This includes both nfs 593 types that end with a 4, such as offset4, length4, etc., as well as 594 more generic types such as uint32_t and uint64_t. 596 3.1. Code Components Licensing Notice 598 Both the XDR description and the scripts used for extracting the XDR 599 description are Code Components as described in Section 4 of "Legal 600 Provisions Relating to IETF Documents" [LEGAL]. These Code 601 Components are licensed according to the terms of that document. 603 605 /// /* 606 /// * Copyright (c) 2012 IETF Trust and the persons identified 607 /// * as authors of the code. All rights reserved. 608 /// * 609 /// * Redistribution and use in source and binary forms, with 610 /// * or without modification, are permitted provided that the 611 /// * following conditions are met: 612 /// * 613 /// * o Redistributions of source code must retain the above 614 /// * copyright notice, this list of conditions and the 615 /// * following disclaimer. 616 /// * 617 /// * o Redistributions in binary form must reproduce the above 618 /// * copyright notice, this list of conditions and the 619 /// * following disclaimer in the documentation and/or other 620 /// * materials provided with the distribution. 621 /// * 622 /// * o Neither the name of Internet Society, IETF or IETF 623 /// * Trust, nor the names of specific contributors, may be 624 /// * used to endorse or promote products derived from this 625 /// * software without specific prior written permission. 626 /// * 627 /// * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS 628 /// * AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED 629 /// * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 630 /// * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 631 /// * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO 632 /// * EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 633 /// * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 634 /// * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 635 /// * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 636 /// * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 637 /// * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF 638 /// * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 639 /// * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING 640 /// * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 641 /// * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 642 /// * 643 /// * This code was derived from RFCTBD10. 644 /// * Please reproduce this note if possible. 645 /// */ 646 /// 647 /// /* 648 /// * flex_files_prot.x 649 /// */ 650 /// 651 /// /* 652 /// * The following include statements are for example only. 653 /// * The actual XDR definition files are generated separately 654 /// * and independently and are likely to have a different name. 655 /// * %#include 656 /// * %#include 657 /// */ 658 /// 660 662 4. Device Addressing and Discovery 664 Data operations to a storage device require the client to know the 665 network address of the storage device. The NFSv4.1+ GETDEVICEINFO 666 operation (Section 18.40 of [RFC5661]) is used by the client to 667 retrieve that information. 669 4.1. ff_device_addr4 671 The ff_device_addr4 data structure is returned by the server as the 672 storage protocol specific opaque field da_addr_body in the 673 device_addr4 structure by a successful GETDEVICEINFO operation. 675 677 /// struct ff_device_versions4 { 678 /// uint32_t ffdv_version; 679 /// uint32_t ffdv_minorversion; 680 /// uint32_t ffdv_rsize; 681 /// uint32_t ffdv_wsize; 682 /// bool ffdv_tightly_coupled; 683 /// }; 684 /// 686 /// struct ff_device_addr4 { 687 /// multipath_list4 ffda_netaddrs; 688 /// ff_device_versions4 ffda_versions<>; 689 /// }; 690 /// 692 694 The ffda_netaddrs field is used to locate the storage device. It 695 MUST be set by the server to a list holding one or more of the device 696 network addresses. 698 The ffda_versions array allows the metadata server to present choices 699 as to NFS version, minor version, and coupling strength to the 700 client. The ffdv_version and ffdv_minorversion represent the NFS 701 protocol to be used to access the storage device. This layout 702 specification defines the semantics for ffdv_versions 3 and 4. If 703 ffdv_version equals 3 then the server MUST set ffdv_minorversion to 0 704 and ffdv_tightly_coupled to false. The client MUST then access the 705 storage device using the NFSv3 protocol [RFC1813]. If ffdv_version 706 equals 4 then the server MUST set ffdv_minorversion to one of the 707 NFSv4 minor version numbers and the client MUST access the storage 708 device using NFSv4 with the specified minor version. 710 Note that while the client might determine that it cannot use any of 711 the configured combinations of ffdv_version, ffdv_minorversion, and 712 ffdv_tightly_coupled, when it gets the device list from the metadata 713 server, there is no way to indicate to the metadata server as to 714 which device it is version incompatible. If however, the client 715 waits until it retrieves the layout from the metadata server, it can 716 at that time clearly identify the storage device in question (see 717 Section 5.3). 719 The ffdv_rsize and ffdv_wsize are used to communicate the maximum 720 rsize and wsize supported by the storage device. As the storage 721 device can have a different rsize or wsize than the metadata server, 722 the ffdv_rsize and ffdv_wsize allow the metadata server to 723 communicate that information on behalf of the storage device. 725 ffdv_tightly_coupled informs the client as to whether the metadata 726 server is tightly coupled with the storage devices or not. Note that 727 even if the data protocol is at least NFSv4.1, it may still be the 728 case that there is loose coupling is in effect. If 729 ffdv_tightly_coupled is not set, then the client MUST commit writes 730 to the storage devices for the file before sending a LAYOUTCOMMIT to 731 the metadata server. I.e., the writes MUST be committed by the 732 client to stable storage via issuing WRITEs with stable_how == 733 FILE_SYNC or by issuing a COMMIT after WRITEs with stable_how != 734 FILE_SYNC (see Section 3.3.7 of [RFC1813]). 736 4.2. Storage Device Multipathing 738 The flexible file layout type supports multipathing to multiple 739 storage device addresses. Storage device level multipathing is used 740 for bandwidth scaling via trunking and for higher availability of use 741 in the event of a storage device failure. Multipathing allows the 742 client to switch to another storage device address which may be that 743 of another storage device that is exporting the same data stripe 744 unit, without having to contact the metadata server for a new layout. 746 To support storage device multipathing, ffda_netaddrs contains an 747 array of one or more storage device network addresses. This array 748 (data type multipath_list4) represents a list of storage devices 749 (each identified by a network address), with the possibility that 750 some storage device will appear in the list multiple times. 752 The client is free to use any of the network addresses as a 753 destination to send storage device requests. If some network 754 addresses are less desirable paths to the data than others, then the 755 MDS SHOULD NOT include those network addresses in ffda_netaddrs. If 756 less desirable network addresses exist to provide failover, the 757 RECOMMENDED method to offer the addresses is to provide them in a 758 replacement device-ID-to-device-address mapping, or a replacement 759 device ID. When a client finds no response from the storage device 760 using all addresses available in ffda_netaddrs, it SHOULD send a 761 GETDEVICEINFO to attempt to replace the existing device-ID-to-device- 762 address mappings. If the MDS detects that all network paths 763 represented by ffda_netaddrs are unavailable, the MDS SHOULD send a 764 CB_NOTIFY_DEVICEID (if the client has indicated it wants device ID 765 notifications for changed device IDs) to change the device-ID-to- 766 device-address mappings to the available addresses. If the device ID 767 itself will be replaced, the MDS SHOULD recall all layouts with the 768 device ID, and thus force the client to get new layouts and device ID 769 mappings via LAYOUTGET and GETDEVICEINFO. 771 Generally, if two network addresses appear in ffda_netaddrs, they 772 will designate the same storage device. When the storage device is 773 accessed over NFSv4.1 or a higher minor version, the two storage 774 device addresses will support the implementation of client ID or 775 session trunking (the latter is RECOMMENDED) as defined in [RFC5661]. 776 The two storage device addresses will share the same server owner or 777 major ID of the server owner. It is not always necessary for the two 778 storage device addresses to designate the same storage device with 779 trunking being used. For example, the data could be read-only, and 780 the data consist of exact replicas. 782 5. Flexible File Layout Type 784 The layout4 type is defined in [RFC5662] as follows: 786 788 enum layouttype4 { 789 LAYOUT4_NFSV4_1_FILES = 1, 790 LAYOUT4_OSD2_OBJECTS = 2, 791 LAYOUT4_BLOCK_VOLUME = 3, 792 LAYOUT4_FLEX_FILES = 4 793 [[RFC Editor: please modify the LAYOUT4_FLEX_FILES 794 to be the layouttype assigned by IANA]] 795 }; 797 struct layout_content4 { 798 layouttype4 loc_type; 799 opaque loc_body<>; 800 }; 802 struct layout4 { 803 offset4 lo_offset; 804 length4 lo_length; 805 layoutiomode4 lo_iomode; 806 layout_content4 lo_content; 807 }; 809 810 This document defines structure associated with the layouttype4 value 811 LAYOUT4_FLEX_FILES. [RFC5661] specifies the loc_body structure as an 812 XDR type "opaque". The opaque layout is uninterpreted by the generic 813 pNFS client layers, but is interpreted by the flexible file layout 814 type implementation. This section defines the structure of this 815 otherwise opaque value, ff_layout4. 817 5.1. ff_layout4 819 821 /// const FF_FLAGS_NO_LAYOUTCOMMIT = 0x00000001; 822 /// const FF_FLAGS_NO_IO_THRU_MDS = 0x00000002; 823 /// const FF_FLAGS_NO_READ_IO = 0x00000004; 824 /// const FF_FLAGS_WRITE_ONE_MIRROR = 0x00000008; 826 /// typedef uint32_t ff_flags4; 827 /// 829 /// struct ff_data_server4 { 830 /// deviceid4 ffds_deviceid; 831 /// uint32_t ffds_efficiency; 832 /// stateid4 ffds_stateid; 833 /// nfs_fh4 ffds_fh_vers<>; 834 /// fattr4_owner ffds_user; 835 /// fattr4_owner_group ffds_group; 836 /// }; 837 /// 839 /// struct ff_mirror4 { 840 /// ff_data_server4 ffm_data_servers<>; 841 /// }; 842 /// 844 /// struct ff_layout4 { 845 /// length4 ffl_stripe_unit; 846 /// ff_mirror4 ffl_mirrors<>; 847 /// ff_flags4 ffl_flags; 848 /// uint32_t ffl_stats_collect_hint; 849 /// }; 850 /// 852 854 The ff_layout4 structure specifies a layout over a set of mirrored 855 copies of that portion of the data file described in the current 856 layout segment. This mirroring protects against loss of data in 857 layout segments. Note that while not explicitly shown in the above 858 XDR, each layout4 element returned in the logr_layout array of 859 LAYOUTGET4res (see Section 18.43.1 of [RFC5661]) describes a layout 860 segment. Hence each ff_layout4 also describes a layout segment. 862 It is possible that the file is concatenated from more than one 863 layout segment. Each layout segment MAY represent different striping 864 parameters, applying respectively only to the layout segment byte 865 range. 867 The ffl_stripe_unit field is the stripe unit size in use for the 868 current layout segment. The number of stripes is given inside each 869 mirror by the number of elements in ffm_data_servers. If the number 870 of stripes is one, then the value for ffl_stripe_unit MUST default to 871 zero. The only supported mapping scheme is sparse and is detailed in 872 Section 6. Note that there is an assumption here that both the 873 stripe unit size and the number of stripes is the same across all 874 mirrors. 876 The ffl_mirrors field is the array of mirrored storage devices which 877 provide the storage for the current stripe, see Figure 1. 879 The ffl_stats_collect_hint field provides a hint to the client on how 880 often the server wants it to report LAYOUTSTATS for a file. The time 881 is in seconds. 883 +-----------+ 884 | | 885 | | 886 | File | 887 | | 888 | | 889 +-----+-----+ 890 | 891 +------------+------------+ 892 | | 893 +----+-----+ +-----+----+ 894 | Mirror 1 | | Mirror 2 | 895 +----+-----+ +-----+----+ 896 | | 897 +-----------+ +-----------+ 898 |+-----------+ |+-----------+ 899 ||+-----------+ ||+-----------+ 900 +|| Storage | +|| Storage | 901 +| Devices | +| Devices | 902 +-----------+ +-----------+ 904 Figure 1 906 The ffs_mirrors field represents an array of state information for 907 each mirrored copy of the current layout segment. Each element is 908 described by a ff_mirror4 type. 910 ffds_deviceid provides the deviceid of the storage device holding the 911 data file. 913 ffds_fh_vers is an array of filehandles of the data file matching to 914 the available NFS versions on the given storage device. There MUST 915 be exactly as many elements in ffds_fh_vers as there are in 916 ffda_versions. Each element of the array corresponds to a particular 917 combination of ffdv_version, ffdv_minorversion, and 918 ffdv_tightly_coupled provided for the device. The array allows for 919 server implementations which have different filehandles for different 920 combinations of version, minor version, and coupling strength. See 921 Section 5.3 for how to handle versioning issues between the client 922 and storage devices. 924 For tight coupling, ffds_stateid provides the stateid to be used by 925 the client to access the file. For loose coupling and a NFSv4 926 storage device, the client may use an anonymous stateid to perform I/ 927 O on the storage device as there is no use for the metadata server 928 stateid (no control protocol). In such a scenario, the server MUST 929 set the ffds_stateid to be the anonymous stateid. 931 This specification of the ffds_stateid restricts both models for 932 NFSv4.x storage protocols: 934 loosely couple: the stateid has to be an anonymous stateid, 936 tightly couple: the stateid has to be a global stateid. 938 These stem from a mismatch of ffds_stateid being a singleton and 939 ffds_fh_vers being an array - each open file on the storage device 940 might need an open stateid. As there are established loosely coupled 941 implementations of this version of the protocol, it can not be fixed. 942 If an implementation needs a different statedid per file handle, then 943 this issue will require a new version of the protocol. 945 For loosely coupled storage devices, ffds_user and ffds_group provide 946 the synthetic user and group to be used in the RPC credentials that 947 the client presents to the storage device to access the data files. 948 For tightly coupled storage devices, the user and group on the 949 storage device will be the same as on the metadata server. I.e., if 950 ffdv_tightly_coupled (see Section 4.1) is set, then the client MUST 951 ignore both ffds_user and ffds_group. 953 The allowed values for both ffds_user and ffds_group are specified in 954 Section 5.9 of [RFC5661]. For NFSv3 compatibility, user and group 955 strings that consist of decimal numeric values with no leading zeros 956 can be given a special interpretation by clients and servers that 957 choose to provide such support. The receiver may treat such a user 958 or group string as representing the same user as would be represented 959 by an NFSv3 uid or gid having the corresponding numeric value. Note 960 that if using Kerberos for security, the expectation is that these 961 values will be a name@domain string. 963 ffds_efficiency describes the metadata server's evaluation as to the 964 effectiveness of each mirror. Note that this is per layout and not 965 per device as the metric may change due to perceived load, 966 availability to the metadata server, etc. Higher values denote 967 higher perceived utility. The way the client can select the best 968 mirror to access is discussed in Section 8.1. 970 ffl_flags is a bitmap that allows the metadata server to inform the 971 client of particular conditions that may result from the more or less 972 tight coupling of the storage devices. 974 FF_FLAGS_NO_LAYOUTCOMMIT: can be set to indicate that the client is 975 not required to send LAYOUTCOMMIT to the metadata server. 977 F_FLAGS_NO_IO_THRU_MDS: can be set to indicate that the client 978 should not send I/O operations to the metadata server. I.e., even 979 if the client could determine that there was a network diconnect 980 to a storage device, the client should not try to proxy the I/O 981 through the metadata server. 983 FF_FLAGS_NO_READ_IO: can be set to indicate that the client should 984 not send READ requests with the layouts of iomode 985 LAYOUTIOMODE4_RW. Instead, it should request a layout of iomode 986 LAYOUTIOMODE4_READ from the metadata server. 988 FF_FLAGS_WRITE_ONE_MIRROR: can be set to indicate that the client 989 only needs to update one of the mirrors (see Section 8.2). 991 5.1.1. Error Codes from LAYOUTGET 993 [RFC5661] provides little guidance as to how the client is to proceed 994 with a LAYOUTEGT which returns an error of either 995 NFS4ERR_LAYOUTTRYLATER, NFS4ERR_LAYOUTUNAVAILABLE, and NFS4ERR_DELAY. 996 Within the context of this document: 998 NFS4ERR_LAYOUTUNAVAILABLE: there is no layout available and the I/O 999 is to go to the metadata server. Note that it is possible to have 1000 had a layout before a recall and not after. 1002 NFS4ERR_LAYOUTTRYLATER: there is some issue preventing the layout 1003 from being granted. If the client already has an appropriate 1004 layout, it should continue with I/O to the storage devices. 1006 NFS4ERR_DELAY: there is some issue preventing the layout from being 1007 granted. If the client already has an appropriate layout, it 1008 should not continue with I/O to the storage devices. 1010 5.1.2. Client Interactions with FF_FLAGS_NO_IO_THRU_MDS 1012 Even if the metadata server provides the FF_FLAGS_NO_IO_THRU_MDS, 1013 flag, the client can still perform I/O to the metadata server. The 1014 flag is at best a hint. The flag is indicating to the client that 1015 the metadata server most likely wants to separate the metadata I/O 1016 from the data I/O to increase the performance of the metadata 1017 operations. If the metadata server detects that the client is 1018 performing I/O against it despite the use of the 1019 FF_FLAGS_NO_IO_THRU_MDS flag, it can recall the layout and either not 1020 set the flag on the new layout or not provide a layout (perhaps the 1021 intent was for the server to temporarily prevent data I/O to meet 1022 some goal). The client's I/O would then proceed according to the 1023 status codes as outlined in Section 5.1.1. 1025 5.2. Interactions Between Devices and Layouts 1027 In [RFC5661], the file layout type is defined such that the 1028 relationship between multipathing and filehandles can result in 1029 either 0, 1, or N filehandles (see Section 13.3). Some rationals for 1030 this are clustered servers which share the same filehandle or 1031 allowing for multiple read-only copies of the file on the same 1032 storage device. In the flexible file layout type, while there is an 1033 array of filehandles, they are independent of the multipathing being 1034 used. If the metadata server wants to provide multiple read-only 1035 copies of the same file on the same storage device, then it should 1036 provide multiple ff_device_addr4, each as a mirror. The client can 1037 then determine that since the ffds_fh_vers are different, then there 1038 are multiple copies of the file for the current layout segment 1039 available. 1041 5.3. Handling Version Errors 1043 When the metadata server provides the ffda_versions array in the 1044 ff_device_addr4 (see Section 4.1), the client is able to determine if 1045 it can not access a storage device with any of the supplied 1046 combinations of ffdv_version, ffdv_minorversion, and 1047 ffdv_tightly_coupled. However, due to the limitations of reporting 1048 errors in GETDEVICEINFO (see Section 18.40 in [RFC5661], the client 1049 is not able to specify which specific device it can not communicate 1050 with over one of the provided ffdv_version and ffdv_minorversion 1051 combinations. Using ff_ioerr4 (see Section 9.1.1 inside either the 1052 LAYOUTRETURN (see Section 18.44 of [RFC5661]) or the LAYOUTERROR (see 1053 Section 15.6 of [RFC7862] and Section 10 of this document), the 1054 client can isolate the problematic storage device. 1056 The error code to return for LAYOUTRETURN and/or LAYOUTERROR is 1057 NFS4ERR_MINOR_VERS_MISMATCH. It does not matter whether the mismatch 1058 is a major version (e.g., client can use NFSv3 but not NFSv4) or 1059 minor version (e.g., client can use NFSv4.1 but not NFSv4.2), the 1060 error indicates that for all the supplied combinations for 1061 ffdv_version and ffdv_minorversion, the client can not communicate 1062 with the storage device. The client can retry the GETDEVICEINFO to 1063 see if the metadata server can provide a different combination or it 1064 can fall back to doing the I/O through the metadata server. 1066 6. Striping via Sparse Mapping 1068 While other layout types support both dense and sparse mapping of 1069 logical offsets to physical offsets within a file (see for example 1070 Section 13.4 of [RFC5661]), the flexible file layout type only 1071 supports a sparse mapping. 1073 With sparse mappings, the logical offset within a file (L) is also 1074 the physical offset on the storage device. As detailed in 1075 Section 13.4.4 of [RFC5661], this results in holes across each 1076 storage device which does not contain the current stripe index. 1078 L: logical offset into the file 1080 W: stripe width 1081 W = number of elements in ffm_data_servers 1083 S: number of bytes in a stripe 1084 S = W * ffl_stripe_unit 1086 N: stripe number 1087 N = L / S 1089 7. Recovering from Client I/O Errors 1091 The pNFS client may encounter errors when directly accessing the 1092 storage devices. However, it is the responsibility of the metadata 1093 server to recover from the I/O errors. When the LAYOUT4_FLEX_FILES 1094 layout type is used, the client MUST report the I/O errors to the 1095 server at LAYOUTRETURN time using the ff_ioerr4 structure (see 1096 Section 9.1.1). 1098 The metadata server analyzes the error and determines the required 1099 recovery operations such as recovering media failures or 1100 reconstructing missing data files. 1102 The metadata server SHOULD recall any outstanding layouts to allow it 1103 exclusive write access to the stripes being recovered and to prevent 1104 other clients from hitting the same error condition. In these cases, 1105 the server MUST complete recovery before handing out any new layouts 1106 to the affected byte ranges. 1108 Although the client implementation has the option to propagate a 1109 corresponding error to the application that initiated the I/O 1110 operation and drop any unwritten data, the client should attempt to 1111 retry the original I/O operation by either requesting a new layout or 1112 sending the I/O via regular NFSv4.1+ READ or WRITE operations to the 1113 metadata server. The client SHOULD attempt to retrieve a new layout 1114 and retry the I/O operation using the storage device first and only 1115 if the error persists, retry the I/O operation via the metadata 1116 server. 1118 8. Mirroring 1120 The flexible file layout type has a simple model in place for the 1121 mirroring of the file data constrained by a layout segment. There is 1122 no assumption that each copy of the mirror is stored identically on 1123 the storage devices. For example, one device might employ 1124 compression or deduplication on the data. However, the over the wire 1125 transfer of the file contents MUST appear identical. Note, this is a 1126 constraint of the selected XDR representation in which each mirrored 1127 copy of the layout segment has the same striping pattern (see 1128 Figure 1). 1130 The metadata server is responsible for determining the number of 1131 mirrored copies and the location of each mirror. While the client 1132 may provide a hint to how many copies it wants (see Section 12), the 1133 metadata server can ignore that hint and in any event, the client has 1134 no means to dictate neither the storage device (which also means the 1135 coupling and/or protocol levels to access the layout segments) nor 1136 the location of said storage device. 1138 The updating of mirrored layout segments is done via client-side 1139 mirroring. With this approach, the client is responsible for making 1140 sure modifications are made on all copies of the layout segments it 1141 is informed of via the layout. If a layout segment is being 1142 resilvered to a storage device, that mirrored copy will not be in the 1143 layout. Thus the metadata server MUST update that copy until the 1144 client is presented it in a layout. If the FF_FLAGS_WRITE_ONE_MIRROR 1145 is set in ffl_flags, the client need only update one of the mirrors 1146 (see Section 8.2. If the client is writing to the layout segments 1147 via the metadata server, then the metadata server MUST update all 1148 copies of the mirror. As seen in Section 8.3, during the 1149 resilvering, the layout is recalled, and the client has to make 1150 modifications via the metadata server. 1152 8.1. Selecting a Mirror 1154 When the metadata server grants a layout to a client, it MAY let the 1155 client know how fast it expects each mirror to be once the request 1156 arrives at the storage devices via the ffds_efficiency member. While 1157 the algorithms to calculate that value are left to the metadata 1158 server implementations, factors that could contribute to that 1159 calculation include speed of the storage device, physical memory 1160 available to the device, operating system version, current load, etc. 1162 However, what should not be involved in that calculation is a 1163 perceived network distance between the client and the storage device. 1164 The client is better situated for making that determination based on 1165 past interaction with the storage device over the different available 1166 network interfaces between the two. I.e., the metadata server might 1167 not know about a transient outage between the client and storage 1168 device because it has no presence on the given subnet. 1170 As such, it is the client which decides which mirror to access for 1171 reading the file. The requirements for writing to a mirrored layout 1172 segments are presented below. 1174 8.2. Writing to Mirrors 1176 8.2.1. Single Storage Device Updates Mirrors 1178 If the FF_FLAGS_WRITE_ONE_MIRROR flag in ffl_flags is set, the client 1179 only needs to update one of the copies of the layout segment. For 1180 this case, the storage device MUST ensure that all copies of the 1181 mirror are updated when any one of the mirrors is updated. If the 1182 storage device gets an error when updating one of the mirrors, then 1183 it MUST inform the client that the original WRITE had an error. The 1184 client then MUST inform the metadata server (see Section 8.2.3. The 1185 client's responsibility with resepect to COMMIT is explained in 1186 Section 8.2.4. The client may choose any one of the mirrors and may 1187 use ffds_efficiency in the same manner as for reading when making 1188 this choice. 1190 8.2.2. Single Storage Device Updates Mirrors 1192 If the FF_FLAGS_WRITE_ONE_MIRROR flag in ffl_flags is not set, the 1193 client is responsible for updating all mirrored copies of the layout 1194 segments that it is given in the layout. A single failed update is 1195 sufficient to fail the entire operation. If all but one copy is 1196 updated successfully and the last one provides an error, then the 1197 client needs to inform the metadata server about the error via either 1198 LAYOUTRETURN or LAYOUTERROR that the update failed to that storage 1199 device. If the client is updating the mirrors serially, then it 1200 SHOULD stop at the first error encountered and report that to the 1201 metadata server. If the client is updating the mirrors in parallel, 1202 then it SHOULD wait until all storage devices respond such that it 1203 can report all errors encountered during the update. 1205 8.2.3. Handling Write Errors 1207 When the client reports a write error to the metadata server, the 1208 metadata server is responsible for determining if it wants to remove 1209 the errant mirror from the layout, if the mirror has recovered from 1210 some transient error, etc. When the client tries to get a new 1211 layout, the metadata server informs it of the decision by the 1212 contents of the layout. The client MUST NOT make any assumptions 1213 that the contents of the previous layout will match those of the new 1214 one. If it has updates that were not committed to all mirrors, then 1215 it MUST resend those updates to all mirrors. 1217 There is no provision in the protocol for the metadata server to 1218 directly determine that the client has or has not recovered from an 1219 error. I.e., assume that the storage device was network partitioned 1220 from the client and all of the copies are successfully updated after 1221 the error was reported. There is no mechanism for the client to 1222 report that fact and the metadata server is forced to repair the file 1223 across the mirror. 1225 If the client supports NFSv4.2, it can use LAYOUTERROR and 1226 LAYOUTRETURN to provide hints to the metadata server about the 1227 recovery efforts. A LAYOUTERROR on a file is for a non-fatal error. 1228 A subsequent LAYOUTRETURN without a ff_ioerr4 indicates that the 1229 client successfully replayed the I/O to all mirrors. Any 1230 LAYOUTRETURN with a ff_ioerr4 is an error that the metadata server 1231 needs to repair. The client MUST be prepared for the LAYOUTERROR to 1232 trigger a CB_LAYOUTRECALL if the metadata server determines it needs 1233 to start repairing the file. 1235 8.2.4. Handling Write COMMITs 1237 When stable writes are done to the metadata server or to a single 1238 replica (if allowed by the use of FF_FLAGS_WRITE_ONE_MIRROR ), it is 1239 the responsibility of the receiving node to propagate the written 1240 data stably, before replying to the client. 1242 In the corresponding cases in which unstable writes are done, the 1243 receiving node does not have any such obligation, although it may 1244 choose to asynchronously propagate the updates. However, once a 1245 COMMIT is replied to, all replicas must reflect the writes that have 1246 been done, and these data must have been committed to stable storage 1247 on all replicas. 1249 In order to avoid situations in which stale data is read from 1250 replicas to which writes have not been propagated: 1252 o A client which has outstanding unstable writes made to single node 1253 (metadata server or storage device) MUST do all reads from that 1254 same node. 1256 o When writes are flushed to the server, for example to implement, 1257 close-to-open semantics, a COMMIT must be done by the client to 1258 ensure that up-to-date written data will be available irrespective 1259 of the particular replica read. 1261 8.3. Metadata Server Resilvering of the File 1263 The metadata server may elect to create a new mirror of the layout 1264 segments at any time. This might be to resilver a copy on a storage 1265 device which was down for servicing, to provide a copy of the layout 1266 segments on storage with different storage performance 1267 characteristics, etc. As the client will not be aware of the new 1268 mirror and the metadata server will not be aware of updates that the 1269 client is making to the layout segments, the metadata server MUST 1270 recall the writable layout segment(s) that it is resilvering. If the 1271 client issues a LAYOUTGET for a writable layout segment which is in 1272 the process of being resilvered, then the metadata server can deny 1273 that request with a NFS4ERR_LAYOUTUNAVAILABLE. The client would then 1274 have to perform the I/O through the metadata server. 1276 9. Flexible Files Layout Type Return 1278 layoutreturn_file4 is used in the LAYOUTRETURN operation to convey 1279 layout-type specific information to the server. It is defined in 1280 Section 18.44.1 of [RFC5661] as follows: 1282 1283 /* Constants used for LAYOUTRETURN and CB_LAYOUTRECALL */ 1284 const LAYOUT4_RET_REC_FILE = 1; 1285 const LAYOUT4_RET_REC_FSID = 2; 1286 const LAYOUT4_RET_REC_ALL = 3; 1288 enum layoutreturn_type4 { 1289 LAYOUTRETURN4_FILE = LAYOUT4_RET_REC_FILE, 1290 LAYOUTRETURN4_FSID = LAYOUT4_RET_REC_FSID, 1291 LAYOUTRETURN4_ALL = LAYOUT4_RET_REC_ALL 1292 }; 1294 struct layoutreturn_file4 { 1295 offset4 lrf_offset; 1296 length4 lrf_length; 1297 stateid4 lrf_stateid; 1298 /* layouttype4 specific data */ 1299 opaque lrf_body<>; 1300 }; 1302 union layoutreturn4 switch(layoutreturn_type4 lr_returntype) { 1303 case LAYOUTRETURN4_FILE: 1304 layoutreturn_file4 lr_layout; 1305 default: 1306 void; 1307 }; 1309 struct LAYOUTRETURN4args { 1310 /* CURRENT_FH: file */ 1311 bool lora_reclaim; 1312 layoutreturn_stateid lora_recallstateid; 1313 layouttype4 lora_layout_type; 1314 layoutiomode4 lora_iomode; 1315 layoutreturn4 lora_layoutreturn; 1316 }; 1318 1320 If the lora_layout_type layout type is LAYOUT4_FLEX_FILES and the 1321 lr_returntype is LAYOUTRETURN4_FILE, then the lrf_body opaque value 1322 is defined by ff_layoutreturn4 (See Section 9.3). It allows the 1323 client to report I/O error information or layout usage statistics 1324 back to the metadata server as defined below. Note that while the 1325 data structures are built on concepts introduced in NFSv4.2, the 1326 effective discriminated union (lora_layout_type combined with 1327 ff_layoutreturn4) allows for a NFSv4.1 metadata server to utilize the 1328 data. 1330 9.1. I/O Error Reporting 1332 9.1.1. ff_ioerr4 1334 1336 /// struct ff_ioerr4 { 1337 /// offset4 ffie_offset; 1338 /// length4 ffie_length; 1339 /// stateid4 ffie_stateid; 1340 /// device_error4 ffie_errors<>; 1341 /// }; 1342 /// 1344 1346 Recall that [RFC7862] defines device_error4 as: 1348 1350 struct device_error4 { 1351 deviceid4 de_deviceid; 1352 nfsstat4 de_status; 1353 nfs_opnum4 de_opnum; 1354 }; 1356 1358 The ff_ioerr4 structure is used to return error indications for data 1359 files that generated errors during data transfers. These are hints 1360 to the metadata server that there are problems with that file. For 1361 each error, ffie_errors.de_deviceid, ffie_offset, and ffie_length 1362 represent the storage device and byte range within the file in which 1363 the error occurred; ffie_errors represents the operation and type of 1364 error. The use of device_error4 is described in Section 15.6 of 1365 [RFC7862]. 1367 Even though the storage device might be accessed via NFSv3 and 1368 reports back NFSv3 errors to the client, the client is responsible 1369 for mapping these to appropriate NFSv4 status codes as de_status. 1370 Likewise, the NFSv3 operations need to be mapped to equivalent NFSv4 1371 operations. 1373 9.2. Layout Usage Statistics 1374 9.2.1. ff_io_latency4 1376 1378 /// struct ff_io_latency4 { 1379 /// uint64_t ffil_ops_requested; 1380 /// uint64_t ffil_bytes_requested; 1381 /// uint64_t ffil_ops_completed; 1382 /// uint64_t ffil_bytes_completed; 1383 /// uint64_t ffil_bytes_not_delivered; 1384 /// nfstime4 ffil_total_busy_time; 1385 /// nfstime4 ffil_aggregate_completion_time; 1386 /// }; 1387 /// 1389 1391 Both operation counts and bytes transferred are kept in the 1392 ff_io_latency4. READ operations are used for read latencies. Both 1393 WRITE and COMMIT operations are used for write latencies. 1394 "Requested" counters track what the client is attempting to do and 1395 "completed" counters track what was done. Note that there is no 1396 requirement that the client only report completed results that have 1397 matching requested results from the reported period. 1399 ffil_bytes_not_delivered is used to track the aggregate number of 1400 bytes requested by not fulfilled due to error conditions. 1401 ffil_total_busy_time is the aggregate time spent with outstanding RPC 1402 calls, ffil_aggregate_completion_time is the sum of all latencies for 1403 completed RPC calls. 1405 Note that LAYOUTSTATS are cumulative, i.e., not reset each time the 1406 operation is sent. If two LAYOUTSTATS ops for the same file, layout 1407 stateid, and originating from the same NFS client are processed at 1408 the same time by the metadata server, then the one containing the 1409 larger values contains the most recent time series data. 1411 9.2.2. ff_layoutupdate4 1413 1414 /// struct ff_layoutupdate4 { 1415 /// netaddr4 ffl_addr; 1416 /// nfs_fh4 ffl_fhandle; 1417 /// ff_io_latency4 ffl_read; 1418 /// ff_io_latency4 ffl_write; 1419 /// nfstime4 ffl_duration; 1420 /// bool ffl_local; 1421 /// }; 1422 /// 1424 1426 ffl_addr differentiates which network address the client connected to 1427 on the storage device. In the case of multipathing, ffl_fhandle 1428 indicates which read-only copy was selected. ffl_read and ffl_write 1429 convey the latencies respectively for both read and write operations. 1430 ffl_duration is used to indicate the time period over which the 1431 statistics were collected. ffl_local if true indicates that the I/O 1432 was serviced by the client's cache. This flag allows the client to 1433 inform the metadata server about "hot" access to a file it would not 1434 normally be allowed to report on. 1436 9.2.3. ff_iostats4 1438 1440 /// struct ff_iostats4 { 1441 /// offset4 ffis_offset; 1442 /// length4 ffis_length; 1443 /// stateid4 ffis_stateid; 1444 /// io_info4 ffis_read; 1445 /// io_info4 ffis_write; 1446 /// deviceid4 ffis_deviceid; 1447 /// ff_layoutupdate4 ffis_layoutupdate; 1448 /// }; 1449 /// 1451 1453 Recall that [RFC7862] defines io_info4 as: 1455 1457 struct io_info4 { 1458 uint64_t ii_count; 1459 uint64_t ii_bytes; 1460 }; 1461 1463 With pNFS, data transfers are performed directly between the pNFS 1464 client and the storage devices. Therefore, the metadata server has 1465 no direct knowledge to the I/O operations being done and thus can not 1466 create on its own statistical information about client I/O to 1467 optimize data storage location. ff_iostats4 MAY be used by the 1468 client to report I/O statistics back to the metadata server upon 1469 returning the layout. 1471 Since it is not feasible for the client to report every I/O that used 1472 the layout, the client MAY identify "hot" byte ranges for which to 1473 report I/O statistics. The definition and/or configuration mechanism 1474 of what is considered "hot" and the size of the reported byte range 1475 is out of the scope of this document. It is suggested for client 1476 implementation to provide reasonable default values and an optional 1477 run-time management interface to control these parameters. For 1478 example, a client can define the default byte range resolution to be 1479 1 MB in size and the thresholds for reporting to be 1 MB/second or 10 1480 I/O operations per second. 1482 For each byte range, ffis_offset and ffis_length represent the 1483 starting offset of the range and the range length in bytes. 1484 ffis_read.ii_count, ffis_read.ii_bytes, ffis_write.ii_count, and 1485 ffis_write.ii_bytes represent, respectively, the number of contiguous 1486 read and write I/Os and the respective aggregate number of bytes 1487 transferred within the reported byte range. 1489 The combination of ffis_deviceid and ffl_addr uniquely identifies 1490 both the storage path and the network route to it. Finally, the 1491 ffl_fhandle allows the metadata server to differentiate between 1492 multiple read-only copies of the file on the same storage device. 1494 9.3. ff_layoutreturn4 1496 1498 /// struct ff_layoutreturn4 { 1499 /// ff_ioerr4 fflr_ioerr_report<>; 1500 /// ff_iostats4 fflr_iostats_report<>; 1501 /// }; 1502 /// 1504 1506 When data file I/O operations fail, fflr_ioerr_report<> is used to 1507 report these errors to the metadata server as an array of elements of 1508 type ff_ioerr4. Each element in the array represents an error that 1509 occurred on the data file identified by ffie_errors.de_deviceid. If 1510 no errors are to be reported, the size of the fflr_ioerr_report<> 1511 array is set to zero. The client MAY also use fflr_iostats_report<> 1512 to report a list of I/O statistics as an array of elements of type 1513 ff_iostats4. Each element in the array represents statistics for a 1514 particular byte range. Byte ranges are not guaranteed to be disjoint 1515 and MAY repeat or intersect. 1517 10. Flexible Files Layout Type LAYOUTERROR 1519 If the client is using NFSv4.2 to communicate with the metadata 1520 server, then instead of waiting for a LAYOUTRETURN to send error 1521 information to the metadata server (see Section 9.1), it MAY use 1522 LAYOUTERROR (see Section 15.6 of [RFC7862]) to communicate that 1523 information. For the flexible files layout type, this means that 1524 LAYOUTERROR4args is treated the same as ff_ioerr4. 1526 11. Flexible Files Layout Type LAYOUTSTATS 1528 If the client is using NFSv4.2 to communicate with the metadata 1529 server, then instead of waiting for a LAYOUTRETURN to send I/O 1530 statistics to the metadata server (see Section 9.2), it MAY use 1531 LAYOUTSTATS (see Section 15.7 of [RFC7862]) to communicate that 1532 information. For the flexible files layout type, this means that 1533 LAYOUTSTATS4args.lsa_layoutupdate is overloaded with the same 1534 contents as in ffis_layoutupdate. 1536 12. Flexible File Layout Type Creation Hint 1538 The layouthint4 type is defined in the [RFC5661] as follows: 1540 1542 struct layouthint4 { 1543 layouttype4 loh_type; 1544 opaque loh_body<>; 1545 }; 1547 1549 The layouthint4 structure is used by the client to pass a hint about 1550 the type of layout it would like created for a particular file. If 1551 the loh_type layout type is LAYOUT4_FLEX_FILES, then the loh_body 1552 opaque value is defined by the ff_layouthint4 type. 1554 12.1. ff_layouthint4 1556 1558 /// union ff_mirrors_hint switch (bool ffmc_valid) { 1559 /// case TRUE: 1560 /// uint32_t ffmc_mirrors; 1561 /// case FALSE: 1562 /// void; 1563 /// }; 1564 /// 1566 /// struct ff_layouthint4 { 1567 /// ff_mirrors_hint fflh_mirrors_hint; 1568 /// }; 1569 /// 1571 1573 This type conveys hints for the desired data map. All parameters are 1574 optional so the client can give values for only the parameter it 1575 cares about. 1577 13. Recalling a Layout 1579 While Section 12.5.5 of [RFC5661] discusses layout type independent 1580 reasons for recalling a layout, the flexible file layout type 1581 metadata server should recall outstanding layouts in the following 1582 cases: 1584 o When the file's security policy changes, i.e., Access Control 1585 Lists (ACLs) or permission mode bits are set. 1587 o When the file's layout changes, rendering outstanding layouts 1588 invalid. 1590 o When existing layouts are inconsistent with the need to enforce 1591 locking constraints. 1593 o When existing layouts are inconsistent with the requirements 1594 regarding resilvering as described in Section 8.3. 1596 13.1. CB_RECALL_ANY 1598 The metadata server can use the CB_RECALL_ANY callback operation to 1599 notify the client to return some or all of its layouts. Section 22.3 1600 of [RFC5661] defines the allowed types of the "NFSv4 Recallable 1601 Object Types Registry". 1603 1605 /// const RCA4_TYPE_MASK_FF_LAYOUT_MIN = 16; 1606 /// const RCA4_TYPE_MASK_FF_LAYOUT_MAX = 17; 1607 [[RFC Editor: please insert assigned constants]] 1608 /// 1610 struct CB_RECALL_ANY4args { 1611 uint32_t craa_layouts_to_keep; 1612 bitmap4 craa_type_mask; 1613 }; 1615 1617 Typically, CB_RECALL_ANY will be used to recall client state when the 1618 server needs to reclaim resources. The craa_type_mask bitmap 1619 specifies the type of resources that are recalled and the 1620 craa_layouts_to_keep value specifies how many of the recalled 1621 flexible file layouts the client is allowed to keep. The flexible 1622 file layout type mask flags are defined as follows: 1624 1626 /// enum ff_cb_recall_any_mask { 1627 /// FF_RCA4_TYPE_MASK_READ = -2, 1628 /// FF_RCA4_TYPE_MASK_RW = -1 1629 [[RFC Editor: please insert assigned constants]] 1630 /// }; 1631 /// 1633 1635 They represent the iomode of the recalled layouts. In response, the 1636 client SHOULD return layouts of the recalled iomode that it needs the 1637 least, keeping at most craa_layouts_to_keep Flexible File Layouts. 1639 The PNFS_FF_RCA4_TYPE_MASK_READ flag notifies the client to return 1640 layouts of iomode LAYOUTIOMODE4_READ. Similarly, the 1641 PNFS_FF_RCA4_TYPE_MASK_RW flag notifies the client to return layouts 1642 of iomode LAYOUTIOMODE4_RW. When both mask flags are set, the client 1643 is notified to return layouts of either iomode. 1645 14. Client Fencing 1647 In cases where clients are uncommunicative and their lease has 1648 expired or when clients fail to return recalled layouts within a 1649 lease period, at the least the server MAY revoke client layouts and 1650 reassign these resources to other clients (see Section 12.5.5 in 1652 [RFC5661]). To avoid data corruption, the metadata server MUST fence 1653 off the revoked clients from the respective data files as described 1654 in Section 2.2. 1656 15. Security Considerations 1658 The pNFS extension partitions the NFSv4.1+ file system protocol into 1659 two parts, the control path and the data path (storage protocol). 1660 The control path contains all the new operations described by this 1661 extension; all existing NFSv4 security mechanisms and features apply 1662 to the control path. The combination of components in a pNFS system 1663 is required to preserve the security properties of NFSv4.1+ with 1664 respect to an entity accessing data via a client, including security 1665 countermeasures to defend against threats that NFSv4.1+ provides 1666 defenses for in environments where these threats are considered 1667 significant. 1669 The metadata server enforces the file access-control policy at 1670 LAYOUTGET time. The client should use RPC authorization credentials 1671 (uid/gid for AUTH_SYS or tickets for Kerberos) for getting the layout 1672 for the requested iomode (READ or RW) and the server verifies the 1673 permissions and ACL for these credentials, possibly returning 1674 NFS4ERR_ACCESS if the client is not allowed the requested iomode. If 1675 the LAYOUTGET operation succeeds the client receives, as part of the 1676 layout, a set of credentials allowing it I/O access to the specified 1677 data files corresponding to the requested iomode. When the client 1678 acts on I/O operations on behalf of its local users, it MUST 1679 authenticate and authorize the user by issuing respective OPEN and 1680 ACCESS calls to the metadata server, similar to having NFSv4 data 1681 delegations. 1683 If access is allowed, the client uses the corresponding (READ or RW) 1684 credentials to perform the I/O operations at the data file's storage 1685 devices. When the metadata server receives a request to change a 1686 file's permissions or ACL, it SHOULD recall all layouts for that file 1687 and then MUST fence off any clients still holding outstanding layouts 1688 for the respective files by implicitly invalidating the previously 1689 distributed credential on all data file comprising the file in 1690 question. It is REQUIRED that this be done before committing to the 1691 new permissions and/or ACL. By requesting new layouts, the clients 1692 will reauthorize access against the modified access control metadata. 1693 Recalling the layouts in this case is intended to prevent clients 1694 from getting an error on I/Os done after the client was fenced off. 1696 15.1. Kerberized File Access 1698 15.1.1. Loosely Coupled 1700 RPCSEC_GSS version 3 (RPCSEC_GSSv3) [RFC7861] could be used to 1701 authorize the client to the storage device on behalf of the metadata 1702 server. This would require that each of the metadata server, storage 1703 device, and client would have to implement RPCSEC_GSSv3. The second 1704 requirement does not match the intent of the loosely coupled model 1705 that the storage device need not be modified. 1707 Under this coupling model, the principal used to authenticate the 1708 metadata file is different than that used to authenticate the data 1709 file. For the metadata server, the user credentials would be 1710 generated by the same Kerberos server as the client. However, for 1711 the data storage access, the metadata server would generate the 1712 ticket granting tickets and provide them to the client. Fencing 1713 would then be controlled either by expiring the ticket or by 1714 modifying the syntethic uid or gid on the data file. 1716 15.1.2. Tightly Coupled 1718 With tight coupling, the principal used to access the metadata file 1719 is exactly the same as used to access the data file. As a result 1720 there are no security issues related to using Kerberos with a tightly 1721 coupled system. 1723 16. IANA Considerations 1725 [RFC5661] introduced a registry for "pNFS Layout Types Registry" and 1726 as such, new layout type numbers need to be assigned by IANA. This 1727 document defines the protocol associated with the existing layout 1728 type number, LAYOUT4_FLEX_FILES (see Table 1). 1730 +--------------------+-------+----------+-----+----------------+ 1731 | Layout Type Name | Value | RFC | How | Minor Versions | 1732 +--------------------+-------+----------+-----+----------------+ 1733 | LAYOUT4_FLEX_FILES | 0x4 | RFCTBD10 | L | 1 | 1734 +--------------------+-------+----------+-----+----------------+ 1736 Table 1: Layout Type Assignments 1738 [RFC5661] also introduced a registry called "NFSv4 Recallable Object 1739 Types Registry". This document defines new recallable objects for 1740 RCA4_TYPE_MASK_FF_LAYOUT_MIN and RCA4_TYPE_MASK_FF_LAYOUT_MAX (see 1741 Table 2). 1743 +------------------------------+-------+----------+-----+-----------+ 1744 | Recallable Object Type Name | Value | RFC | How | Minor | 1745 | | | | | Versions | 1746 +------------------------------+-------+----------+-----+-----------+ 1747 | RCA4_TYPE_MASK_FF_LAYOUT_MIN | 16 | RFCTBD10 | L | 1 | 1748 | RCA4_TYPE_MASK_FF_LAYOUT_MAX | 17 | RFCTBD10 | L | 1 | 1749 +------------------------------+-------+----------+-----+-----------+ 1751 Table 2: Recallable Object Type Assignments 1753 Note, [RFC5661] should have also defined (see Table 3): 1755 +-------------------------------+------+-----------+-----+----------+ 1756 | Recallable Object Type Name | Valu | RFC | How | Minor | 1757 | | e | | | Versions | 1758 +-------------------------------+------+-----------+-----+----------+ 1759 | RCA4_TYPE_MASK_OTHER_LAYOUT_M | 12 | [RFC5661] | L | 1 | 1760 | IN | | | | | 1761 | RCA4_TYPE_MASK_OTHER_LAYOUT_M | 15 | [RFC5661] | L | 1 | 1762 | AX | | | | | 1763 +-------------------------------+------+-----------+-----+----------+ 1765 Table 3: Recallable Object Type Assignments 1767 17. References 1769 17.1. Normative References 1771 [LEGAL] IETF Trust, "Legal Provisions Relating to IETF Documents", 1772 November 2008, . 1775 [RFC1813] IETF, "NFS Version 3 Protocol Specification", RFC 1813, 1776 June 1995. 1778 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1779 Requirement Levels", BCP 14, RFC 2119, March 1997. 1781 [RFC4506] Eisler, M., "XDR: External Data Representation Standard", 1782 STD 67, RFC 4506, May 2006. 1784 [RFC5531] Thurlow, R., "RPC: Remote Procedure Call Protocol 1785 Specification Version 2", RFC 5531, May 2009. 1787 [RFC5661] Shepler, S., Ed., Eisler, M., Ed., and D. Noveck, Ed., 1788 "Network File System (NFS) Version 4 Minor Version 1 1789 Protocol", RFC 5661, January 2010. 1791 [RFC5662] Shepler, S., Ed., Eisler, M., Ed., and D. Noveck, Ed., 1792 "Network File System (NFS) Version 4 Minor Version 1 1793 External Data Representation Standard (XDR) Description", 1794 RFC 5662, January 2010. 1796 [RFC7530] Haynes, T. and D. Noveck, "Network File System (NFS) 1797 version 4 Protocol", RFC 7530, March 2015. 1799 [RFC7862] Haynes, T., "NFS Version 4 Minor Version 2", RFC 7862, 1800 November 2016. 1802 [pNFSLayouts] 1803 Haynes, T., "Requirements for pNFS Layout Types", draft- 1804 ietf-nfsv4-layout-types-04 (Work In Progress), January 1805 2016. 1807 17.2. Informative References 1809 [RFC4519] Sciberras, A., Ed., "Lightweight Directory Access Protocol 1810 (LDAP): Schema for User Applications", RFC 4519, DOI 1811 10.17487/RFC4519, June 2006, 1812 . 1814 [RFC7861] Adamson, W. and N. Williams, "Remote Procedure Call (RPC) 1815 Security Version 3", November 2016. 1817 Appendix A. Acknowledgments 1819 Those who provided miscellaneous comments to early drafts of this 1820 document include: Matt W. Benjamin, Adam Emerson, J. Bruce Fields, 1821 and Lev Solomonov. 1823 Those who provided miscellaneous comments to the final drafts of this 1824 document include: Anand Ganesh, Robert Wipfel, Gobikrishnan 1825 Sundharraj, Trond Myklebust, and Rick Macklem. 1827 Idan Kedar caught a nasty bug in the interaction of client side 1828 mirroring and the minor versioning of devices. 1830 Dave Noveck provided comprehensive reviews of the document during the 1831 working group last calls. He also rewrote Section 2.3. 1833 Olga Kornievskaiaa made a convincing case against the use of a 1834 credential versus a principal in the fencing approach. Andy Adamson 1835 and Benjamin Kaduk helped to sharpen the focus. 1837 Tigran Mkrtchyan provided the use case for not allowing the client to 1838 proxy the I/O through the data server. 1840 Rick Macklem provided the use case for only writing to a single 1841 mirror. 1843 Appendix B. RFC Editor Notes 1845 [RFC Editor: please remove this section prior to publishing this 1846 document as an RFC] 1848 [RFC Editor: prior to publishing this document as an RFC, please 1849 replace all occurrences of RFCTBD10 with RFCxxxx where xxxx is the 1850 RFC number of this document] 1852 Authors' Addresses 1854 Benny Halevy 1856 Email: bhalevy@gmail.com 1858 Thomas Haynes 1859 Primary Data, Inc. 1860 4300 El Camino Real Ste 100 1861 Los Altos, CA 94022 1862 USA 1864 Phone: +1 408 215 1519 1865 Email: thomas.haynes@primarydata.com