nfs:nrnode
Parameter
- Description
-
Controls the size of the
rnode
cache 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. Thernode
contains the file handle that identifies the file on the NFS server. Thernode
also contains pointers to various caches used by the NFS client to avoid network calls to the server. Eachrnode
has a one-to-one association with avnode
. Thevnode
caches file data.The NFS client attempts to maintain a minimum number of
rnode
s to attempt to avoid destroying cached data and metadata. When anrnode
is 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
nrnode
should be set to the value of thencsize
parameter. Actually, any non positive value ofnrnode
results innrnode
being set to the value ofncsize
. - Range
-
1 to 231 - 1
- Units
-
rnode
s - 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
rnode
cache can only consume 25 percent of available memory. - When to Change
-
Because
rnode
s 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 ofnrnode
if 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 ofnrnode
to a small number so that system memory can cache file data instead ofrnode
s. Alternately, if the client is accessing many small files, you could increase the value ofnrnode
to optimize for storing file metadata to reduce the number of network calls for metadata.Although it is not recommended, the
rnode
cache can be effectively disabled by setting the value ofnrnode
to 1. This value instructs the client to only cache 1rnode
, which means that it is reused frequently. - Commitment Level
-
Unstable