Quantcast
Channel: VMware Communities: Message List
Viewing all articles
Browse latest Browse all 293210

Re: New-VIPermission bug still exists in PowerCLI 5.0?

$
0
0

Hi Terry.

 

Please see my earlier post in this thread.  For some reason, the name of the Authorization Manager changes with the vSphere 5. objects.

 

Here's the code I posted earlier.

 

$domain = "ourDomain"

$groupname = "ourGroup"

$svcgroup = $domain + "\" + $groupname

$folder = Get-Folder -Name "ha-folder-root"

$authMgr = Get-View "AuthorizationManager-ha-authmgr"

$perm = New-Object VMware.Vim.Permission

$perm.principal = $svcgroup

$perm.group = $true

$perm.propagate = $true

$perm.roleid = ($authMgr.RoleList | where{$_.Name -eq "Admin"}).RoleId

$authMgr.SetEntityPermissions(($folder | Get-View).MoRef, $perm)


Viewing all articles
Browse latest Browse all 293210

Trending Articles