invalid device ordinal (I can't find any help about this)
so I'm using GTX 590 on ubuntu 10.04 64bit
recently I tried to update cuda toolkit to 4.2 version, so I updated the cuda driver and cuda toolkit,
then when i was trying to build the newest gpu computing sdk, I went successfully
however i got a problem, when i tried to run ./deviceQuery, this message appeared

./deviceQuery Starting...

CUDA Device Query (Runtime API) version (CUDART static linking)

cudaGetDeviceCount returned 10
-> invalid device ordinal
[deviceQuery] test results...
FAILED

then tried to revert back to previous toolkit version 4.1 with it's devdriver and computingsdk, however it didnt work, still the same error msg
anyone can help me about this?

i tried to find any helpful post about this, but there is nothing.. anyone can help me?
so I'm using GTX 590 on ubuntu 10.04 64bit

recently I tried to update cuda toolkit to 4.2 version, so I updated the cuda driver and cuda toolkit,

then when i was trying to build the newest gpu computing sdk, I went successfully

however i got a problem, when i tried to run ./deviceQuery, this message appeared



./deviceQuery Starting...



CUDA Device Query (Runtime API) version (CUDART static linking)



cudaGetDeviceCount returned 10

-> invalid device ordinal

[deviceQuery] test results...

FAILED



then tried to revert back to previous toolkit version 4.1 with it's devdriver and computingsdk, however it didnt work, still the same error msg

anyone can help me about this?



i tried to find any helpful post about this, but there is nothing.. anyone can help me?

#1
Posted 04/30/2012 09:43 AM   
Hello, a you solve you problem?

I have same problem.
i have next:
ubuntu 11.04 natty
two cards 9800GTX+
Tesla C2050.
monitor connect to geforce.
devdriver,toolkit,sdk installing succesfully.
bur i run ./deviceQuery
i have the same error
cudagetDeviceCount returned 10
invalid device ordinal .
if use only one card all work fine.

what you amount of RAM?
wherewer i read that the problem in amount of host memory.

p.s. cuda version 4.0 and 4.2

sorry for my poor english.
Hello, a you solve you problem?



I have same problem.

i have next:

ubuntu 11.04 natty

two cards 9800GTX+

Tesla C2050.

monitor connect to geforce.

devdriver,toolkit,sdk installing succesfully.

bur i run ./deviceQuery

i have the same error

cudagetDeviceCount returned 10

invalid device ordinal .

if use only one card all work fine.



what you amount of RAM?

wherewer i read that the problem in amount of host memory.



p.s. cuda version 4.0 and 4.2



sorry for my poor english.

#2
Posted 05/08/2012 05:40 PM   
Double check that you are running the Nvidia driver ( cat /proc/driver/nvidia/version ) and not what Ubuntu decided was the best for you....
Double check that you are running the Nvidia driver ( cat /proc/driver/nvidia/version ) and not what Ubuntu decided was the best for you....

#3
Posted 05/08/2012 05:53 PM   
thanks for reply)

please, tell what linux will the best for me

i will try use the CentOS 6.2 DVD (x86_64),and i think,that all will work fine

i want to bench my hardware with Cuda Accelerated Linpack.

but i know linux a little(
thanks for reply)



please, tell what linux will the best for me



i will try use the CentOS 6.2 DVD (x86_64),and i think,that all will work fine



i want to bench my hardware with Cuda Accelerated Linpack.



but i know linux a little(

#4
Posted 05/13/2012 03:12 PM   
[quote name='ghostRustam' date='13 May 2012 - 07:12 AM' timestamp='1336921962' post='1407772']
thanks for reply)

please, tell what linux will the best for me

i will try use the CentOS 6.2 DVD (x86_64),and i think,that all will work fine

i want to bench my hardware with Cuda Accelerated Linpack.

but i know linux a little(
[/quote]

Hi, I ran into same error ( invalid device ordinal ) with CUDA 5 on Redhat EH6:
cat /proc/driver/nvidia/version
NVRM version: NVIDIA UNIX x86_64 Kernel Module 302.06.03 Thu May 3 18:19:16 PDT 2012
GCC version: gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)

I followed the suggestion from an earlier thread .. 2010
.. > sudo -i
# cd /your/executable/blah-blah
# ./blah-blah

and it seems to go away.

What bugs me is there seems to be a lack of explanation for this. Does it mean everyone has to be root to run CUDA codes ?
Thanks ahead Nvidia for monitoring this thread..
[quote name='ghostRustam' date='13 May 2012 - 07:12 AM' timestamp='1336921962' post='1407772']

thanks for reply)



please, tell what linux will the best for me



i will try use the CentOS 6.2 DVD (x86_64),and i think,that all will work fine



i want to bench my hardware with Cuda Accelerated Linpack.



but i know linux a little(





Hi, I ran into same error ( invalid device ordinal ) with CUDA 5 on Redhat EH6:

cat /proc/driver/nvidia/version

NVRM version: NVIDIA UNIX x86_64 Kernel Module 302.06.03 Thu May 3 18:19:16 PDT 2012

GCC version: gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)



I followed the suggestion from an earlier thread .. 2010

.. > sudo -i

# cd /your/executable/blah-blah

# ./blah-blah



and it seems to go away.



What bugs me is there seems to be a lack of explanation for this. Does it mean everyone has to be root to run CUDA codes ?

Thanks ahead Nvidia for monitoring this thread..

#5
Posted 06/27/2012 12:44 AM   
[quote name='cudaha' date='26 June 2012 - 04:44 PM' timestamp='1340757850' post='1426978']
Hi, I ran into same error ( invalid device ordinal ) with CUDA 5 on Redhat EH6:
cat /proc/driver/nvidia/version
NVRM version: NVIDIA UNIX x86_64 Kernel Module 302.06.03 Thu May 3 18:19:16 PDT 2012
GCC version: gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)

I followed the suggestion from an earlier thread .. 2010
.. > sudo -i
# cd /your/executable/blah-blah
# ./blah-blah

and it seems to go away.

What bugs me is there seems to be a lack of explanation for this. Does it mean everyone has to be root to run CUDA codes ?
Thanks ahead Nvidia for monitoring this thread..
[/quote]

I stand corrected ..
After getting it to run once, you can exit all-mighty shell and run as mere mortals..
[quote name='cudaha' date='26 June 2012 - 04:44 PM' timestamp='1340757850' post='1426978']

Hi, I ran into same error ( invalid device ordinal ) with CUDA 5 on Redhat EH6:

cat /proc/driver/nvidia/version

NVRM version: NVIDIA UNIX x86_64 Kernel Module 302.06.03 Thu May 3 18:19:16 PDT 2012

GCC version: gcc version 4.4.6 20110731 (Red Hat 4.4.6-3) (GCC)



I followed the suggestion from an earlier thread .. 2010

.. > sudo -i

# cd /your/executable/blah-blah

# ./blah-blah



and it seems to go away.



What bugs me is there seems to be a lack of explanation for this. Does it mean everyone has to be root to run CUDA codes ?

Thanks ahead Nvidia for monitoring this thread..





I stand corrected ..

After getting it to run once, you can exit all-mighty shell and run as mere mortals..

#6
Posted 06/27/2012 01:13 AM   
[quote name='cudaha' date='27 June 2012 - 10:13 AM' timestamp='1340759597' post='1426986']
I stand corrected ..
After getting it to run once, you can exit all-mighty shell and run as mere mortals..
[/quote]


i think my question was silly
so i tried to run from terminal but i didnt setup the script file as it is required while u dont use the GPU for monitor
read this carefully [url="http://developer.download.nvidia.com/compute/DevZone/docs/html/C/doc/CUDA_Getting_Started_Linux.pdf"][url="http://developer.download.nvidia.com/compute/DevZone/docs/html/C/doc/CUDA_Getting_Started_Linux.pdf"]http://developer.download.nvidia.com/compute/DevZone/docs/html/C/doc/CUDA_Getting_Started_Linux.pdf[/url][/url], there is a quide that u have to put a script file

[quote name='cudaha' date='27 June 2012 - 10:13 AM' timestamp='1340759597' post='1426986']

I stand corrected ..

After getting it to run once, you can exit all-mighty shell and run as mere mortals..







i think my question was silly

so i tried to run from terminal but i didnt setup the script file as it is required while u dont use the GPU for monitor

read this carefully http://developer.download.nvidia.com/compute/DevZone/docs/html/C/doc/CUDA_Getting_Started_Linux.pdf, there is a quide that u have to put a script file


#7
Posted 06/28/2012 06:23 AM   
I have installed CUDA on Ubuntu 12.04 LTS, and got same problem and SOLVED. The problem is the CUDA environment is not defined in either user or root environment. So, we then insert the following script into ~/.bashrc of user [i]export CUDA_HOME=/usr/local/cuda-6.0 export LD_LIBRARY_PATH=${CUDA_HOME}/lib64 PATH=${CUDA_HOME}/bin:${PATH} export PATH[/i] And then change to root: $sudo su Insert the above script into .bashrc of root. Then restart, and run ./devicequerry It will work well.
I have installed CUDA on Ubuntu 12.04 LTS, and got same problem and SOLVED.

The problem is the CUDA environment is not defined in either user or root environment.

So, we then insert the following script into ~/.bashrc of user

export CUDA_HOME=/usr/local/cuda-6.0
export LD_LIBRARY_PATH=${CUDA_HOME}/lib64

PATH=${CUDA_HOME}/bin:${PATH}
export PATH


And then change to root: $sudo su
Insert the above script into .bashrc of root.

Then restart, and run ./devicequerry
It will work well.

#8
Posted 07/01/2014 03:19 AM   
Scroll To Top