Solaris Tunable Parameters Reference Manual

nfs:nrnode

Description

Controls the size of the rnode cache on the NFS client.

The rnode cache, used by both NFS version 2 and 3 clients, is the central data structure that describes a file on the NFS client. It contains the file handle that identifies the file on the server and also contains pointers to various caches used by the NFS client to avoid network calls to the server. Each rnode has a one-to-one association with a vnode. The vnode caches file data.

The NFS client attempts to keep a minimum number of rnodes around to attempt to avoid destroying cached data and metadata. When an rnode 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 of nrnode should be set to the value of the ncsize parameter. Actually, any non-positive value of nrnode results in nrnode being set to the value of ncsize.

Range

1 to 231 - 1

Units

rnodes

Dynamic?

No. This value can only be changed by adding or changing the parameter in the /etc/system file, and then rebooting the system.

Validation

The system enforces a maximum value such that the rnode cache can only consume 25% of available memory.

When to Change

Since 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, it might be helpful to set the value of nrnode 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, it might be useful to set the value of nrnode to be a small number so that system memory can cache file data instead of rnodes. Alternately, if the client is accessing many small files, it might be helpful to set the value of nrnode large enough 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 of nrnode to 1. This instructs the client to only cache 1 rnode, which means that it is reused frequently.

Stability Level

Evolving