How to reset root password in VMware VCSA appliance

Since there is no option to reset the root password with VCSA running, we need to restart the VCSA in single-user mode. To do that, restart the VCSA, and when the PhotonOS logo is displayed, press e on your keyboard to edit the boot loader. Locate the line starting with linux, and at the end of the line add the following:

rw init=/bin/bash

Now press F10 to continue the boot process. Once in the root shell, mount the root partition:

# mount -o remount,rw /

Now change the root password:

# passwd
# New Password:
# Retype new password:

After the password has been changed, unmount the root partition:

umount /

and restart the VCSA

# reboot -f

Confirm that you can log in using the new root password.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.