Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I am trying to get CUDALink working on my laptop. I am running Crunchbang "waldorf" which is based on Debian 7 "wheezy". I am a linux novice. The issue is that Mathematica can "see" the nVidia drivers, but yet I am not able to get CUDALink to work. I have searched, and read over the article CUDALink not working on Linux-64 and Asus GTX460 which is close to my issue but doesn't seem to cover it, and where it does shed some light I don't appear to have any of the directories mentioned. I have engaged the Crunchbang linux forums to no avail..

I would really like to get CUDALink working.. I have tried information such as on this website http://www2.warwick.ac.uk/fac/sci/statistics/staff/academic-research/graham/cuda5-debian-wheezy/ but it ruined my video driver setup and I was forced to go through the smxi script again and re-install to get the GUI back.

At the moment I am re-downloading the cuda_5.5.22_linux_64.run file from nVidia. I have tried installing the nVidia CUDA binaries from the debian package manager but it ruins my system every time, forcing me to use the smxi script to repair.

Otherwise, Mathematica 9 is running wonderfully.

If someone can please illustrate the process of setting up CUDA/CUDALink I would greatly appreciate it. Cheers! Will

EDIT: I have installed CUDA 5.5 from the above package and have run deviceQuery, with positive results. It detects the card and all fields are nominal, referencing the nVidia website for the 3100m.

EDIT 2: It was discovered from https://wiki.archlinux.org/index.php/Mathematica that the x64 version of Mathematica is "hard wired" to look for drivers in the /usr/lib64 and not in /usr/lib where things are installed in an x64 native system. Since making a symbolic link using "ln -s /usr/lib /usr/lib64" Mathematica's CUDALink appears to be working now. This question is now closed, but hopefully this can act as community support for others.

EDIT 3: As is mentioned in my answer, there is now an issue with CUDALink not running certain functions. It is the same symptoms as this question: CUDALink is not initialized

share|improve this question
    
Could you provide your edit 2 as an official answer? Self-answering is ok here, and it will make clear in search results that the question has been answered. –  Sjoerd C. de Vries Mar 11 at 7:31
    
I will certainly do that. It is still not working 100% at the moment as it shows the graphics driver version but not the CUDA version, but CUDAQ[] is answering TRUE so it's at least recognized. –  willanth Mar 11 at 8:25
add comment

1 Answer 1

up vote 2 down vote accepted

Mathematica (version 9.0.1.0) looks for /usr/lib64 in it's 64bit linux version. Most installs (Crunchbang "Waldorf" in my case) will not generate this directory and instead create a /usr/lib directory in a native 64 bit system, and a lib32 for "legacy" code. After fooling around with modifying path variables etc, I have found that the fastest and easiest way for Mathematica to find the nVidia and CUDA drivers is to create a symbolic link "ln -s /usr/lib /usr/lib64".

Cuda 5.5 was installed by downloading it from nVidia (cuda_5.5.22_linux_64.run) and following the installation prompts using all defaults. Once this was complete, I followed the CUDALink install instructions from Wolfram. When the CUDALink module was installed, I performed the above symbolic link and restarted Mathematica. It would then return a CUDAQ[] "True" and provide all of the other diagnostic information including populating the system information.

The directory hard-coding appears to be a bug in Mathematica.

That being said, I am now having the same issues as this post: CUDALink is not initialized I am not sure if it is related to the fact that I am using an NVS 3100 or not, but I am still not able to use many of the built-in functions despite the software reporting that it is working.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.