Assign SRM permissions using SRM MOB
search cancel

Assign SRM permissions using SRM MOB

book

Article ID: 313060

calendar_today

Updated On:

Products

VMware Live Recovery

Issue/Introduction

This article describes how to assign SRM permissions using SRM Managed Object Browser {MOB}.

Symptoms:
The Site Recovery Manager UI fails to find domain users with the search function when trying to add permissions for SRM.
You may see the error  "Failed to connect to vCenter Server at <VC location>:443/sdk. Reason: <VC location>:443/sdk invocation failed with "java.net.SocketTimeoutException: Read timed out" Read timed out"

Environment

VMware vCenter Site Recovery Manager 8.x

Resolution

Stage 1: Examine current account permissions
  1. Ensure that the Site Recovery Manager Managed Object Browser is enabled.
  2. Open the SRM MOB
    1. For Windows-based SRM use https://<SRM-fqdn|IP>:9086/mob where 9086 is the default port that the SRM service is listening.
    2. For the SRM virtual appliance use https://<SRM-fqdn|IP>:443/mob.
  3. Log into MOB using vCenter administrator credentials.
  4. Review the current permissions by navigating to the permissions section of the MOB.
    1. In the Properties table, select the permission link.
    2. Look for the specific user you are concerned with. Note the roleId value set for that user.NOTE: The entity is of type "DrServiceInstance" and the roleId is "-1"
       
  5. There are lots or roleIds defined in vCenter. Identify which roleId you need to set for a specific user:
    1. Connect to ihttps://<vCenter FQDN or IP>/mob
    2. Under the Properties table, select the content link
    3. Select the AuthorizationManager link
    4. Select the roleList link
  6. You see a list of all vCenter roles with roleIDs, These roles match those visible in the vCenter, Administration, Role UI.
  7. Note the roleID value matching the role you want the user to possess.

    Note: In this example, SRM specific roles could be seen with roleIds range [1101, 1106] This may not be the case for your environment as it depends on which other solutions are installed in your environment.
Stage 2: Create a new user
  1. Return to the SRM MOB home page.
  2. Select the content link by DrServiceInstanceContent as shown..
  3. Select the DrAuthorizationManager link.
  4. Select the DrSetEntityPermissions link to invoke that method.                                                                                               
  5. The following dialog box will popup:
  6. Modify the items In this dialog box to suit your need:
    1. Set the MOID in both the entity and permission sections to be the same. If working with a global permission set the MOID to "DrServiceInstance" as seen for the other users in step 4 of Stage 1.
    2. Set the principle in the permission section to the account you are setting the permissions on in the DOMAIN\User format.
    3. If the principle is a domain group, set the group tag to true, else leave it as false.
    4. If all child entities have the same permissions, set the propagate flag to true. For example, if you set permission for SRM root object “DrServiceInstance” then this flag must be true so this permission will be global and applied on all SRM objects like Protection Group, Recovery Plans and folders. This matches the meaning of the same parameter seen through the disaster recovery UI.
    5. Set roleId to the integer number representing desired the role (as identified in step 5 of Stage 1). Such as, ‘Administrators’, ‘ReadOnly-Access’ and so forth. Example:, ‘-1’ represents the vCenter Administrator role with full access rights and ‘1101’ represents the SRM Administrator Role.
  7. When finished, select the Invoke Method link.
    1. If the result is successful ti will display the message "Method Invocation Result: void"
 

Example:

How to set SRM global permission for a Recovery Admin user:
We will use principal VSPHERE.LOCAL\nonadminuser for which we want to set a global permission with “SRM Recovery Administrator” role which means this user will be able to run Recovery Plans only and won’t be able to perform any configuration changes.
 

For this purpose we need to set the following parameters for

ManagedObjectReference:DrManagedEntity method:
<entity type="DrManagedEntity">DrServiceInstance</entity>

DrSetEntityPermissions method:

<entity type="DrManagedEntity">DrServiceInstance</entity>
<principal>VSPHERE.LOCAL\nonadminuser</principal>
<group>false</group>
<roleId>1105</roleId>
<propagate>true</propagate>


Or as shown below:


As described above this can be confirmed in the SRM permissions pane of the UI: