This is an archive version of the document. To get the most up-to-date information, see the current version.

Set-VBRUserRoleAssignment

Short Description

Modifies a role that is assigned to a user or a user group.

Product Edition: Standard, Enterprise, Enterprise Plus, Veeam Universal License

Syntax

Set-VBRUserRoleAssignment -Assignment <VBRUserRoleAssignment> [-Role {BackupOperator | RestoreOperator | BackupAdmin | TapeOperator |BackupViewer}]  [<CommonParameters>]

Detailed Description

This cmdlet modifies a role that is assigned to a user or a user group

Parameters

Parameter

Description

Type

Required

Position

Accept Pipeline Input

Assignment

Specifies a user or a user group . The cmdlet will modify a role for this user or a user group.

Accepts the VBRUserRoleAssignment object. To create this object, run the Get-VBRUserRoleAssignment cmdlet.

True

Named

True (ByValue,
ByProperty
Name)

Role

Specifies a role that you want to assign to a user. The cmdlet will replace the current role with a new role. You can assign one of the following roles:

  • BackupOperator
  • RestoreOperator
  • BackupAdmin
  • TapeOperator
  • BackupViewer

 

False

Named

False

<CommonParameters>

This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.

Output Object

The cmdlet returns the VBRUserRoleAssignment object that defines a role for a user or a user group.

Examples

Modifying User Role

$user = Get-VBRUserRoleAssignment -Name Tech\BackupAdmin

Set-VBRUserRoleAssignment -Assignment $user -Role RestoreOperator

          Role Type Name            Id

          ---- ---- ----            --

RestoreOperator Group Administrators c5d266c7-8e2b-43f9-92c6-fffc4297074d

Perform the following steps:

  1. Run the Get-VBRUserRoleAssignment cmdlet. Save the result to the $role variable.
  2. Run the Set-VBRUserRoleAssignment cmdlet. Set the $user variable as the Assignment parameter value. Set the $role variable as the Assignment parameter value.

Related Commands

Get-VBRUserRoleAssignment