Troubleshoot Slack in a Citrix environment

If you're using Slack with Citrix and having trouble launching the desktop app, learn more about this problem and how to fix it. 

 

Issues launching Slack

What's causing this problem

Citrix environments, like XenApp and XenDesktop, use Dynamic-Link Library (DLL) redirection to route API calls that perform extra tasks before calling Windows operating system APIs. 

Due to an incompatibility between the Slack desktop app and Citrix's third-party DLLs, Slack may fail to load in Citrix environments. 

 

What you'll see when launching Slack

The Slack app will appear not to start after you attempt to launch it. However, if you open the task manager, you'll see slack.exe processes running. Slack may show up in the taskbar as well, but you won't be able to interact with the app. 

Typically, the app will finish launching after about 15 minutes and perform normally — but you'll see multiple reports of the slack.exe process crashing from that time period. 

 

Exempt slack.exe from DLL hooking

To resolve problems launching the Slack app, you can exempt specific processes from your Citrix environment's DLL hooking mechanism. You can either add registry values manually or run a PowerShell script to create registry values automatically. 

Add the slack.exe registry value manually

  1. From your computer, press the Win and R keys, then type regedit.exe
  2. Check for the following keys and add any you don't see:
    HKEY_LOCAL_MACHINE/SOFTWARE/Citrix/CtxHook>
    HKEY_LOCAL_MACHINE/SOFTWARE/Wow6432Node/Citrix/CtxHook
    HKEY_LOCAL_MACHINE/SOFTWARE/Wow6432Node/Citrix/CtxHook64
    HKLM/SYSTEM/CurrentControlSet/services/CtxUvi
  3. Make sure slack.exe is listed as the value for each of these keys. When adding slack.exe to keys with other exempted processes, make sure they're separated by a comma.

 

Run a PowerShell script to create registry values 

  1. Download this PowerShell script.
  2. When the download is complete, right-click the script file and select Run with PowerShell
  3. Reboot your machine, then re-launch the Slack desktop app. 

Tip: if you're unable to run the PowerShell script because of an execution policy violation, follow Microsoft's documentation to update your computer's policies.