CUDA and Remote Desktop

Problem

If you connect to a CUDA-capable Windows computer using Remote Desktop and run CUDA programs on it, they fail. That is, CUDA programs fail if they are executed under a Remote Desktop Protocol (RDP) session.

Explanation

In the RDP universe, the CUDA-capable computer is the RDP server and the computer connecting to it is the RDP client. When a Windows computer becomes a RDP server, its graphics driver (say, a NVIDIA driver) is replaced with a RDP graphics driver of Windows.

The RDP graphics driver converts display information into RDP packets and sends it to the client. This is why the display of the RDP server goes blank when it is involved in a RDP session.

At the RDP client, the data in these packets are interpreted as Windows Graphics Device Interface (GDI) information and used to draw the corresponding windows. Thus, RDP is somewhat similar to how X works in the Linux world. This is what gives RDP its speed, performance and other capabilities.

But, this is also why CUDA will not work over RDP. Windows replaces the CUDA-capable NVIDIA graphics driver with its RDP graphics driver. Thus, all CUDA programs fail.

Solution

Instead of RDP, pick any alternate solution that does not touch the graphics driver. That is, something that allows the graphics driver to render, and then captures and sends the desktop information as a bitmap to the other end. So, desktop sharing solutions like VNC or TeamViewer work fine with CUDA.

Reference: Remote Desktop Protocol at MSDN

3 thoughts on “CUDA and Remote Desktop

  1. When I use teamviewer, it works first; but suddenly, the power to use cuda got lost…Do you have any advice?

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.