vSphere PowerCLI Reference

Get-VIPrivilege

Synopsis

Retrieve the privilege groups and items for the provided servers.

Syntax

Get-VIPrivilege [-PrivilegeGroup] [-PrivilegeItem] [[-Name] <String[]>] [-Id <String[]>] [-Server <VIServer[]>] [<CommonParameters>]
Get-VIPrivilege [[-Name] <String[]>] [-Role] <Role[]> [-Id <String[]>] [<CommonParameters>]
Get-VIPrivilege [[-Name] <String[]>] [-Group] <PrivilegeGroup[]> [-Id <String[]>] [<CommonParameters>]

Related Commands

Online version
Get-VIRole
New-VIRole
Remove-VIRole
Set-VIRole

Detailed Description

Retrieve the privilege groups and items for the provided servers.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
NameString[]Specify the names of the privileges you want to retrieve.falsefalse
GroupPrivilegeGroup[]Specify the privilege group whose items you want to retrieve.truetrue (ByValue)
RoleRole[]Specify the roles whose privileges you want to retrieve.truetrue (ByValue)
IdString[]Specify the Ids of the privileges you want to retrieve.falsefalse
PrivilegeGroupSwitchParameterIndicate that you want to retrieve only the privilege groups and not the privilege items in them.falsefalse
PrivilegeItemSwitchParameterIndicate that you want to retrieve only the privilege items and not the privilege groups.falsefalse
ServerVIServer[]Specify the vSphere servers on which you want to run the cmdlet. If no value is given to this parameter, the command runs on the default servers. For more information about default servers, see the description of Connect-VIServer.falsefalse

Return Type

Privilege

Notes

Examples

-------------- Example 1 --------------

Get-VIPrivilege -Name "Host*"

Retrieves all privileges with names that start with "Host".

-------------- Example 2 --------------

Get-VIPrivilege -PrivilegeGroup

Retrieves all privilege groups.


Copyright © 1998 - 2012 VMware, Inc. All rights reserved.