Which version of NFS is my NFS server using?

The nfsstat -c program will show you the NFS version actually being used.

If you run rpcinfo -p {server} you will see all the versions of all the RPC programs that the server supports. On my system I get this output:

$ rpcinfo -p localhost
   program vers proto   port
    100000    2   tcp    111  portmapper
    100000    2   udp    111  portmapper
    ...
    100003    2   tcp   2049  nfs
    100003    3   tcp   2049  nfs
    100003    4   tcp   2049  nfs
    100003    2   udp   2049  nfs
    100003    3   udp   2049  nfs
    100003    4   udp   2049  nfs
    ...

This shows me that my NFS server (localhost in this example) offers versions 2, 3, and 4 of the NFS protocol all over UDP and TCP.


Depending your OS and version there may be different ways to check it.

nfsstat:

# nfsstat -m
/mnt/share from 10.0.0.1:/mnt/share
Flags:  rw,relatime,vers=3,rsize=524288,wsize=524288,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=10.0.0.1,mountvers=3,mountport=30924,mountproto=udp,local_lock=none,addr=10.0.0.1

But you can for sure

# grep nfs /proc/mounts
10.0.0.1:/mnt/share /mnt/share nfs rw,relatime,vers=3,rsize=524288,wsize=524288,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=10.0.0.1,mountvers=3,mountport=30924,mountproto=udp,local_lock=none,addr=10.0.0.1

which is obviously the same output.

It shows vers=3 on server, and mountvers=3.