Reset root/admin password for PhotonOS based HCX Manager
search cancel

Reset root/admin password for PhotonOS based HCX Manager

book

Article ID: 321638

calendar_today

Updated On: 04-16-2025

Products

VMware HCX VMware Cloud on AWS

Issue/Introduction

  • Unable to access HCX Connector or Cloud Manager with "admin" or "root" account.
  • Error "Invalid credentials"

Environment

HCX 4.4 or later

Cause

Resetting a lost or forgotten root/admin password for PhotonOS based HCX Connector or Cloud Manager appliance.

Resolution

The following steps can be followed to reset root/admin password in the HCX Connector or Cloud Manager.
  • Launch the vSphere or ESXi graphical user interface (GUI).
  • Shutdown HCX Connector/Cloud Manager Appliance.
  • Take a snapshot of the HCX Manager VM.
  • Power on the HCX Manager Appliance.
  • After the HCX Manager Photon OS starts, press the "e" key to enter the GNU GRUB Edit Menu.
  • Locate the line that begins with the word Linux.
  • Append these entries to the end of the line:
rw init=/bin/bash
  • Press "F10" OR Ctrl - x to boot with the changed Entry.
  • Run the command  
mount -o remount,rw / 
  • In the Command prompt, enter the command "passwd" and provide a new root password (ask for ReType new Password):
passwd
  • Unmount the filesystem by running this command (the unmount command is umount  -  it's not a spelling error):
umount /
  • Reboot HCX Manager Appliance by running this command:
reboot -f
  • To reset admin password follow the same steps as above but use: passwd admin
  • Reboot the appliance and login with the new password.

Additional Information

Refer HCX - Reset root/admin password for HCX Manager for earlier HCX version password recovery.

Impact/Risks:
Unable to login to PhotonOS based HCX Connector or Cloud Manager using "admin" and/or "root" account to perform administrative tasks. There is NO impact to HCX services while access remains forbidden.
The recovery procedure, which requires a reboot of the HCX Connector or Cloud manager, it should NOT impact:
  • Network Extension services
  • DR Protections
  • Migration workflows in the transfer phase or "waiting for switchover"
Active migration and configurations workflows may be impacted so those must be allowed to complete before proceeding to recover the password.