There isn't much to setup on the client side. You need to:
enable NFSv3 client support in the kernel
run the portmapper
run the rpc.statd daemon
if you want file locking, also run the rpc.lockd daemon
and then just mount the remote filesystem like this:
mount -t nfs yourserver:/exportdir /mnt -o hard,intr,nfsvers=3,rsize=2048,wsize=2048
Test things
on the client:
showmount -e nfsserver
rpcinfo -p nfsserver
on the server:
showmount -a
nfsstat
Server setup
NFSv4 (Network File System Version 4)
The main difference between NFSv3 and NFSv4 is, that NFSv4 uses only one
single TCP port (default is 2049) and therefore can be used over the internet
(unlike NFSv3)
Also the mapping of user names to userids works in a better way (users don't
need to have the same userid on every client)
Client setup
There isn't much to setup on the client side. You need to:
enable NFSv4 client support in the kernel
run the portmapper
configure and run the idmap-daemon (see below)
and then just mount the remote filesystem like this:
root@osiris:~# mount -t nfs -o nfsvers=4 yourserver:/ /mnt/nfs4/
or, using kerberos, like this:
root@osiris:~# mount -t nfs -o nfsvers=4,sec=krb5 yourserver:/ /mnt/nfs4/
When using entries in the fstab, you should fill in something like this:
If you want to use IPv6, you need to use "proto=tcp6"
Please note that the use of filesystem "nfs4" in fstab is deprecated
and often does not work as expected. Use type "nfs" instead and add
the option "nfsvers=4"