Citrix Virtual Apps and Desktops

USB Diagnostics Tool

CtxUsbDiagnostics.exe is a command-line tool on the VDA to help Citrix admins diagnose and resolve USB device redirection issues experienced on the client in an expedited manner. This utility tool collects vital information required to triage configuration issues associated with USB devices attached to the client that are failing to redirect inside an HDX session.

> **Note :**
>
> Running Command Prompt or Powershell as an administrator is required to ensure the tool has the necessary permissions to perform system-level operations.

Requirements

Session host

  • Operating system
    • Windows 10 1809 or later
    • Windows 11 21H2 or later
    • Windows Server 2016 or later
  • VDA
    • Windows: Citrix Virtual Apps and Desktops Version 2311 or later

Client device

  • Operating system
    • Windows 10 1809 or later
  • Workspace App
    • Windows: version 2311 or later

What does the tool do?

The tool currently provides:

  • SessionID
  • VDA device policies (device rules set in Studio)
  • Client devices and client device policies (device rules)
  • List of devices, their redirection state, and why they were allowed or denied

    USB-Diagnostic-Tool

    Note :

    The administrator can see device information for all active sessions.

Information Displayed

  • Citrix Studio rules - Version 1/2

    • The DDC rules indicate the use of the legacy “Client USB device redirection rules” or “Client USB device redirection rules (Version 2)” policy in Studio. The information listed in this section lists all the rules configured by the Citrix admin.

    DDC-Rules-Ver1

  • Client Default Device Rules

    • This section lists the rules that are set in the registry on the client.

    DDC-Rules-Ver2

  • Device optimization rules

    • The section lists the device optimization rules as set in “Client USB device optimization rules.

    Device Optimization rules

Device List

This section lists valuable information about each device that is connected to the client endpoint, the hardware information, whether it is being redirected or not, whether the correct device redirection rule is set or not, and so on.

Tag Name Description
displayName Lists the common name of the device.
vid Vendor ID
pid Product ID
Interfaces This subsection lists all the interfaces in case the composite device has been split into multiple child devices.
InterfaceNum Indicates the index of the interface descriptor
class Class code
subclass Subclass Code
protocol Protocol
redirectionState Local indicates that the device is not redirected in the ICA session. ThisSession indicates that the device is redirected in the ICA session. OtherSession indicates that the device is redirected in another ICA session.
optiEnabled true indicates that the device is optimized. false indicates that the device is not optimized and the data transfer happens over the USB virtual channel.
deviceType generic indicates that the device does not have an optimized virtual channel and the traffic is flowing through the USB virtual channel. optimized implies that the data transfer associated with the device is happening over a dedicated virtual channel.
isDenied true indicates that the device is not redirected because of a policy rule set by the admin. false indicates that the device is redirected because of applied policy.
denyRule This field is useful if isDenied is set to true. It tells the admin the specific rule set in the policy that is resulting in the device not getting redirected.
USB Diagnostics Tool