nfs:nrnode Parameter
- Description
-
Controls the size of the
rnodecache on the NFS client.The
rnode, used by NFS version 2, 3, and 4 clients, is the central data structure that describes a file on the NFS client. Thernodecontains the file handle that identifies the file on the NFS server. Thernodealso contains pointers to various caches used by the NFS client to avoid network calls to the server. Eachrnodehas a one-to-one association with avnode. Thevnodecaches file data.The NFS client attempts to maintain a minimum number of
rnodes to attempt to avoid destroying cached data and metadata. When anrnodeis reused or freed, the cached data and metadata must be destroyed. - Data Type
-
Integer (32-bit)
- Default
-
The default setting of this parameter is 0, which means that the value
nrnodeshould be set to the value of thencsizeparameter. Actually, any non positive value ofnrnoderesults innrnodebeing set to the value ofncsize. - Range
-
1 to 231 - 1
- Units
-
rnodes - Dynamic?
-
No. This value can only be changed by adding or changing the parameter in an
/etc/system.d/file, and then rebooting the system. - Validation
-
The system enforces a maximum value such that the
rnodecache can only consume 25 percent of available memory. - When to Change
-
Because
rnodes are created and destroyed dynamically, the system tends to settle upon a nrnode-size cache, automatically adjusting the size of the cache as memory pressure on the system increases or as more files are simultaneously accessed. However, in certain situations, you could set the value ofnrnodeif the mix of files being accessed can be predicted in advance. For example, if the NFS client is accessing a few very large files, you could set the value ofnrnodeto a small number so that system memory can cache file data instead ofrnodes. Alternately, if the client is accessing many small files, you could increase the value ofnrnodeto optimize for storing file metadata to reduce the number of network calls for metadata.Although it is not recommended, the
rnodecache can be effectively disabled by setting the value ofnrnodeto 1. This value instructs the client to only cache 1rnode, which means that it is reused frequently. - Commitment Level
-
Unstable