The first time through I was able to mount my nfs backup share to all 4 esxi hosts using the vsphere->storage->related objects->datastores->new wizard with no problems.
But my nfs server got rebooted and the hosts didn't automatically remount it after it came back up. So I deleted the entry for the
share in vsphere. But I couldn't remount it using the same wizard.
I logged into the esxi shell and ran
esxcfg-nas -a VMBNFS -o hostname -s /backup
it said:
Connecting to NAS volume: VMBNFS
Unable to connect to NAS volume VMBNFS: Sysinfo error on operation returned status : Unable to query remote mount point's attributes. Please see the VMkernel log for detailed error information
/var/log/vmkernel.log says:
2016-10-06T23:15:19.823Z cpu14:14322423)NFS: 157: Command: (mount) Server: (vmb.coas.missouri.edu) IP: (128.206.72.86) Path: (/backup) Label: (VMBNFS) Options: (None)
2016-10-06T23:15:19.823Z cpu14:14322423)StorageApdHandler: 698: APD Handle 2fd087ff-e4566bb9 Created with lock[StorageApd0x410af9]
2016-10-06T23:15:19.826Z cpu14:14322423)NFS: 1244: NFS FSINFO failed with NFS status 70 (Stale file handle) on Server (128.206.72.86) Path (/backup)
2016-10-06T23:15:19.826Z cpu14:14322423)StorageApdHandler: 745: Freeing APD Handle [2fd087ff-e4566bb9]
2016-10-06T23:15:19.826Z cpu14:14322423)StorageApdHandler: 808: APD Handle freed!
2016-10-06T23:15:19.826Z cpu14:14322423)NFS: 218: NFS mount vmb.coas.missouri.edu:/backup status: Unable to query remote mount point's attributes
The stale file handle had me thinking there was some residual cached info on the esxi hosts that was confusing things. Anyway, after much hair pulling and gnashing of teeth,
I thought to ask the nfs server what it thought its active nfs clients were.
showmount
and the esxi hosts were still listed there! This was after a reboot, so it was a bit of a surprise. Anyway, long story short, I cleared out the cache file on the server:
exportfs -ua
:> /var/lib/nfs/rmtab
exportfs -a
After that I was able to remount the share with no problem!
Just thought I'd try to save someone else the trouble.