Vamsee Priya wrote: > I have NFS v2, v3 and v4 on my Solaris machine which has Solaris 10 OS. > > How can I find out what version of NFS is being used when I do an NFS > share of a directory?
The client and server will both favor more recent versions by default. You can see what the client negotiated on an existing mount with 'nfsstat -m': % nfsstat -m /export/pond/tools /export/pond/tools from kootenay:/export/pond/tools Flags: vers=4,proto=tcp,sec=sys,hard,intr,link,symlink,acl,rsize=1048576,wsize=1048576,retrans=5,timeo=600 Attr cache: acregmin=3,acregmax=60,acdirmin=30,acdirmax=60 > How can I make the system use only a particular version of NFS(say v2) > only for sharing a particular directory? The client can use the "vers=" mount option to insist on a particular version. This can be used on the mount command line, in /etc/vfstab, or in automounter maps. # mount -o vers=2 peyto:/export/thurlow /mnt # nfsstat -m /mnt /mnt from peyto:/export/thurlow Flags: vers=2,proto=tcp,sec=sys,hard,intr,dynamic,acl,rsize=8192,wsize=8192,retrans=5,timeo=600 Attr cache: acregmin=3,acregmax=60,acdirmin=30,acdirmax=60 If you want the server to share filesystems with only a certain version, you have to make that decision for all filesystems at once via the NFS_SERVER_VERSMIN and NFS_SERVER_VERSMAX keywords in /etc/default/nfs, which I'd advise against. We prefer and support more recent versions best, and clients not capable of recent versions should be able to use versions they support. Rob T _______________________________________________ opensolaris-discuss mailing list [email protected]
