Christian Francke Posted January 27, 2015 Share Posted January 27, 2015 Hi NG, I'm trying to retrieve the associated users and groups from a desktop group which I can see in Studio --> assignments in "Users" get-brokerdesktopgroup won't do. I found the Get-BrokerAccessPolicyRule cmdlet. When I list the includedusers I get empty braces: PS Get-BrokerAccessPolicyRule | select includedusers IncludedUsers-------------{}{}{}{}{} When I run the same cmdlet with -expandproperty I get nothing: PS Get-BrokerAccessPolicyRule | select -ExpandProperty IncludedUsers Any idea how I can get the list of users/groups from a desktop group via PowerShell? Regards Christian 1 Link to comment
0 William Charnell Posted January 28, 2015 Share Posted January 28, 2015 For XD 5.6 (note that this is different for XD 7.x Studio) Studio will set up the user list on either the entitlement policy rule or the assignment policy rule attached to the desktop group, depending on whether the group is a random/shared one or a private/static one. See the cmdlets: Get-BrokerEntitelementPolicyRule or Get-BrokerAssignmentPolicyRule Regards William 2 Link to comment
4 Anand Kumar Nelapati Posted February 14, 2018 Share Posted February 14, 2018 Hi, Here is the command i used to get the details, Get-BrokerMachine -MaxRecordCount 9999 -DeliveryType "DesktopsOnly" |select MachineName, @{l="AssociatedUserNames";e={$_.AssociatedUserNames -join " "}}, @{l="AssociatedUserFullNames";e={$_.AssociatedUserFullNames -join " "}}, DesktopGroupName |Export-Csv usertogroups.csv Thanks Anand Kumar Nelapati 4 Link to comment
0 nitin chitkara Posted January 5, 2016 Share Posted January 5, 2016 http://citrixtroubleshootingsteps.blogspot.in/2016/01/listing-all-dedicated-virtual-desktops.html Link to comment
0 Kailas S Posted March 5, 2019 Share Posted March 5, 2019 Hello Try this Get-BrokerAccessPolicyRule -DesktopGroupName 'Give Desktop Group Name' | select -ExpandProperty includedusers| Select-Object Name Link to comment
0 Sandeep Sandeep Posted July 7, 2020 Share Posted July 7, 2020 On 2/14/2018 at 7:42 PM, Anand Kumar Nelapati said: Hi, Here is the command i used to get the details, Get-BrokerMachine -MaxRecordCount 9999 -DeliveryType "DesktopsOnly" |select MachineName, @{l="AssociatedUserNames";e={$_.AssociatedUserNames -join " "}}, @{l="AssociatedUserFullNames";e={$_.AssociatedUserFullNames -join " "}}, DesktopGroupName |Export-Csv usertogroups.csv Thanks Anand Kumar Nelapati This is perfect, thank you Link to comment
Question
Christian Francke
Hi NG,
I'm trying to retrieve the associated users and groups from a desktop group which I can see in Studio --> assignments in "Users"
get-brokerdesktopgroup won't do.
I found the Get-BrokerAccessPolicyRule cmdlet. When I list the includedusers I get empty braces:
PS Get-BrokerAccessPolicyRule | select includedusers
IncludedUsers
-------------
{}
{}
{}
{}
{}
When I run the same cmdlet with -expandproperty I get nothing:
PS Get-BrokerAccessPolicyRule | select -ExpandProperty IncludedUsers
Any idea how I can get the list of users/groups from a desktop group via PowerShell?
Regards
Christian
Link to comment
5 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now