NFS force only nfs v4
Dear Linux experts,
I set up a NFS server on RHEL6 and i set the following on the /etc/nfsmount.conf:
[ NFSMount_Global_Options ]
Defaultvers=4
Nfsvers=4
However, when i checked the nfs status : nfsstat, i got these :
==============================================================================
Server rpc stats:
calls badcalls badauth badclnt xdrcall
31616598 1 1 0 0
Server nfs v2:
null getattr setattr root lookup readlink
1 100% 0 0% 0 0% 0 0% 0 0% 0 0%
read wrcache write create remove rename
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
link symlink mkdir rmdir readdir fsstat
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
Server nfs v3:
null getattr setattr lookup access readlink
5 0% 146827 90% 22 0% 57 0% 11909 7% 0 0%
read write create mkdir symlink mknod
6 0% 2816 1% 0 0% 0 0% 0 0% 0 0%
remove rmdir rename link readdir readdirplus
0 0% 0 0% 0 0% 0 0% 0 0% 6 0%
fsstat fsinfo pathconf commit
0 0% 4 0% 2 0% 0 0%
Server nfs v4:
null compound
64 0% 31454522 99%
Server nfs v4 operations:
op0-unused op1-unused op2-future access close commit
0 0% 0 0% 0 0% 4050903 4% 2376235 2% 26367 0%
create delegpurge delegreturn getattr getfh link
47337 0% 0 0% 856541 0% 29986865 33% 3862923 4% 666 0%
lock lockt locku lookup lookup_root nverify
110 0% 25 0% 95 0% 2804501 3% 0 0% 0 0%
open openattr open_conf open_dgrd putfh putpubfh
2724218 3% 0 0% 896604 0% 126 0% 31309499 34% 0 0%
putrootfh read readdir readlink remove rename
4992 0% 972621 1% 154837 0% 2100 0% 427079 0% 83398 0%
renew restorefh savefh secinfo setattr setcltid
224172 0% 2527102 2% 2855225 3% 0 0% 728940 0% 104 0%
setcltidconf verify write rellockowner bc_ctl bind_conn
104 0% 0 0% 3571190 3% 50 0% 0 0% 0 0%
exchange_id create_ses destroy_ses free_stateid getdirdeleg getdevinfo
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
getdevlist layoutcommit layoutget layoutreturn secinfononam sequence
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
set_ssv test_stateid want_deleg destroy_clid reclaim_comp
0 0% 0 0% 0 0% 0 0% 0 0%
==============================================================================
This NFS server seems to give not only NFS v4, but also v2 and v3.
ANd if not mistaken, there are some v3 connections still running.
When i checked all the clients, they all running v4:
===================================================
Server rpc stats:
calls badcalls badauth badclnt xdrcall
0 0 0 0 0
Client rpc stats:
calls retrans authrefrsh
2057241 0 2058046
Client nfs v4:
null read write commit open open_conf
0 0% 28493 1% 63116 3% 120 0% 185556 9% 12456 0%
open_noat open_dgrd close setattr fsinfo renew
0 0% 3 0% 164441 7% 56158 2% 3 0% 4061 0%
setclntid confirm lock lockt locku access
2 0% 2 0% 22 0% 5 0% 19 0% 387882 18%
getattr lookup lookup_root remove rename link
742645 36% 264025 12% 1 0% 33621 1% 8317 0% 27 0%
symlink create pathconf statfs readlink readdir
0 0% 39 0% 2 0% 2 0% 390 0% 11593 0%
server_caps delegreturn getacl setacl fs_locations rel_lkowner
5 0% 94381 4% 0 0% 0 0% 0 0% 10 0%
exchange_id create_ses destroy_ses sequence get_lease_t reclaim_comp
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
layoutget layoutcommit layoutreturn getdevlist getdevinfo ds_write
0 0% 0 0% 0 0% 0 0% 0 0% 0 0%
ds_commit
0 0%
===================================================
all the clients have the same mount setting in /etc/fstab:
=========================================================
nfsserver:/home /home nfs4 rw,sync,hard,intr 0 0
=========================================================
Questions:
==========
- How to force NFS server to use only v4, why the config /etc/nfsmount.conf has no effect?
- How to check which client is using lower version of NFS (v2-v3)?
Thanks in advance,
Teddy
|