vCenter upgrade fails with message "Failed to set hostname"
search cancel

vCenter upgrade fails with message "Failed to set hostname"

book

Article ID: 408609

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

  • vCenter upgrade might fail stage 2 with below message:
  • PNID and Hostname of the vCenter will be matching in this case.

Environment

  • VMware vCenter 7.0
  • VMware vCenter 8.0

Cause

  • In the /etc/hosts file of the vCenter, there were additional entries added with the temporary IP of the vCenter and FQDN.

Resolution

  • Ensure DNS resolution is working for vCenter IP and FQDN, additionally temporary IP is reachable from vCenter 
  • Edit the /etc/hosts file to remove the additional entries.
  • The content should look like this after edit:
    • # VAMI_EDIT_BEGIN
      # Generated by Studio VAMI service. Do not modify manually.
      127.0.0.1  <VC_FQDN> <VC_shortname> localhost
      ::1  <VC_FQDN> <VC_shortname> localhost ipv6-localhost ipv6-loopback
      # VAMI_EDIT_END