• Home
  • Podcast
  • Contact
Ervik.as
Cloud, Cyber Security, EUC, DaaS and HCI
  • Cloud
    • Azure
    • Citrix Cloud
    • Cloud Management
    • Nutanix Clusters
  • Cyber Security
    • Arctic Wolf
    • Cyber Security News
  • EUC
    • Citrix
      • Citrix Analytics
      • Citrix NetScaler
      • Citrix Provisioning
      • Receiver
      • ShareFile
      • Citrix Virtual Apps (XenApp)
      • Citrix Virtual Desktops (XenDesktop)
      • Workspace
      • Workspace app
    • DaaS
      • Azure Virtual Desktop
      • Frame
    • Microsoft
      • HoloLens
      • Microsoft App-V
      • Remote Desktop Services
      • Windows 7
      • Windows 8
      • Windows 10
      • Windows Server 2008
      • Windows Server 2008 R2
      • Windows Server 2012
      • Windows Server 2012 R2
      • Windows Server 2016
    • Thin Clients
      • Igel
      • Wyse
    • VMware
      • Fusion
      • Horizon View
      • Vmware ThinApp
      • Vmware Workstation
    • Parallels
      • Remote Application Server
  • End User Experience
    • ControlUp
    • eG Innovations
    • Goliath Technologies
    • Liquidware
  • Datacenter
    • Backup & Disaster Recovery
      • Altaro
      • HYCU
      • Unitrends
      • Rubrik
      • Veeam Software
    • Containers
      • Docker
      • Red Hat OpenShift
    • Hybrid Multi Cloud
      • Nutanix
        • Nutanix Database Service
        • Files
        • Flow
        • Nutanix AHV
        • Nutanix Cloud Platform
    • Server Virtualization
      • Nutanix AHV
      • Microsoft Hyper-V
      • VMware vSphere
      • Citrix Hypervisor (XenServer)
    • Network & Security
      • Nutanix Flow
      • Palo Alto Networks
  • About
    • Cookie Policy (EU)
    • News
      • Citrix Community News

XenDesktop

Citrix XenDesktop Image Management Script

Alexander Ervik Johnsen Citrix, Control Machine, Desktop Virtualization, Image Management, Script, VDI, VHD, XD, XenDesktop, XenDesktop Multi-site, XenServer, XenServer API 2011-09-22

Currently XenDesktop does not support multi-site deployment. If the administrator has same images, they have to manually keep all the images in sync. Citrix has come up with a way to automate this process.

Beside the general XenDesktop components, there are the following few additional components required to perform Image Management.

Note: These additional components are not part of either XenDesktop or XenServer.

Control Machine

Control Machine is Windows OS which has Desktop Studio (for XenDeskop SDK) and XenServer PowerShell SDK installed. This machine hosts the PowerShell script (Control Script) which manages the image synchronization and updating of slave Catalogs.

Control Script

The Control Script is a PowerShell script which runs on the Control Machine. It interacts with the user by getting the Master Site and Slave Sites details and keep them updated with the progress and result of the sync process.

Sync Script

The Sync Script is a bash script started by the control script and is run in Dom0 on the master site’s XenServer Pool-Master to copy the consolidated image’s VHD file across to a XenServer residing on the slave site. rsync-over-SSH is used to complete this task.

The rationale for placing the sync script on the hypervisor itself rather than on the control machine is that neither of the XenDesktop or XenServer APIs currently provides a mechanism for copying files across hosting units located in different pools or sites.

The sync script is started by the control script on the control machine and takes the following parameters.

  • VDI Name
  • Arbitrary number of Host/SR pairs as targets for the synchronization.

The following is an overview of the sync script’s operations:

    • Managed: True
    • Read-Only: False
  • Resolve the VDI to all possible candidate VHD files on the host’s SRs.
  • Locate the youngest candidate VHD for the given VDI. The assumption being that the youngest file is the product of the most recent consolidation.
  • Determine the mount point of the target host’s SR to copy the VHD file to.
  • Use rsync to initiate the synchronization process.
  • Attempt to verify that the VHD file has indeed been copied to the target.
  • Change the following flags on the VHD file for use in reconsolidation on the slave site:

Considerations

  • The sync script requires interaction with hosts that have visibility of the file-systems associated with the SRs involved in this process.
  • The remote target must be visible over ssh from the host pushing the VHD out.
  • The host initiating the transfer must have been setup for SSH Public Key Authentication for a fully automatic schedulable synchronization.
  • The mount-point for the remote SR must have necessary space and permissions to allow the VHD copy.

Click here to learn more about the Citrix XenDesktop Image Management Tool and download

Related Posts

XenDesktop /

Citrix positioned as a Leader in the 2019-2020 IDC MarketScape for VCC

XenDesktop /

How to Anticipate Citrix End-User Performance Issues with Embedded Intelligence and Automation

XenDesktop /

Citrix Optimizer 2.0.0.109

XenDesktop /

Citrix Receiver 4.x vs Citrix Workspace app 1808

XenDesktop /

How eG Enterprise ensures a samless upgrade to Citrix XenApp & XenDesktop 7.x

‹ Citrix XenApp 6.5 Powershell SDK› Citrix XenServer 6.0 released

Back to Top

Crafted in the land of the Vikings 🇳🇴 by Alexander Ervik Johnsen.
Copyright 2000-2025 - www.ervik.as - All Rights Reserved