Improving NFS client large file writing performance

Writing large, sequential files over an NFS-mounted file system can cause a severe decrease in the file transfer rate to the NFS server. In this scenario, you identify whether this situation exists and use the steps to remedy the problem.

Things to Consider
Note: The information in this how-to scenario was tested using specific versions of AIX. The results you obtain might vary significantly depending on your version and level of AIX.

Assume that the system is running an application that sequentially writes large files (larger than the amount of physical memory on the machine) to an NFS-mounted file system. The file system is mounted by using NFS V3. The NFS server and client communicate over a 100 MB per-second Ethernet network. When sequentially writing a small file, the throughput averages around 10 MB per second. However, when writing a very large file, the throughput average drops to well under 1 MB per second.

The application's large file write is filling all of the client's memory, causing the rate of transfer to the NFS server to decrease. This happens because the client AIX system must invoke the LRUD kproc to release some pages in memory to accommodate the next set of pages being written by the application.

Use either of the following methods to detect if you are experiencing this problem:
  • While a file is being written to the NFS server, run the nfsstat command periodically (every 10 seconds) by typing the following:
    nfsstat
    Check the nfsstat command output. If the number of V3 commit calls is increasing nearly linearly with the number of V3 write calls, it is likely that this is the problem.
  • Use the topas command (located in the bos.perf.tools fileset) to monitor the amount of data per second that is being sent to the NFS server by typing the following:
    topas -i 1

If either of the methods that are listed indicate that the problem exists, the solution is to use the new mount command option that is called combehind when mounting the NFS server file system on the client system. Do the following:


  1. When the file system is not active, unmount it by typing the following:
    unmount /mnt  
    (assumes /mnt is local mount point)

  2. Remount the remote file system by using the mount command option called combehind, as follows:
    mount -o combehind server_hostname:/remote_mount_point /mnt