Back to home page

OSCL-LXR

 
 

    


0001 =============================
0002 NFSv4.1 Server Implementation
0003 =============================
0004 
0005 Server support for minorversion 1 can be controlled using the
0006 /proc/fs/nfsd/versions control file.  The string output returned
0007 by reading this file will contain either "+4.1" or "-4.1"
0008 correspondingly.
0009 
0010 Currently, server support for minorversion 1 is enabled by default.
0011 It can be disabled at run time by writing the string "-4.1" to
0012 the /proc/fs/nfsd/versions control file.  Note that to write this
0013 control file, the nfsd service must be taken down.  You can use rpc.nfsd
0014 for this; see rpc.nfsd(8).
0015 
0016 (Warning: older servers will interpret "+4.1" and "-4.1" as "+4" and
0017 "-4", respectively.  Therefore, code meant to work on both new and old
0018 kernels must turn 4.1 on or off *before* turning support for version 4
0019 on or off; rpc.nfsd does this correctly.)
0020 
0021 The NFSv4 minorversion 1 (NFSv4.1) implementation in nfsd is based
0022 on RFC 5661.
0023 
0024 From the many new features in NFSv4.1 the current implementation
0025 focuses on the mandatory-to-implement NFSv4.1 Sessions, providing
0026 "exactly once" semantics and better control and throttling of the
0027 resources allocated for each client.
0028 
0029 The table below, taken from the NFSv4.1 document, lists
0030 the operations that are mandatory to implement (REQ), optional
0031 (OPT), and NFSv4.0 operations that are required not to implement (MNI)
0032 in minor version 1.  The first column indicates the operations that
0033 are not supported yet by the linux server implementation.
0034 
0035 The OPTIONAL features identified and their abbreviations are as follows:
0036 
0037 - **pNFS**      Parallel NFS
0038 - **FDELG**     File Delegations
0039 - **DDELG**     Directory Delegations
0040 
0041 The following abbreviations indicate the linux server implementation status.
0042 
0043 - **I** Implemented NFSv4.1 operations.
0044 - **NS**        Not Supported.
0045 - **NS\***      Unimplemented optional feature.
0046 
0047 Operations
0048 ==========
0049 
0050 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0051 | Implementation status | Operation            | REQ,REC, OPT or NMI | Feature (REQ, REC or OPT) | Definition     |
0052 +=======================+======================+=====================+===========================+================+
0053 |                       | ACCESS               | REQ                 |                           | Section 18.1   |
0054 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0055 | I                     | BACKCHANNEL_CTL      | REQ                 |                           | Section 18.33  |
0056 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0057 | I                     | BIND_CONN_TO_SESSION | REQ                 |                           | Section 18.34  |
0058 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0059 |                       | CLOSE                | REQ                 |                           | Section 18.2   |
0060 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0061 |                       | COMMIT               | REQ                 |                           | Section 18.3   |
0062 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0063 |                       | CREATE               | REQ                 |                           | Section 18.4   |
0064 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0065 | I                     | CREATE_SESSION       | REQ                 |                           | Section 18.36  |
0066 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0067 | NS*                   | DELEGPURGE           | OPT                 | FDELG (REQ)               | Section 18.5   |
0068 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0069 |                       | DELEGRETURN          | OPT                 | FDELG,                    | Section 18.6   |
0070 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0071 |                       |                      |                     | DDELG, pNFS               |                |
0072 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0073 |                       |                      |                     | (REQ)                     |                |
0074 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0075 | I                     | DESTROY_CLIENTID     | REQ                 |                           | Section 18.50  |
0076 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0077 | I                     | DESTROY_SESSION      | REQ                 |                           | Section 18.37  |
0078 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0079 | I                     | EXCHANGE_ID          | REQ                 |                           | Section 18.35  |
0080 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0081 | I                     | FREE_STATEID         | REQ                 |                           | Section 18.38  |
0082 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0083 |                       | GETATTR              | REQ                 |                           | Section 18.7   |
0084 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0085 | I                     | GETDEVICEINFO        | OPT                 | pNFS (REQ)                | Section 18.40  |
0086 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0087 | NS*                   | GETDEVICELIST        | OPT                 | pNFS (OPT)                | Section 18.41  |
0088 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0089 |                       | GETFH                | REQ                 |                           | Section 18.8   |
0090 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0091 | NS*                   | GET_DIR_DELEGATION   | OPT                 | DDELG (REQ)               | Section 18.39  |
0092 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0093 | I                     | LAYOUTCOMMIT         | OPT                 | pNFS (REQ)                | Section 18.42  |
0094 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0095 | I                     | LAYOUTGET            | OPT                 | pNFS (REQ)                | Section 18.43  |
0096 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0097 | I                     | LAYOUTRETURN         | OPT                 | pNFS (REQ)                | Section 18.44  |
0098 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0099 |                       | LINK                 | OPT                 |                           | Section 18.9   |
0100 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0101 |                       | LOCK                 | REQ                 |                           | Section 18.10  |
0102 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0103 |                       | LOCKT                | REQ                 |                           | Section 18.11  |
0104 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0105 |                       | LOCKU                | REQ                 |                           | Section 18.12  |
0106 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0107 |                       | LOOKUP               | REQ                 |                           | Section 18.13  |
0108 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0109 |                       | LOOKUPP              | REQ                 |                           | Section 18.14  |
0110 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0111 |                       | NVERIFY              | REQ                 |                           | Section 18.15  |
0112 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0113 |                       | OPEN                 | REQ                 |                           | Section 18.16  |
0114 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0115 | NS*                   | OPENATTR             | OPT                 |                           | Section 18.17  |
0116 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0117 |                       | OPEN_CONFIRM         | MNI                 |                           | N/A            |
0118 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0119 |                       | OPEN_DOWNGRADE       | REQ                 |                           | Section 18.18  |
0120 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0121 |                       | PUTFH                | REQ                 |                           | Section 18.19  |
0122 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0123 |                       | PUTPUBFH             | REQ                 |                           | Section 18.20  |
0124 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0125 |                       | PUTROOTFH            | REQ                 |                           | Section 18.21  |
0126 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0127 |                       | READ                 | REQ                 |                           | Section 18.22  |
0128 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0129 |                       | READDIR              | REQ                 |                           | Section 18.23  |
0130 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0131 |                       | READLINK             | OPT                 |                           | Section 18.24  |
0132 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0133 |                       | RECLAIM_COMPLETE     | REQ                 |                           | Section 18.51  |
0134 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0135 |                       | RELEASE_LOCKOWNER    | MNI                 |                           | N/A            |
0136 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0137 |                       | REMOVE               | REQ                 |                           | Section 18.25  |
0138 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0139 |                       | RENAME               | REQ                 |                           | Section 18.26  |
0140 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0141 |                       | RENEW                | MNI                 |                           | N/A            |
0142 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0143 |                       | RESTOREFH            | REQ                 |                           | Section 18.27  |
0144 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0145 |                       | SAVEFH               | REQ                 |                           | Section 18.28  |
0146 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0147 |                       | SECINFO              | REQ                 |                           | Section 18.29  |
0148 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0149 | I                     | SECINFO_NO_NAME      | REC                 | pNFS files                | Section 18.45, |
0150 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0151 |                       |                      |                     | layout (REQ)              | Section 13.12  |
0152 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0153 | I                     | SEQUENCE             | REQ                 |                           | Section 18.46  |
0154 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0155 |                       | SETATTR              | REQ                 |                           | Section 18.30  |
0156 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0157 |                       | SETCLIENTID          | MNI                 |                           | N/A            |
0158 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0159 |                       | SETCLIENTID_CONFIRM  | MNI                 |                           | N/A            |
0160 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0161 | NS                    | SET_SSV              | REQ                 |                           | Section 18.47  |
0162 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0163 | I                     | TEST_STATEID         | REQ                 |                           | Section 18.48  |
0164 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0165 |                       | VERIFY               | REQ                 |                           | Section 18.31  |
0166 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0167 | NS*                   | WANT_DELEGATION      | OPT                 | FDELG (OPT)               | Section 18.49  |
0168 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0169 |                       | WRITE                | REQ                 |                           | Section 18.32  |
0170 +-----------------------+----------------------+---------------------+---------------------------+----------------+
0171 
0172 
0173 Callback Operations
0174 ===================
0175 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0176 | Implementation status | Operation               | REQ,REC, OPT or NMI | Feature (REQ, REC or OPT) | Definition    |
0177 +=======================+=========================+=====================+===========================+===============+
0178 |                       | CB_GETATTR              | OPT                 | FDELG (REQ)               | Section 20.1  |
0179 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0180 | I                     | CB_LAYOUTRECALL         | OPT                 | pNFS (REQ)                | Section 20.3  |
0181 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0182 | NS*                   | CB_NOTIFY               | OPT                 | DDELG (REQ)               | Section 20.4  |
0183 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0184 | NS*                   | CB_NOTIFY_DEVICEID      | OPT                 | pNFS (OPT)                | Section 20.12 |
0185 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0186 | NS*                   | CB_NOTIFY_LOCK          | OPT                 |                           | Section 20.11 |
0187 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0188 | NS*                   | CB_PUSH_DELEG           | OPT                 | FDELG (OPT)               | Section 20.5  |
0189 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0190 |                       | CB_RECALL               | OPT                 | FDELG,                    | Section 20.2  |
0191 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0192 |                       |                         |                     | DDELG, pNFS               |               |
0193 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0194 |                       |                         |                     | (REQ)                     |               |
0195 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0196 | NS*                   | CB_RECALL_ANY           | OPT                 | FDELG,                    | Section 20.6  |
0197 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0198 |                       |                         |                     | DDELG, pNFS               |               |
0199 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0200 |                       |                         |                     | (REQ)                     |               |
0201 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0202 | NS                    | CB_RECALL_SLOT          | REQ                 |                           | Section 20.8  |
0203 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0204 | NS*                   | CB_RECALLABLE_OBJ_AVAIL | OPT                 | DDELG, pNFS               | Section 20.7  |
0205 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0206 |                       |                         |                     | (REQ)                     |               |
0207 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0208 | I                     | CB_SEQUENCE             | OPT                 | FDELG,                    | Section 20.9  |
0209 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0210 |                       |                         |                     | DDELG, pNFS               |               |
0211 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0212 |                       |                         |                     | (REQ)                     |               |
0213 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0214 | NS*                   | CB_WANTS_CANCELLED      | OPT                 | FDELG,                    | Section 20.10 |
0215 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0216 |                       |                         |                     | DDELG, pNFS               |               |
0217 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0218 |                       |                         |                     | (REQ)                     |               |
0219 +-----------------------+-------------------------+---------------------+---------------------------+---------------+
0220 
0221 
0222 Implementation notes:
0223 =====================
0224 
0225 SSV:
0226   The spec claims this is mandatory, but we don't actually know of any
0227   implementations, so we're ignoring it for now.  The server returns
0228   NFS4ERR_ENCR_ALG_UNSUPP on EXCHANGE_ID, which should be future-proof.
0229 
0230 GSS on the backchannel:
0231   Again, theoretically required but not widely implemented (in
0232   particular, the current Linux client doesn't request it).  We return
0233   NFS4ERR_ENCR_ALG_UNSUPP on CREATE_SESSION.
0234 
0235 DELEGPURGE:
0236   mandatory only for servers that support CLAIM_DELEGATE_PREV and/or
0237   CLAIM_DELEG_PREV_FH (which allows clients to keep delegations that
0238   persist across client reboots).  Thus we need not implement this for
0239   now.
0240 
0241 EXCHANGE_ID:
0242   implementation ids are ignored
0243 
0244 CREATE_SESSION:
0245   backchannel attributes are ignored
0246 
0247 SEQUENCE:
0248   no support for dynamic slot table renegotiation (optional)
0249 
0250 Nonstandard compound limitations:
0251   No support for a sessions fore channel RPC compound that requires both a
0252   ca_maxrequestsize request and a ca_maxresponsesize reply, so we may
0253   fail to live up to the promise we made in CREATE_SESSION fore channel
0254   negotiation.
0255 
0256 See also http://wiki.linux-nfs.org/wiki/index.php/Server_4.0_and_4.1_issues.