Wednesday, January 11, 2012

Cool PowerShell commands for manipulating XenApp

After installing the XenApp 6 SDK you can do some neat PowerShell scripts to help move things around. I recently created a test farm and needed a way to move all the applications and their settings from the original farm. These commands did it:

First: Export the XenApp configuration

Get-XAApplicationReport * | Export-Clixml c:\testingApps.xml

Copy C:\testingapps.xml to the new server.
Create the folder structure:

Import-Clixml c:\testingapps.xml | New-XAFolder

Load your previous application settings:
Import-Clixml c:\testingApps.xml | New-XAApplication -WorkerGroupNames $null

No comments: