"An error occurred while connecting to depot" due to DNS resolution failure when trying to update the ESXi host using cluster image
search cancel

"An error occurred while connecting to depot" due to DNS resolution failure when trying to update the ESXi host using cluster image

book

Article ID: 411379

calendar_today

Updated On:

Products

VMware vSphere ESXi VMware vCenter Server

Issue/Introduction

  • Running a compliance check or remediation on a cluster using an image-based configuration fails.
  • ESXi host /var/run/log/lifecycle.log shows below log lines:
    YYYY-MM-DDTHH:MM:SS Er(11) lifecycle[25002320]: imagemanagerctl:90 vmware.esximage.Errors.DepotConnectError: ([MetadataDownloadError('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-227__index__.xml', '', "Could not download from depot at http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-227__index__.xml, skipping (('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-227__index__.xml', '', '<urlopen error [Errno -3] Temporary failure in name resolution>'))"), MetadataDownloadError('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-149__index__.xml', '', "Could not download from depot at http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-149__index__.xml, skipping (('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-vmw__metadata-149__index__.xml', '', '<urlopen error [Errno -3] Temporary failure in name resolution>'))"), MetadataDownloadError('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-DEL__metadata-211__index__.xml', '', "Could not download from depot at http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-DEL__metadata-211__index__.xml, skipping (('http://<vCenter Server FQDN>:9084/vum/repository/hostupdate/__micro-depot__vendor-DEL__metadata-211__index__.xml', '', '<urlopen error [Errno -3] Temporary failure in name resolution>'))")
  • During VCF cluster creation the task can fail at : Remediate ESXi Host(s) to be Compliant with Cluster's Image - Failed
  • On the vShere Client UI you see:
    • Failed to connect to depot: 'URL: 'http://<VC_FQDN>:9084/vum/repository/hostupdate/....' Error: <urlopen error [Errno -3] Temporary failure in name resolution>"
  • ESXi host is unable to resolve the vCenter IP address. It can be validated with the below command
    • nslookup <VC_FQDN/IP> 

Environment

  • VMware ESXi 8.x/9.x
  • VMware vCenter Server using vLCM with cluster images
  • VCF 5.x/9.x
  • Restricted network / DMZ environment with Port 53 blocked

Cause

"Temporary failure in name resolution" means the ESXi host is unable to resolve the vCenter Server referenced in the error.

Resolution

  1. Ensure the ESXi host is able to resolve the DNS name of the vCenter Server to an IP address.
  2. If the DNS is wrong, update the DNS by following the document Configuring DNS settings.
  3. If the communication to DNS is blocked in your environment, follow Configure the DNS Hosts File by Using ESXCLI Commands.

Additional Information

Error: An error occurred while connecting to depot during ESXi vLCM image upgrade in vSphere 7.x and 8.x