NFSwatch monitoring of an NFS server

About nfswatch

nfswatch is a tool used on an NFS server to monitor the NFS I/O traffic from NFS clients. Unfortunately nfswatch hasn't been updated since 2010.

nfswatch is an extremely useful tool when you need to understand a server's NFS load. For example, if you want to identify which NFS clients are making heavy I/O traffic to the NFS server.

Apparently nfswatch doesn't support NFS v4, see Bug_570981.

nfswatch for RHEL/CentOS 7

There are no RPM packages of nfswatch for RHEL/CentOS 7, not even in the EPEL repository. However, you can build an RPM using the Fedora source as follows:

  1. Download the source RPM from the Fedora build system page nfswatch-4.99.11-11.fc26:


    or check for newer packages at

  2. Rebuild the package:

    rpmbuild --rebuild nfswatch-4.99.11-11.fc26.src.rpm
  3. Install the RPM:

    yum install $HOME/rpmbuild/RPMS/x86_64/nfswatch-4.99.11-11.el7.centos.x86_64.rpm

Using nfswatch

See the man nfswatch manual page.

On CentOS 6 and 7 the nfswatch tool spits out lots of error messages:

Unknown Linux fsid_type 6:

It is not obvious which of the file systems the error message refers to.

However, you can still use nfswatch by piping the error messages:

nfswatch 2>/dev/null

Here is a recommended usage monitoring all network interfaces, listing NFS clients, and sort them by usage:

nfswatch -allif -clients -usage 2>/dev/null

You can also get the usernames of NFS client users:

nfswatch -allif -auth -usage 2>/dev/null

Other NFS monitoring tools

There doesn't seem to be any other tool which provides information similar to nfswatch. However, some insights may be gleaned using these methods:

  1. Use iftop to monitor all traffic on a specific interface, for example:

    iftop -i ib0

    Get iftop from the EPEL repository.

  1. Analyzing Linux NFS server performance suggests these commands:

    netstat -plaute | grep nfs
    watch -d "netstat -plaute | grep nfs | sort -k 4,5"

    I suggest this watch command:

    watch -n 5 "netstat -plate | grep nfs | sort -r -n -k 3,2"
  2. Use the nfsiostat command on each NFS client, see Monitoring Client NFS Storage with nfsiostat.

IT-wiki: NFSwatch (last edited 2017-09-06 08:52:31 by OleHolmNielsen)