Changing the vCenter Server user name and password used while installing SRM and configuring VRMS
search cancel

Changing the vCenter Server user name and password used while installing SRM and configuring VRMS

book

Article ID: 304522

calendar_today

Updated On:

Products

VMware Live Recovery

Issue/Introduction

This article provides steps to change the vCenter Server user name and password used while installing vCenter Site Recovery Manager (SRM) and when configuring the vSphere Replication Management Server (VRMS).

Symptoms:
  • Unable to pair SRM sites
  • Unable to start the VRMS service


Cause

If the vCenter Server user name and/or password is accidentally changed, VRMS cannot connect to the vCenter Server and replication stops.

Resolution

Note: Back up both the SRM and VRMS databases before performing the steps below.

  1. Change the vCenter Server user name and/or password in Active Directory.
  2. Run the SRM installer with the modify option at both sites using the new vCenter Server user name and password.
  3. Pair the SRM sites. For more information, see the Connect the Sites section of the Site Recovery Manager Administration Guide.
  4. To change the vCenter Server user name and password used on the vSphere Replication Management Servers (VRMS):

    Note: Repeat this procedure for both servers.

    1. Use SSH to connect to the VRMS, and log in using the root user credentials.
    2. Encode the new vCenter Server user password by running the command:

      python -c "import base64; print(base64.b64encode('new_vCenter_user_password'))"

      The output is an encoded password. For example:

      dmlydHVhbGx5aHlwZXI=

    3. Navigate to the /opt/vmware/hms/conf directory and open the hms-configuration.xml file in a text editor.
    4. Update the password and/or user name in the file by entering the newly encoded password and user name, if applicable. For example:

      <hms-localvc-user>Administrator</hms-localvc-user>
      <hms-localvc-password>Y2EkaGMwdw==</hms-localvc-password>


    5. Connect to the VRMS database with an SQL client.
    6. Highlight the VRMS database from the inventory and open a New Query window.
    7. Extract the key and value pairs for the vCenter Server user name and password stored in the database by running this query:

      SELECT configKey,configValue FROM ConfigEntryEntity;

    8. Update the vCenter Server user password in the ConfigEntryEntity table by running this query:

      UPDATE ConfigEntryEntity SET configValue = 'encoded_new_vCenter_user_password' WHERE configKey = 'hms-localvc-password'

    9. If you also changed the vCenter Server user name, update it in the ConfigEntryEntity table by running this query:

      UPDATE ConfigEntryEntity SET configValue = 'new_vCenter_username' WHERE configKey = 'hms-localvc-user'

    10. Verify that the values have been updated correctly by running the query:

      SELECT configKey,configValue FROM ConfigEntryEntity WHERE configKey IN ('hms-localvc-password', 'hms-localvc-user')

      Example output:

      configKey configValue
      hms-localvc-password encoded_new_vCenter_user_password
      hms-localvc-user new_vCenter_username


    11. Restart the hms service to make the changes take effect by running the command:

      /etc/init.d/hms restart

After completing these steps, the VRMS successfully connects to the vCenter Server. Log into Site Recovery Manager and reconfigure the VRMS pairing.