sys_attrs_nfs(5)sys_attrs_nfs(5)NAMEsys_attrs_nfs - NFS and RPC subsystem attributes
DESCRIPTION
This reference page lists and describes attributes for the Network File
System (NFS) server, the NFS client, and the Remote Procedure Call
(RPC) kernel subsystems. See sys_attrs(5) for general guidelines about
changing system attributes.
In the following lists, an asterisk (*) precedes the names of
attributes whose values you can change while the system is running.
Changes to values of attributes whose names are not preceded by an
asterisk take effect only when the system is rebooted.
NFS Server Subsystem Attributes A value that enables or disables write
gathering for NFS V2.
Enabling this attribute improves NFS V2 performance by gathering
several write requests and performing a single synchronization
before sending all the replies. This occurs because all NFS V2
writes are synchronous. However, you may want to disable this
attribute for the following reasons:
The write gathering code path is complex, and disabling write
gathering may make it easier to diagnose odd problems. Write
gathering will not help in the uncommon situation in which a
client waits for a reply after each write request. Write gath‐
ering does not improve performance when writing small files that
need only a single write.
Default value: 1 (enable NFS V2 server write gathering)
Minimum value: 0
Maximum value: 1 A value that enables or disables write gather‐
ing for NFS V3.
Enabling this attribute improves NFS V3 performance by gathering
several write requests and performing a single synchronization
before sending all the replies.
This write gathering operation is not as important in NFS V3 as
it is in NFS V2 because V3 supports both “unstable” and “stable”
writes: Unstable writes reply that the data has been received,
but probably has not been written to disk. Stable writes are
like V2 writes.
With nfs3_write_gather, only stable writes are gathered, and
because most V3 writes are unstable, write gathering becomes
less important.
Default value: 1 (enable NFS V3 server write gathering)
Minimum value: 0
Maximum value: 1 A value that enables or disables a delay when
NFS V2 returns writes.
This attribute affects write gathering for all file systems (not
just UFS) for NFS V2. When enabled (by default) and the server
has no more writes to process, it will sleep for 8 milliseconds
to give the client time to send more writes. If more writes
arrive, write gathering will be more efficient. Disabling this
attribute may improve performance in situations where many small
files are being written or your I/O system has a cache.
Default value: 1 (enable V2 delay before returning write
results)
Minimum value: 0
Maximum value: 1 A value that enables or disables a delay when
NFS V3 returns writes.
This attribute affects write gathering for all file systems (not
just UFS) for NFS V3. A Tru64 UNIX client generally writes the
last partial page of a file with a stable write, which has a
significant impact on writing small NFS V3 files.
Default value: 1 (enable V3 delay before returning write
results)
Minimum value: 0
Maximum value: 1
NFS Client Subsystem Attributes
A value that enables or disables Close-To-Open (CTO) consistency to
reduce the number of client caches that provide applications with stale
NFS data. It works by doing the following: Ensuring that all data is
written to the server during a close function Checking for recent modi‐
fications during an open function. This means that one client can
write a file then tell another client to read it and the latter client
will see the new data.
Close-To-Open consistency can be disabled by mounting with the
-o nocto option. Although this will produce a slight performance
gain, the risk is moderate, so the use of nocto is discouraged.
Enabling the nfs_cto attribute will override the nocto mount
option. There is little reason to use this attribute, even when
experimenting with performance.
Default value: 0 (mount option -o nocto is effective)
Minimum value: 0
Maximum value: 1 A value that enables or disables synchronous
cache flush.
When an application calls the stat function on a file, the NFS
client first flushes any unwritten data to the server. This
allows stat to return the most accurate data to the application
-- especially st_blocks.
However, the cache flush is done synchronously and if another
application is actively writing the file, the cache flush will
significantly impact performance. In the typical case, a user
uses the ls -l command to watch the progress of a file being
written and sees that the listing, when done on the client,
slows progress.
Enabling nfs_quicker_attr prevents the synchronization from hap‐
pening, with little loss in stat accuracy.
This attribute affects both NFS v2 and NFS V3 client behavior.
Default value: 1 (disabled, do file synchronization before the
stat function)
Minimum value: 0
Maximum value: 1 A value that controls the frequency of console
messages related to an NFS V3 problem on some servers where a
file lookup would return erroneous data for the parent direc‐
tory. It unlikely this attribute will need to be changed.
Default value: 600 (print a complaint, then suppress for 10 min‐
utes)
Minimum value: 0 (print no complaints)
Maximum value: 1 unlimited A value that enables or disables the
operating system from issuing the readdirplus procedure.
The readdir NFS V2 and V3 procedure is analogous to the ls com‐
mand or file name completion. The readdirplus NFS V3 procedure
is analogous to ls -l. The readdirplus procedure is more CPU
intensive than readdir if the application needs just file names;
however, if it needs attributes too, readdir followed by a
lookup for each file is even more CPU intensive. (The POSIX get‐
direntries function provides no hint about which to use.) Tru64
UNIX will issue readdirplus if all of the following conditions
exist: It is reading at the start of the directory. The mount
is caching attributes (that is, -o noac is not in effect). The
system does not remember reading the directory before. The
do_client_readdirplus attribute is set.
Default value: 1 Use readdirplus on the first directory read)
Minimum value: 0 (Never use readdirplus)
Maximum value: 1 A value to control the number of outstanding
readaheads.
When the NFS V3 client sees that a file is being read sequen‐
tially, it will issue readaheads, subject to various limits,
primarily the availability of idle nfsiod threads and the number
of outstanding readaheads for the file.
If the value of nfs3_maxreadahead is increased, more readaheads
may be issued, at the risk of triggering network congestion. If
it is decreased, the system may not get all the network band‐
width available.
In practice, this value can be reduced to just 2 or 3 and Tru64
UNIX can still saturate small Gigabit Ethernet networks. Reasons
to increase it include networks with long round trip times (con‐
sider TCP) or when applications alternate reading data and num‐
ber crunching.
Default value: 8 (allow 8 readaheads to be outstanding for a
file)
Minimum value: 0
Maximum value: INT_MAX (but other limits apply) A value to con‐
trol the number of readaheads.
When the NFS V3 client decides it can issue readaheads (see
nfs3_maxreadahead) by default it issues 2 readaheads for each
read done by the application. This allows the system to gradu‐
ally build up the number of outstanding reads without waking
several nfsiod threads at once. Generally, the default of 2
works well. Reducing it to 1 will mean that only a single reada‐
head will be outstanding, regardless of the nfs3_maxreadahead
limit. Reducing it to 0 will disable readahead.
Default value: 2
Minimum value: 0
Maximum value: INT_MAX (but nfs3_maxreadahead and other limits
apply)
RPC Subsystem Attributes
A value enables or disables the optimization of client and server code
used by NFS over UDP.
In general, fastsend works well, but it can cause problems in
some configurations. Consider disabling use_fastsend when NFS
traffic is not flowing well, but the network infrastructure is
not losing packets and other high-data-rate applications (for
example, ftp and rcp) work well. Leave use_fastsend disabled
only if the system clearly runs better that way.
Default value: 1 (enable fast UDP send path)
Minimum value: 0
Maximum value: 1 A value that enables or disables improved fast‐
send optimization that affects the NFS server.
When use_fastroute is enabled, NFS replies destined for the
local network are sent out the network interface from where the
request arrived. Although that interface may not be the one nor‐
mal routing would use, it is often the best choice. Consider
disabling this attribute if an NFS mount hangs due to the NFS
server not responding. In that case, replies from the mount
server, which does not use fastsend/fastroute, reached the
client but NFS replies did not.
Cluster configurations automatically disable use_fastroute
because NFS requests can be forwarded from one server member to
another and the source interface information is wrong.
Default value: 1 (enabled) on non-cluster, 0 (disabled) on clus‐
ters
Minimum value: 0
Maximum value: 1
SEE ALSOsys_attrs(5)sys_attrs_nfs(5)