ESXi

 View Only
  • 1.  How to reset root password ESXi version 7

    Posted May 17, 2022 07:03 AM

    How to reset root password ESXi version 7? If anyone know how only the way. Please share



  • 2.  RE: How to reset root password ESXi version 7

    Posted May 17, 2022 07:13 AM

    Hello, officially is you lost the root password you have to reinstall.
    Unofficially you can try this:
    https://www.vmwareblog.org/forgot-esxi-root-password-no-problems-4-ways-reset/




  • 3.  RE: How to reset root password ESXi version 7

    Posted May 17, 2022 07:18 AM

    If you have vCenter and the correct license you can use Host Profiles to reset the root password.

    Reset ESXi Root Password with Host Profile (68079) (vmware.com)

     



  • 4.  RE: How to reset root password ESXi version 7

    Posted May 17, 2022 07:49 AM

    I think, there is a much easier way, that isn't linked yet.

    If the ESXi is registered to vCenter, you can use PowerCLI together with esxcli to reset the password.

    You can also use this script to change the root password periodically

     

     



  • 5.  RE: How to reset root password ESXi version 7

    Posted May 17, 2022 08:49 AM

    Great info.



  • 6.  RE: How to reset root password ESXi version 7

    Posted Jun 10, 2023 12:36 AM

    Excellent, that technique is great.  Thank you.



  • 7.  RE: How to reset root password ESXi version 7

    Posted Jul 28, 2023 06:50 AM

    Can you send me a How-to-Do for your script. I don't work so often with the PowerCli.

    Thanks Manuel



  • 8.  RE: How to reset root password ESXi version 7

    Posted Nov 12, 2023 01:32 AM

    Use Power shell ISE to create the script

    You just need to copy and paste the script and change some values

     

    #THIS SCRIPT MUST BE EDITED AS SHOWN IN THE EXAMPLES

    #Connect to vCenter ip or hostname
    #Example Connect-VIServer 10.60.x.xxx
    Connect-VIServer <vcenter-name>

    #Connect to esxcli you must specify hosname
    #Example $esxcli = Get-EsxCli -VMhost esx1.lab.com -V2
    $esxcli = Get-EsxCli -VMhost <esxi-host-name> -V2


    #Define new password for root
    #Example $arg.password = ‘Changeme!'
    $arg = $esxcli.system.account.set.CreateArgs()
    $arg.id = ‘root’
    $arg.password = ‘NewPassword’
    $arg.passwordconfirmation = $arg.password

    #Set new password leave this as default
    $esxcli.system.account.set.Invoke($arg)