NFS datastore mount operation failed with an error "Failed DNS Lookup : Hostname"
search cancel

NFS datastore mount operation failed with an error "Failed DNS Lookup : Hostname"

book

Article ID: 393115

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Unable to mount NFS datastore.
Mount operation fails from both, UI and ssh.

Environment

VMware vSphere ESXi 8.0.x 
VMware vSphere ESXi 7.0.1 and later

Cause

The mount operation can fail if there is a stale entry of the NFS Datastore configuration in the Configuration Store of ESXi

Resolution

Remove the related stale entry in the ESXi Configuration Storage.

To remove one specific NFS 3 datastore
configstorecli config current delete -c esx -g storage -k nfs_v3_datastores --i nfs_datastorename

To remove all NFS 3 datastores
configstorecli config current delete -c esx -g storage -k nfs_v3_datastores --all

To remove one specific NFS 4.1 datastore
configstorecli config current delete -c esx -g storage -k nfs_v41_datastores  --i nfs4.1_datastorename

To remove all NFS 4.1 datastores
configstorecli config current delete -c esx -g storage -k nfs_v41_datastores  --all

We may now mount the NFS Datastore

Additional Information

ESXi 7.0U1 onward, the NFS configuration is saved in a Configuration Store unlike old versions where it was saved in /etc/vmware/esx.conf file. We may review it by running the following commands:

NFS 3
configstorecli config current get -c esx -g storage -k nfs_v3_datastores

NFS 4.1
configstorecli config current get -c esx -g storage -k nfs_v41_datastores