Install VDA Failed with Error "Configuration tool AgentConfig.exe failed with error code -2"

Install VDA Failed with Error "Configuration tool AgentConfig.exe failed with error code -2"

book

Article ID: CTX550378

calendar_today

Updated On:

Description

Install VDA failed on Remote PC with error: "Configuration tool AgentConfig.exe failed with error code -2".

=====VDA Installation Log=====
17:42:56.7664       : XenDesktopSetup:GetRegValue: Key Opened successfully. Software\Citrix\Citrix Virtual Desktop Agent
17:42:56.7664       : XenDesktopSetup:GetRegValue: GetValue() failed Software\Citrix\Citrix Virtual Desktop Agent ConfigToolLocation
17:42:56.7664       : XenDesktopSetup:ExecuteBrokerAgentConfigurationTool: toolLocation is C:\WINDOWS\TEMP\Ctx-xxxx\Extract\Image-Full\x64\Virtual Desktop Components\BrokerAgentConfigurationTool\AgentConfig.exe
17:42:56.7674       : XenDesktopSetup:Starting synchronous process 'C:\WINDOWS\TEMP\Ctx-xxxx\Extract\Image-Full\x64\Virtual Desktop Components\BrokerAgentConfigurationTool\AgentConfig.exe' with args '/ExecutionMode:configure /CONTROLLERS:"****'
17:43:17.5711       : XenDesktopSetup:Process completed with error code 0xFFFFFFFE
17:43:17.5711       : XenDesktopSetup:ExecuteBrokerAgentConfigurationTool: returnVal -2
17:43:17.5721 $ERR$ : XenDesktopSetup:Configuration tool AgentConfig.exe failed with error code -2
17:43:17.5770       : XenDesktopSetup:Re-configure failed

Environment

Caution! Using Registry Editor incorrectly can cause serious problems that might require you to reinstall your operating system. Citrix cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk. Be sure to back up the registry before you edit it.

Resolution

Solution 1:
Manually adding/creating [HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\Citrix Virtual Desktop Agent] before running the reconfigure:
  • Name: ConfigToolLocation
  • Type: REG_SZ
  • Value: C:\Program Files\Citrix\Virtual Desktop Agent\Agent Configuration\
Solution 2:
Uninstall VDA using VDA CleanUp Utility, then reinstall it normally.
https://support.citrix.com/article/CTX209255/vda-cleanup-utility
 

Problem Cause

The installation is abnormal, and the Citrix registry key value is missing.

Issue/Introduction

Reconfigure VDA failed because the related registry is missing.