How to Reset the Root Password in VMware ESX 4
1.0 Introduction
This Xtravirt hot tip provides information on how to reset the Root password in VMware ESX 4.
Without the root password it is impossible to carry out certain tasks. Even logged on with a non-root account, without knowing it you won’t be able to elevate privileges and adequately manage the server.
2.0 Pre-Requisites
- If the ESX server is part of a cluster, vMotion your VM’s off the host then power down the ESX host. If the ESX server is standalone, power off running VM’s and then shut down the ESX host.
- Access to the physical ESX server console – a remote network session cannot be used.
3.0 Resolution – Resetting the Root password
A lost root password cannot be recovered, but as outlined in the procedure below, it can be reset.
- Power on the ESX server. At the Grub boot loader, select the “VMware ESX 4.0” entry and press a to modify the kernel arguments.
- The default kernel options for the “VMware ESX 4.0” entry will be displayed.
- Add a space and the word single to the end of the list of arguments and press Enter. (Note that the first few arguments will scroll off the left hand side of the console.)
- ESX will boot to single user mode. This may take a minute or so and when complete, a sh-32.# prompt will appear.
- At the prompt, type the command passwd and press Enter. Follow the prompts and enter the required new root password twice. A successful password change will result in the display of a “passwd: all authentication tokens updated successfully” message.
- Enter the command reboot and press Enter. ESX will boot normally.
- When ESX has finished booting, switch to the ESX console by pressing Alt-F1 and confirm the new password has taken affect by logging on as root.
4.0 General Info
If the ESX server is managed by vCenter, you will need to provide the new Root password credentials again in vCenter to reconnect it.
For the procedure on how to reset the root account password for earlier versions of ESX, refer to VMware KB article http://kb.vmware.com/kb/1317898.
- VMware KB, http://kb.vmware.com/kb/1317898
Spotlight:
Microsoft Volume Licensing in Virtualized Environments
If you are a Microsoft volume licensing customer then this paper is a 'must have'
Tape Backup Integration with VMware Data Recovery (VDR)
Move VDR backup data to tape the easy way with Powershell
Beginners Guide to Managing VMware using PowerShell
Release the power...go forth and manage VMware using Microsoft's PowerShell
Technology Exchange:
Paul Davey, Xtravirt CTO - Blog
virtualboy - Matt McSpirit on Windows Server & Virtualisation
ICT-Freak – VMware, Windows, Citrix, Linux, Scripting...
Virtu-Al – Virtually everything is poshable
Download the FREE SolarWinds VM Monitor for Instant Visibility into VMware!
Add3 – Technology Driven Consultancy
ICT-Freak – VMware, Windows, Citrix, Linux, Scripting...



