CUDA reports no devices present when logging in over SSH

1

I'm on Windows 7, CUDA 5, but I also experienced this with CUDA 4.2 (prompting an upgrade to 5.)

I remote in over SSH (using cygwin's ssh), and when I run the following test program, it tells me no device present.

$ ./a.exe
CUDA error: no CUDA-capable device is detected

$ cat test.cu
#include <stdio.h>

__global__ void foo()
{
}

int main()
{
  foo<<<1,1>>>();
  printf("CUDA error: %s\n", cudaGetErrorString(cudaGetLastError()));
  return 0;
}

When I try to run deviceQuery, it loops infinitely. Here's a snippet:

CUDA Device #91366
Major revision number:         0
Minor revision number:         0
Name:                          pqrstuvwB
Total global memory:           1895825521
Total shared memory per block: 3
Total registers per block:     -1073741632
Warp size:                     0
Maximum memory pitch:          132
Maximum threads per block:     -1819111168
Maximum dimension 0 of block:  -1751738988
Maximum dimension 1 of block:  1997970554
Maximum dimension 2 of block:  0
Maximum dimension 0 of grid:   1895825521
Maximum dimension 1 of grid:   0
Maximum dimension 2 of grid:   0
Clock rate:                    0
Total constant memory:         0
Texture alignment:             0
Concurrent copy and execution: Yes
Number of multiprocessors:     0
Kernel execution timeout:      No

These programs give the expected output when run locally. I have two GTX 480's and a 9500 GT. In a prior version (I guess pre-4.2) this did work, and I used it for developing CUDA apps remotely. Now I cannot.

I saw some remarks about CUDA not working over Remote Desktop, and suggesting people switch to VNC - but nothing about SSH. For what it's worth, it happens when the monitors are both on and off.

Tom Ritter

Posted 2012-12-02T20:59:28.503

Reputation: 966

After SSHing in, try to run export COMPUTE=:0 before running the GPU app. If that doesn't work, try to compare the environment variables that you have in the local session with the ones in the remote session and alter the remote session to match the local one. – Roger Dahl – 2012-12-02T21:57:19.830

No answers