cannot unmount nfs version 3 export on rhel/centos 5

By thomas, 8 February, 2011
We have a server exporting a filesystem with nfs version 3. rhel5 clients cannot unmount the filesystem and have this error:
[root@client /]# umount /var/spool/mail umount.nfs: server.example.com:/export: not found / mounted or server not reachable
Running the umount with -v shows the problem.
[root@client /]# umount -v /var/mail mount: trying 192.168.0.1 prog 100005 vers 1 prot tcp port 4002 umount.nfs: server.example.com:/export: not found / mounted or server not reachable mount: trying 192.168.0.1 prog 100005 vers 1 prot tcp port 4002 umount.nfs: server.example.com:/export: not found / mounted or server not reachable
The client is trying to talk version 1 with the version 3 server. For some reason the ount steps up to version 3, the umount doesn't. The workaround is to specify vers=3 in the mount line.
[root@client /]# cat /etc/fstab |grep server server.example.com:/export /export nfs vers=3,rw,nosuid,noac,rsize=32768,wsize=32768 0 0 [root@client /]# mount |grep server server.example.com:/export on /export type nfs (rw,nosuid,remount,nfsvers=3,noac,rsize=32768,wsize=32768,addr=192.168.0.1)
After that the umount works fine.
[root@client /]# umount -v /export mount: trying 192.168.0.1 prog 100005 vers 3 prot tcp port 4002 server.example.com:/export umounted