Get-SCUserRole

Get-SCUserRole

Gets a VMM user role.

構文

Parameter Set: Default
Get-SCUserRole [[-Name] <String> ] [-ID <Guid]> ] [-OnBehalfOfUser <System.String> ] [-OnBehalfOfUserRole <Microsoft.SystemCenter.VirtualMachineManager.UserRole> ] [-UserRoleProfile <Profile]> ] [-VMMServer <ServerConnection> ] [ <CommonParameters>]

詳細説明

The Get-SCUserRole cmdlet gets one or more Virtual Machine Manager (VMM) user roles. VMM uses role-based security to define the boundaries within which members of a given user role can operate and the set of allowed operations members of a user role can perform.

For information about creating user roles, type Get-Help New-SCUserRole -detailed.

For information about setting the properties of a user role, including the scope for delegated and read-only administrators and the scope and actions for self-service users, type Get-Help Set-SCUserRole -detailed.

パラメーター

-ID<Guid]>

Specifies the numerical identifier as a globally unique identifier (GUID) for a specific object.

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-Name<String>

Specifies the name of a VMM object.

エイリアス

none

必須?

false

位置は?

1

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-OnBehalfOfUser<System.String>

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-OnBehalfOfUserRole<Microsoft.SystemCenter.VirtualMachineManager.UserRole>

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-UserRoleProfile<Profile]>

Specifies the type of profile to use as the basis for the user role. Valid values are:

-- DelegatedAdmin
-- ReadOnlyAdmin
-- SelfServiceUser

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

false

ワイルドカード文字を許可する

false

-VMMServer<ServerConnection>

Specifies a VMM server object.

エイリアス

none

必須?

false

位置は?

named

既定値

none

パイプライン入力を許可する

True (ByValue)

ワイルドカード文字を許可する

false

<CommonParameters>

このコマンドレットは次の共通パラメーターをサポートします。-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、-OutVariable.詳細については、以下を参照してください。 about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216)。

入力

入力型は、コマンドレットにパイプできるオブジェクトの型です。

出力

出力型は、コマンドレットによって生成されるオブジェクトの型です。

  • UserRole

Example 1: Get all VMM user roles

This command gets all VMM user role objects on VMMServer01 and displays information about each user role.

PS C:\> Get-SCUserRole -VMMServer "VMMServer01.Contoso.com"

Example 2: Get a specific user role by name

This command gets the user role object named Administrator, and then displays information about that user role.

PS C:\> Get-SCUserRole -Name "Administrator"

Example Example 3: Get a specific user role by UserRoleProfile.

This command gets the user role objects on VMMServer01 that have a UserRoleProfile value of SelfServiceUser, and then displays information about these users role.

PS C:\> Get-SCUserRole -VMMServer "VMMServer01.Contoso.com" -UserRoleProfile "SelfServiceUser"

Example Example 4.: Display properties and other information about user role objects.:

The first command gets all user role objects on VMMServer01, and then stores the objects in the $UserRoles variable.

The second command passes each user role object in $UserRoles to select, the alias for the Select-Object cmdlet, and then displays the name, user role profile, parent user role, and cloud for each user role.

The last command passes each user role in $UserRoles to the Get-Member cmdlet, which displays the .NET type for each user role and the methods and properties associated with each user role type.

PS C:\> $UserRoles = Get-SCUserRole -VMMServer "VMMServer01.Contoso.com"
PS C:\> $UserRoles | select Name, UserRoleProfile, ParentUserRole, Cloud
PS C:\> $UserRoles | Get-Member

関連トピック

Grant-SCResource

New-SCUserRole

Remove-SCUserRole

Revoke-SCResource

Set-SCUserRole