Citrix Studio - VDI power state unknown

Modificato il Gio, 4 Mag, 2023 alle 4:26 PM

Warning! Back up the XenDesktop database before completing these actions.

  1. Open DDC using the PowerShell console and run the following commands to display all machine IDs of the virtual machines from the hypervisor.

    1
    2
    3
    
    asnp Citrix*
    $ErrorActionPreference=Continue
    Get-ChildItem -Path XdHyp:\ -force -recurse | ?{ $_.IsMachine } | Out-File Filepath c:\xdhyp.txt
    
  2. The xdhyp.txt output file contains the correct machine IDs from the hypervisor. Open that file and press Ctrl+F or Edit > Find. Search for the name of the Virtual Machine, in this case, the name of the Virtual Machine is PVS0003.

    Example output

    PSPath : Citrix.Host.Admin.V1\Citrix.Hypervisor::XDHyp:\Connections\XenServer\PVS0003.vm PSParentPath : Citrix.Host.Admin.V1\Citrix.Hypervisor::XDHyp:\Connections\XenServer PSChildName : PVS0003.vm PSDrive : XDHyp PSProvider : Citrix.Host.Admin.V1\Citrix.Hypervisor PSIsContainer : True Name : PVS0003 FullName : PVS0003.vm ObjectType : Vm Id : 7d1d6004-5319-7a7e-59cb-2662e212a3e5 IsContainer : True IsMachine : True IsSnapshotable : True ObjectPath : /PVS0003.vm FullPath : XDHyp:\Connections\XenServer\PVS0003.vm IsSymLink : False AdditionalData : {}

    Note: The machine ID is as follows:
    Id : 7d1d6004-5319-7a7e-59cb-2662e212a3e5.
    Your result will vary.

  3. Run the following command:
    Get-BrokerMachine -PowerState Unknown This identifies the machines that have the unknown power state.+ Note the “HostedMachineId “ from the output.+ Now comparing the “ID” from Step1, and the “HostedMachineId “ from this step, You’ll find that the IDs are different.+ Correct “Id” is from the Step-1  and incorrect value is present in Database (from step-3)

    • We can also verify the same by Browsing the below tables in SQL site database and confirming the values.
  4. Chb_Config.Workers » HostedMachineId »

    DesktopUpdateManagerSchema.ProvisionedVirtualMachine » VMId »

  5. Run the following command to change the XenDesktop Database’s record for the machine ID to match the Hypervisor’s Machine ID:Set-BrokerMachine -MachineName ‘MyDomain\MyMachine’ -HostedMachineId  [machine ID from preceding output]. This corrects the HostedMachineId for the problem machines using the ID that was retrieved from xdhyp.txt.

  6. Check Desktop Studio or Desktop Director and refresh the list of results.
    The power state must now match the state indicated in the hypervisor.

Note: It might be necessary to restart the Citrix Broker Service on all DDCs and/or restart the virtual machine.



ref. https://support.citrix.com/article/CTX131267/error-power-state-unknown-cdseventhostingfailedpoweraction-in-xendesktop

Questo articolo ti è stato utile?

Fantastico!

Grazie per il tuo feedback

Siamo spiacenti di non poterti essere di aiuto

Grazie per il tuo feedback

Facci sapere come possiamo migliorare questo articolo!

Seleziona almeno uno dei motivi
La verifica CAPTCHA è richiesta.

Feedback inviato

Apprezziamo il tuo sforzo e cercheremo di correggere l’articolo