If you are having issues with your existing XenDesktop Hypervisorconnection, maybe Certificate Errors or something else you can simply create a new Hypervisorconnection and move the existing Machinecatalogs/Desktopgroups to the new Hypervisorconnection via the following powershell commands (tested with XenDesktop 7.17):
look for the line MachineCount of the old HypervisorConnection, wait until it´s showing 0
If you now look into your Citrix Director you maybe see powerstate "unknown" for your machines, so you have to restart all Citrix Services on all DDC´s (or just reboot all of them)
7. Use Citrix Studio or powershell to put the old Hypervisorconnection into maintenance mode.
If you got lot´s of machines and you are showing the hypervisorconnection column within Director it may be showing the old connection name, it seems like the monitoring database needs some time to get updatet, while I was testing this in a customer environment the monitoring database was still showing the old Hypervisorconnection ID for a few hours.
Question
Dennis Reimer1709157751
If you are having issues with your existing XenDesktop Hypervisorconnection, maybe Certificate Errors or something else you can simply create a new Hypervisorconnection and move the existing Machinecatalogs/Desktopgroups to the new Hypervisorconnection via the following powershell commands (tested with XenDesktop 7.17):
1. PS C:\Users\administrator> add-pssnapin citrix*
2. PS C:\Users\administrator> Get-BrokerHypervisorConnection
Capabilities : {PowerOn, PowerOff, SuspendResume, Reset...}
ExplicitPreferredController : False
HypHypervisorConnectionUid : 4ebd79c6-e194-4685-9cf0-83cbd562ab95
IsReady : True
MachineCount : 2
MaxAbsoluteActiveActions : 100
MaxAbsoluteNewActionsPerMinute : 10
MaxAbsolutePvdPowerActions : 50
MaxPercentageActiveActions : 20
MaxPvdPowerActionsPercentageOfDesktops : 25
MetadataMap : {}
Name : XEN01 <-- Existing Hypervisorconnection
PreferredController : Domain\DDC01
State : On
Uid : 1 <-- Existing UiD
Capabilities : {PowerOn, PowerOff, SuspendResume, Reset...}
ExplicitPreferredController : False
HypHypervisorConnectionUid : 42de21c6-c04b-4ace-a1d5-89afa80bdf41
IsReady : True
MachineCount : 1
MaxAbsoluteActiveActions : 100
MaxAbsoluteNewActionsPerMinute : 10
MaxAbsolutePvdPowerActions : 50
MaxPercentageActiveActions : 20
MaxPvdPowerActionsPercentageOfDesktops : 25
MetadataMap : {}
Name : TestHypervisor <-- New Hypervisorconnection
PreferredController : Domain\DDC01
State : On
Uid : 2 <-- New UiD (Note this UiD)
3. PS C:\Users\administrator> Get-BrokerMachine -AdminAddress ddc.domain.local | where {(($_.CatalogName -eq "YourMachineCatalogName"))} | ForEach-Object { set-brokermachine -HypervisorConnectionUid 2 -MachineName $_.MachineName }
(You only have to change the HypervisorconnectionUid, after that the corresponing values will automatically change!)
4. PS C:\Users\administrator>Get-BrokerMachine
Search for a Machine within the changed catalog and look for the following lines, it should be showing the new Hypervisorconnection:
HypHypervisorConnectionUid : 42de21c6-c04b-4ace-a1d5-89afa80bdf41
HypervisorConnectionName : TestHypervisor
HypervisorConnectionUid : 2
Do this for all other machine catalogs and after that:
5. PS C:\Users\administrator> Get-BrokerHypervisorConnection
look for the line MachineCount of the old HypervisorConnection, wait until it´s showing 0
If you now look into your Citrix Director you maybe see powerstate "unknown" for your machines, so you have to restart all Citrix Services on all DDC´s (or just reboot all of them)
6. PS C:\Users\administrator> get-service citrix* | restart-service -force
7. Use Citrix Studio or powershell to put the old Hypervisorconnection into maintenance mode.
If you got lot´s of machines and you are showing the hypervisorconnection column within Director it may be showing the old connection name, it seems like the monitoring database needs some time to get updatet, while I was testing this in a customer environment the monitoring database was still showing the old Hypervisorconnection ID for a few hours.
That´s all!!!!
Hope this helps
Regards
Dennis
Link to comment
14 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