Change Device Order Change default GPU


I am working with a multi-gpu system. It has a Tesla c2070 and two GTX 570s. My problem is, the programs my lab uses all use the default gpu. (Device 0) Which would be fine if the device 0 was the tesla card, but it is not.

I have the Tesla card plugged into bus 1 and the two GTX cards in 7 and 8. I tried physically swapping them and it made no difference in order. I even tried swapping them in the xorg.conf file.

Any idea how I can change the devices around? Or bet set the default device on the fly?

Thank you,

Matthew Caylor
Department of Chemistry and Biochemistry, BSU.

Drives or cards?

Typo, devices. As in video cards.

Either that or how to tell which device maps to which physical card?

CUDA_VISIBLE_DEVICES=1,2,0 ./application

Was hopeful that would work, but it is a bust. Still have all three cards showing…except it works for deviceQuery. That is interesting.

A library trace later I find that the program I running calls unsetenv on CUDA_VISIBLE_DEVICES, thank you for you help.