Adding the Local Administrator Account as a Full XenApp Farm Administrator Using Microsoft PowerShell
January 26, 2014
Scenario: You are locked out of the Delivery Services Console or AppCenter or AppCentre and you need in. How? There is a tool called SlimJim you can use or you can use one line of PowerShell. Obviously, I would prefer PowerShell over an unsupported utility even if the utility works.
Here is a screenshot of my XenApp 6.5 AppCenter showing there is no local administrator account.
Note: My domain is Webster.
The first thing I do is open a PowerShell session. Next I type in add-pssnapin *citrix* to load the Citrix XenApp PowerShell cmdlets. Next I type in hostname to verify the name of the local XenApp server. Then I type
new-xaadministrator LocalServerName\administrator -Enabled $True -AdministratorType Full
to add the XenApp server’s local administrator account as a Full Farm Administrator. Since the local administrator account has the same name on every server this effectively adds the local administrator from every XenApp server as a Full Farm Administrator.
Finally I verify in AppCenter the account was added.
To verify the local administrator account had access to AppCenter, I logged in as the local administrator and ran AppCenter.
Granted, you will not have access to AppCenter of the Delivery Service Console but this is just to show you this one line of PowerShell works to add the local administrator account into your XenApp Farm as a Full Farm Administrator.
I only tested this on XenApp 6.5 but the same PowerShell command should work on XenApp 6, XenApp 5 for Server 2003 and XenApp 5 for Server 2008.
Update 30-Jan-2014: I have now tested this on XenApp 5 for Server 2003, XenApp 5 for Server 2008, XenApp 6.0 and XenApp 6.5.