nfso Command

Purpose

Manages Network File System (NFS) tuning parameters.

Syntax

nfso [ -p | -r ] [ -c ] { -o Tunable[ =newvalue ] }

nfso [ -p | -r ] { -d Tunable }

nfso [ -p | -r ] -D

nfso [ -p | -r ] -a [-F] [ -c ]

nfso -h [ Tunable ]

nfso -l [ hostname ]

nfso [-F] -L [ Tunable ]

nfso [-F] -x [ Tunable ]

nfso [ -@ WparName ] [ -p | -r ] -a [ -c ]

nfso [ -@ WparName ] [ -p | -r ] [ -c ] { -o Tunable[ =newvalue ] }

Note: Multiple flags -o, -d, -x, and -L are allowed.

Description

Use the nfso command to configure Network File System tuning parameters. The nfso command sets or displays current or next boot values for Network File System tuning parameters. This command can also make permanent changes or defer changes until the next reboot. Whether the command sets or displays a parameter is determined by the accompanying flag. The -o flag performs both actions. It can either display the value of a parameter or set a new value for a parameter.

Understanding the Effect of Changing Tunable Parameters

Extreme care should be taken when using this command. If used incorrectly, the nfso command can make your system inoperable.

Before modifying any tunable parameter, you should first carefully read about all its characteristics in the Tunable Parameters section below, and follow any Refer To pointer, in order to fully understand its purpose.

You must then make sure that the Diagnosis and Tuning sections for this parameter truly apply to your situation and that changing the value of this parameter could help improve the performance of your system.

If the Diagnosis and Tuning sections both contain only "N/A", you should probably never change this parameter unless specifically directed by AIX® development.

Flags

Item Description
-a Displays the current, reboot (when used in conjunction with -r) or permanent (when used in conjunction with -p) value for all tunable parameters, one per line in pairs Tunable = Value. For the permanent options, a value is only displayed for a parameter if its reboot and current values are equal. Otherwise NONE displays as the value.
-c Changes the output format of the nfso command to colon-delineated format.
-d Tunable Sets the Tunable variable back to its default value. If a Tunable needs to be changed that is, . it is currently not set to its default value) and is of type Bosboot or Reboot, or if it is of type Incremental and has been changed from its default value, and -r is not used in combination, it will not be changed but a warning displays instead.
-D Sets all Tunable variables back to their default value. If Tunables needing to be changed are of type Bosboot or Reboot, or are of type Incremental and have been changed from their default value, and the -r flag is not used in combination, they will not be changed but warnings display instead.
-F Forces restricted tunable parameters to be displayed when the options -a, -L or -x are specified on the command line. If you do not specify the -F flag, restricted tunables are not included, unless they are specifically named in association with a display option.
-h [Tunable] Displays help about Tunable parameter if one is specified. Otherwise, displays the nfso command usage statement.
-l hostname Allows a system administrator to release NFS file locks on an NFS server. The hostname variable specifies the host name of the NFS client that has file locks held at the NFS server. The nfso -l command makes a remote procedure call to the NFS server's rpc.lockd network lock manager to request the release of the file locks held by the hostname NFS client.
If there is an NFS client that has file locks held at the NFS server and this client has been disconnected from the network and cannot be recovered, the nfso -l command can be used to release those locks so that other NFS clients can obtain similar file locks.
Note: The nfso command can be used to release locks on the local NFS server only.
-L [Tunable] Lists the characteristics of one or all Tunable, one per line, using the following format:
NAME                      CUR    DEF    BOOT   MIN    MAX    UNIT           TYPE
     DEPENDENCIES
--------------------------------------------------------------------------------
portcheck                 0      0      0      0      1      On/Off            D
--------------------------------------------------------------------------------
udpchecksum               1      1      1      0      1      On/Off            D
--------------------------------------------------------------------------------
nfs_socketsize            600000 600000 600000 40000  1M     Bytes             D
--------------------------------------------------------------------------------
nfs_tcp_socketsize        600000 600000 600000 40000  1M     Bytes             D
--------------------------------------------------------------------------------
... 
where: 
    CUR = current value 
    DEF = default value 
    BOOT = reboot value 
    MIN = minimal value 
    MAX = maximum value 
    UNIT = tunable unit of measure 
    TYPE = parameter type: D (for Dynamic), 
           S (for Static), R (for Reboot),B (for Bosboot), M (for Mount),
           I (for Incremental), C (for Connect), and d (for Deprecated) 
    DEPENDENCIES = list of dependent tunable parameters, one per line
-o Tunable[ =newvalue ] Displays the value or sets Tunable to newvalue. If a tunable needs to be changed (the specified value is different than current value), and is of type Bosboot or Reboot, or if it is of type Incremental and its current value is bigger than the specified value, and -r is not used in combination, it will not be changed but a warning displays instead.

When -r is used in combination without a new value, the nextboot value for the Tunable displays. When -p is used in combination without a newvalue, a value displays only if the current and next boot values for the Tunable are the same. Otherwise NONE displays as the value.

-p Makes changes apply to both current and reboot values, when used in combination with -o, -d or -D, that is, it turns on the updating of the /etc/tunables/nextboot file in addition to the updating of the current value. These combinations cannot be used on Reboot and Bosboot type parameters because their current value cannot be changed.

When used with -a or -o without specifying a new value, values are displayed only if the current and next boot values for a parameter are the same. Otherwise NONE displays as the value.

-r Makes changes apply to reboot values when used in combination with -o, -d or -D, that is, it turns on the updating of the /etc/tunables/nextboot file. If any parameter of type Bosboot is changed, the user is prompted to run bosboot.

When used with -a or -o without specifying a new value, next boot values for tunables display instead of current values.

-x [Tunable] Lists characteristics of one or all tunables, one per line, using the following (spreadsheet) format:
tunable,current,default,reboot,min,max,unit,type,{dtunable } 

where: 
    current = current value 
    default = default value 
    reboot = reboot value 
    min = minimal value 
    max = maximum value 
    unit = tunable unit of measure 
TYPE = parameter type: D (for Dynamic), 
           S (for Static), R (for Reboot),B (for Bosboot), M (for Mount),
           I (for Incremental), C (for Connect), and d (for Deprecated) 
       dtunable = space separated list of dependent tunable parameters 
-@ WparName Sets or displays tunables for the specified workload partition. The -@ flag can only be used when the nfso command is run in the global partition.

If you make any change (with -o, -d or -D) to a restricted tunable parameter, it results in a warning message that a tunable parameter of the restricted-use type has been modified. If you also specify the -r or -p options on the command line, you are prompted for confirmation of the change. In addition, at system reboot, the presence of restricted tunables in the /etc/tunables/nextboot file, which were modified to a value that is different from their default value (using a command line specifying the -r or -p options), results in an error log entry that identifies the list of these modified tunables.

If you make any change (with -o, -d, or -D) to a parameter of type Mount, it results in a warning message that the change is only effective for future mountings.

If you make any change (with -o, -d or -D) to a parameter of type Connect, it results in inetd being restarted, and a warning message that the change is only effective for future socket connections.

If you make any change (with -o, -d, or -D) to a parameter of type Bosboot or Reboot without -r, it results in an error message.

If you make any change (with -o, -d, or -D but without -r) to the current value of a parameter of type Incremental with a new value smaller than the current value, it results in an error message.

Note: Tunable variables that apply to the entire system can not be modified within a workload partition.
Note: When the nfso command is run within a workload partition (or if the -@ flag is specified), only the following tunables can be set with the -o flag:

Tunable Parameters Type

All the tunable parameters manipulated by the tuning commands (no, nfso, vmo, ioo, schedo, and raso) have been classified into these categories:
Item Description
Dynamic If the parameter can be changed at any time
Static If the parameter can never be changed
Reboot If the parameter can only be changed during reboot
Bosboot If the parameter can only be changed by running bosboot and rebooting the machine
Mount If changes to the parameter are only effective for future file systems or directory mounts
Incremental If the parameter can only be incremented, except at boot time
Connect If changes to the parameter are only effective for future socket connections
Deprecated If changing this parameter is no longer supported by the current release of AIX.
For parameters of type Bosboot, whenever a change is performed, the tuning commands automatically prompt the user to ask if they want to execute the bosboot command. For parameters of type Connect, the tuning commands automatically restart the inetd daemon.

Note that the current set of parameters managed by the nfso command only includes Dynamic, Mount, and Incremental types.

Compatibility Mode

When running in pre 5.2 compatibility mode (controlled by the pre520tune attribute of sys0, see AIX 5.2 compatibility mode), reboot values for parameters, except those of type Bosboot, are not really meaningful because in this mode they are not applied at boot time.

In pre 5.2 compatibility mode, setting reboot values to tuning parameters continues to be achieved by imbedding calls to tuning commands in scripts called during the boot sequence. Parameters of type Reboot can therefore be set without the -r flag, so that existing scripts continue to work.

This mode is automatically turned ON when a machine is MIGRATED to AIX 5L™ Version 5.2. For complete installations, it is turned OFF and the reboot values for parameters are set by applying the content of the /etc/tunables/nextboot file during the reboot sequence. Only in that mode are the -r and -p flags fully functional. See Kernel Tuning in the AIX Version 7.1 Performance Tools Guide and Reference for details about the new 5.2 mode.

Tunable Parameters

For default values and range of values for tunables, refer the nfso command help (-h <tunable_parameter_name>).

Note: Starting with AIX Version 6.1 with the 6100-02 Technology Level, the following parameters are obsolete because the network file system (NFS) and the virtual memory manager (VMM) dynamically tunes the number of buf structures and page device tables (PDTs) based on workload:
  • nfs_v2_pdts
  • nfs_v2_vm_bufs
  • nfs_v3_pdts
  • nfs_v3_vm_bufs
  • nfs_v4_pdts
  • nfs_v4_vm_bufs
Item Description
client_delegation
Purpose:
Determine if the NFS version 4 client will accept delegations for open files.
Tuning:
A value of 0 disables delegations. A value of 1 enables delegations.
nfs_max_read_size
Purpose:
Allows the system administrator to control the NFS RPC sizes at the server.
Tuning:
Useful when all clients need to have changes in the read/write sizes, and it is impractical to change the clients. Default means to use the values used by the client mount. This may be required to reduce the V3 read/write sizes when the mounts cannot be manipulated directly on the clients, in particular during NIM installations on networks where the network is dropping packets with the default read/write sizes. In that case, set the maximum size to a smaller size that works on the network. It can also be useful where network devices are dropping packets and a generic change is desired for communications with the server.
nfs_max_write_size
Purpose:
Allows the system administrator to control the NFS RPC sizes at the server.
Tuning:
Useful when all clients need to have changes in the read/write sizes, and it is impractical to change the clients. Default means to use the values used by the client mount. This may be required to reduce the V3 read/write sizes when the mounts cannot be manipulated directly on the clients, in particular during NIM installations on networks where the network is dropping packets with the default read/write sizes. In that case, set the maximum size to a smaller size that works on the network. It can also be useful where network devices are dropping packets and a generic change is desired for communications with the server.
nfs_rfc1323
Purpose:
Enables very large TCP window size negotiation (greater than 65535 bytes) to occur between systems.
Tuning:
If using the TCP transport between NFS client and server, and both systems support it, this allows the systems to negotiate a TCP window size in a way that will allow more data to be in-flight between the client and server. This increases the throughput potential between client and server. Unlike the rfc1323 option of the no command, this only affects NFS and not other applications in the system. Value of 0 means this is disabled, and value of 1 means it is enabled. If the no command parameter rfc1323 is already set, this NFS option does not need to be set.
nfs_securenfs_authtimeout
Purpose:
Sets the number of seconds for which a DES credential.
Tuning:
Value of 0 disables DES credential timeouts.
nfs_server_base_priority
Purpose:
Sets the base priority of nfsd daemons.
Tuning:
By default, the nfsd daemons run with a floating process priority. Therefore, as they increase their cumulative CPU time, their priority will change. This parameter can be used to set a static parameter for the nfsd daemons. The value of 0 represents the floating priority (default). Other values within the acceptable range will be used to set the priority of the nfsd daemon when an NFS request is received at the server. This option can be used if the NFS server is overloading the system (lowering or making the nfsd daemon less favored). It can also be used if you want the nfsd daemons be one of the most favored processes on the server. Use caution when setting the parameter because it can render the system almost unusable by other processes. This situation can occur if the NFS server is very busy and will essentially lock out other processes from having run time on the server.
nfs_server_clread
Purpose:
This option allows the NFS server to be very aggressive about the reading of a file. The NFS server can only respond to the specific NFS-read request from the NFS client. However, the NFS server can read data in the file which exists immediately after the current read request. This is normally referred to as read-ahead. The NFS server does read-ahead by default.
Tuning:
May be useful in cases where server memory is low and a lot of disk-to-memory activity is going on. With the nfs_server_clread option enabled, the NFS server becomes very aggressive about doing read-ahead for the NFS client. If value is 1, then aggressive read-ahead is done; If value is 0, normal system default read-ahead methods are used. Normal system read-ahead is controlled by VMM (for JFS file systems) and JFS2 (for JFS2 file systems). This more aggressive top-half read-ahead enabled via the nfs_server_clread option is less susceptible to read-ahead breaking down due to out-of-order requests (which are typical in the NFS server case). When the mechanism is activated, it will read an entire cluster (128 KB, the LVM logical track group size) at a time.
nfs_use_reserved_ports
Purpose:
Specifies using non-reserved IP port number.
Tuning:
Value of 0 will use non-reserved IP port number when the NFS client communicates with the NFS server.
nfs_v3_server_readdirplus
Purpose:
Determines if READDIRPLUS calls are supported by the server.
Tuning:
Value of 0 disables READDIRPLUS processing.
nfs_v4_fail_over_timeout
Purpose:
Specifies a time out period which the NFS version 4 client operation will fail over to the replica provided by the NFS version 4 server. Measured in seconds.
Tuning:
If value of 0 is specified, the timeout value will be the timeout value for tcp multipled by 4. Values from 1 to 4 are reserved and the NFS version 4 client will treat it as 0. NFS version 4 allows client to fail over to other replica server if the main server is not responding. This value will determine how long a client has to wait for a respond from the server before it switch all the NFS version 4 request for that fsid to other replica server.
portcheck
Purpose:
Checks whether an NFS request originated from a privileged port.
Tuning:
Value of 0 disables the port-checking that is done by the NFS server. A value of 1 directs the NFS server to do port checking on the incoming NFS requests. This is a configuration decision with minimal performance consequences.
server_delegation
Purpose:
Determine if the NFS version 4 server will issue read delegations for open files.
Tuning:
A value of 0 disables delegation granting. A value of 1 enables delegation granting.
utf8_validation
Purpose:
Determine if the NFS version 4 client and server will check string data for UTF-8 correctness.
Tuning:
A value of 0 disables the UTF-8 checking. A value of 1 enables the UTF-8 checking.

Examples

  1. To set the portcheck tunable parameter to a value of zero, type:
    nfso -o portcheck=0
  2. To set the udpchecksum tunable parameter to its default value of 1 at the next reboot, type:
    nfso -r -d udpchecksum
  3. To print, in colon-delimited format, a list of all tunable parameters and their current values, type:
    nfso -a -c
  4. To list the current and reboot value, range, unit, type and dependencies of all tunables parameters managed by the nfso command, type:
     nfso -L
  5. To display help information on nfs_tcp_duplicate_cache_size, type:
    nfso -h nfs_tcp_duplicate_cache_size
  6. To permanently turn off nfs_dynamic_retrans, type:
    nfso -p -o nfs_dynamic_retrans=0
  7. To list the reboot values for all Network File System tuning parameters, type:
    nfso -r -a
  8. To list (spreadsheet format) the current and reboot value, range, unit, type and dependencies of all tunables parameters managed by the nfso command, type:
    nfso -x