Jun 06

XenApp servers list for each Application with WorkerGroups management


We present you a Powershell command line to retrieve the server list of published application.

The specificity is that we will take the fact that applications can be published directly on servers and/or by a worker group.

The script will then get list of servers contained in the worker group:

[important]Get-XAApplicationReport * | select DisplayName,FolderPath,@{N=’ServerNames’;E={$_.serverNames+($_|?{$_.WorkerGroupNames}|%{Get-XAWorkerGroup $_.WorkerGroupNames}).ServerNames}} |convertto-csv >> export.csv[/important]

Thanks to Hypervisor.fr for the “OneLiner” form.

You can export a CSV file, here export.csv but you can change the ‘ConvertTo-Csv’ to ‘ConvertTo-Html’ and generate a usable HTML file.

As always feel free to comment 🙂



This command is ONLY functionnal if your worker group is populate with Server Farm ( not by OU or ServerGroup )

I will update the command in a second post.

Thanks to Glen for his help about this.



This is a Powershell command allow you to get all servers without regarding their type:

Get-XAWorkerGroupServer NAMEOFYOURWORKER |select servername

You can try command who is NOT finished because if you don’t have a publication publishing with a worker it return a $null

I will make an update (again )

Get-XAApplicationReport * | select DisplayName,FolderPath,@{N=’ServerNames’;E={$_.serverNames+($_|?{$_.WorkerGroupNames}|%{Get-XAWorkerGroup $_.WorkerGroupNames}).ServerNames}}




Skip to comment form

  1. Glen

    The script is not pulling the list of servers contained in the workergroups. any suggestions?

  2. RIZ

    Is there an updated script for OU or ServerGroup ?

    1. Virtuaprodadmin

      Yes i will update it very soon. Sorry for delay

      1. RIZ



  3. M.LY


    Very helpful .

    Thank you

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">