cuda7 install fail on ubuntu: modprobe: ERROR

Hi All,
I have a freshly installed Ubuntu 14.04LTS system, with a GTX460, on an AMD Athlon 64. When I run deviceQuery I get the following:

modprobe: ERROR: could not insert ‘nvidia_331_uvm’: Invalid argument
cudaGetDeviceCount returned 30

I went through all the pre-install and post-install steps, including disabling nouveau. I set my PATH and LD_LIBRARY_PATH. My system recognizes the 460. I’ve tried installing the CTK with both the deb and run methods, with the same result. I’ve run with the driver included in the CTK download and the most recent driver, with the same result. Some web-page suggested I ‘sudo deviceQuery’ to set some permissions correctly, but that didn’t help (the permissions were rw/rw/rw for those files). I’m considering trying Cuda6, but that’s just guessing at the expense of another hour of messing around.

Any ideas, anyone? Is Ubuntu14/Cuda7/GTX460 a rational system, or is there some incompatibility?

BTW, the samples all compile with the supplied makefile. But my helloWorld program, when compiled with nvcc, gives the following error, suggesting to me it’s not workig right:

helloWorld.cpp:5:1: error: ‘global’ does not name a type
helloWorld.cpp: error: ‘kernel’ was not declared in this scope

The lines in question were:

5: global void kernel( void ) {}
9: kernel<<<1,1>>>();

If I comment out these lines, the compile completes and I get my “hello World!”

Thanks in advance for your advice! /kletus

It’s rational, unfortunately your system has a mixed driver install environment. The 331 stuff is leftover junk from something and it needs to be cleaned out.

Take a look at this section of the getting started guide:

http://docs.nvidia.com/cuda/cuda-getting-started-guide-for-linux/index.html#handle-uninstallation

Remove all previous installations, using the instructions there.

Then reinstall the CUDA 7 toolkit using the .run file installer/method.

And regarding your compile error, don’t put CUDA codes in .cpp files. If you’re starting out as a beginner, they belong in .cu files (like all the samples that compile correctly…)

It worked, thanks! By the time I did a few install/uninstall experiments, my system was pretty much munged up. So I re-installed ubuntu, re-installed the CDK, and amazingly it worked on the first try!