Citrix Solution for Stateless (Non-Persistent) VDI – Automatic Enrolment of Robots

How to maintain a fixed machine name range, defined in Citrix?

In a Non Persistent VDI, machine name changes constantly at startup (from a set of predefined range). However, any machine-user pair needs to be defined in UiPath Orchestrator.

Below is a way to keep the machine name range defined in Citrix, fixed: 

  • For a correct overview of the Citrix solution, see the picture below, where a minimal Citrix Environment is presented: 

Pre-Requisites : The Software packages needed for solution development are listed below

·        VMware vSphere 5.5 or newer or another L1 hypervisor

·        Citrix XenDesktop, VDA and PVS 6.5 or newer

·        MS Windows 7 or newer

·       MS Windows Server 2008R2 or newer for Orchestrator and other infrastructure machines

·        MS SQL Server 2012 or newer

·       UiPath Orchestrator 2017.1 or newer

Solution Description:

Firstly, create a virtual machine where the UiPath Platform (Robot and Studio) will be installed.

The latest version of UiPath Robot/Studio (currently 2019.10) can be downloaded from the following link:

For this solution (Non-persistent VDI) the installation process has something different. Installation must be done from an elevated command prompt window, where we need to specify the "connectionstring".

  • "connectionstring" is unique for each tenant in UiPath Orchestrator, which means that all robots that are using same "connectionstring" will connect to same tenant. "connectionstring"  can be obtained only after the Windows Integrated Authentication is enabled in Orchestrator.

To enable Windows Integrated Authentication, perform the below

  • To obtain "connectionstring", login to desired tenant in Orchestrator, go to settings. In general tab, the connectionstring can be viewed
  • Installation Command:

msiexec /i UiPathPlatform.msi ADDLOCAL=DesktopFeature,Robot,RegisterService,Packages,StartupLauncher CONNECTIONSTRING= https://orch19lts.unicorn.infra//api/RobotsService/GetConnectionData?tenantId=1 /qn

Where https://orch19lts.unicorn.infra is your full Orchestrator URL and tenantId=1 means “default” tenant 
After the installation is complete, the UiPathRobot service will appear in the windows services list.

  • The robot tray should look like this:
  • The UiPath.settings, located in C:\programdata\UiPath,  file should look like below :
  • Do not provision in Orchestrator a Robot, that use as Robot machine the machine template. Robots that are installed with "connectionstring" parameter will try to connect to the Orchestrator tenant specified in the connectionstring at every heartbeat (2 times in a minute)
  • If the Robot machine is provisioned in Orchestrator, it will accept connection and will populate the securelicensekey area. This key is unique for each machine. If securelicensekey will be the same for all machines, only one robot will be connected, licensed and available.
After UiPath Platform installation is complete, preparation of the master target device from Citrix Provision Services suite can be proceeded with.
  • Select “Target Device Installation"
  • After installation process is completed, master disk can be extracted. This vDisk will be used by all robot machines.
  • The correct configuration for vdisk is:

              Access mode: Standard Image (multi-device, read-only access)

              Cache type : Cache in device RAM with overflow on hard disk

  • A device collection with this boot device needs to be created.
  • To create this device collection, “XenDesktop Setup Wizard” function can be used. 


  • Robot Machines have to be in the same domain, subdomain or another domain but with a 2-way trust relationship with Orchestrator server.
  • In case of different domains with a 2-way trust relationship connectionstring will be changed accordingly in:https://orch19lts.unicorn.infra /api/robotsservice/GetConnectionData?tenantId=1&domainName=domain_nameWhere https://orch19lts.unicorn.infra is your full Orchestrator URL and tenantId=1 means “default” tenant 
  • DomainName= should be filled with robot machines AD domain./
All the machines from the device collection that was previously created in PVS Console can be seen in Citrix Studio, organized in Machine Catalogs:


  • A Citrix Delivery Group was created and populated with machines set to boot from the previously created vdisk. At this point, it is possible to set the VM persistence options along with other settings.


On selection to go with the non-persisting VDI options and nothing is being saved between runs. Every time a VM starts up, it is fresh.
  • All VMs in the Citrix Delivery Group can have power management plans assigned to them, also it is possible to select the manner of assignment between users and machines.


  • At the Orchestrator level, Robots have been provisioned with the assigned users, passwords and machine names.
After a VM finishes the boot process, the corresponding robot can be seen as online in Orchestrator.
  • Post Robot connecting to the Orchestrator, the Robot tray will look like below:
Uipath.settings file will be updated and will look like below:
  • When a Robot will start a job, the user associated with that Robot will create, automatically, a Windows interactive session, on the machine specified, using the credentials (username and password) provided during the Robot provisioning process.
  • To trigger jobs for the available robots in the list (the powered on machines), use “Schedules” from UiPath Orchestrator. This is applicable for versions between 2017.1  and 2019.4 .

  • If the “Execution Target- A number of Robots” function is used, Orchestrator will trigger automatically the available robots.
In the picture below, four available Robots will be triggered from all provisioned Robots:
  • Starting with 2019.10, “Schedules”  have been renamed as “Triggers”
  •  “All robots” needs to be considered, where all robots available at that moment will execute the selected workflow.

  • After the job finishes, the user logs off and Citrix sends the power off command to vSphere for that VM.

The poweroff command can be disabled too.