Hi.
I’ve had some trouble getting cuda 1.1 beta to run on Fedora 8, and I thought I could share my experiences here.
I’ve been able to successfully run bitonic sample, and that seems like a big victory to me. Yes, I’m a bit novice when it comes to linux.
I’ve performed these steps over several days (little precious free time, for this, you know), so I may have forgotten something. The bits I tell are those “holy s**t” moments that stick in memory when you finally understand what the hell is going wrong.
Steps:
a) Get a linux distribution that seems very similar to one of the cuda-supported distributions and that will install on my machine out of the box. Apparently, some linux distributions are fooled by my brand-new hw (RAID 0 bios seems to be to blame). Since cuda 1.1 supports fedora 7 (which won’t install on my machine out of the box) and fedora 8 does install on my machine, fedora 8 is the winner here. And no, I won’t change to this or that distribution or do some complicated installing gym, thank you, not now I’ve been able to run SOME cuda code.
Make sure you install kernel source, It’ll be needed later.
b) Get and install appropiate driver as advised on the downloads page for cuda 1.1 beta. For my machine, I had to change to the directory where kernel source is installed and do “make menuconfig”, or whatever option is required to configure your kernel source with a menu. I just got into the menu and left normally. On my machine, this was required for a kernel module compilation to proceed further.
Of course, in order to install the driver you must NOT be running an X server, something Fedora 8 insists on making difficult. In order to not run it, I had to follow instructions found at
[url=“Get command line login running RedHat 9 or Fedora core 3 Linux”]http://www.perpetualpc.net/command_line_login.html[/url]
c) Install toolkit and SDK. NVIDIA provides instructions on this.
d) Set PATH, LD_LIBRARY_PATH. Do so by editing .bash_profile on your home folder. Mine looks like this:
.bash_profile
Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi
User specific environment and startup programs
PATH=$PATH:$HOME/bin:/usr/local/cuda/bin
export PATH
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib
export LD_LIBRARY_PATH
e) Compile the examples, doing make on the sdk’s root folder.
f) Try to run one of the samples (ie, bitonic) from the command line, and get some error message about libcudart. Do some ldd gym in order to test wether bitonic is finding all shared libraries. Yes, it can find everything. Do the same with libcudart.so. Again, all is there. Be puzzled, understand nothing, run startx to get into the web. Notice a report from SELINUX saying that there’s been some kind of problem. Open it, and realize that SELINUX is preventing libcudart.so from loading because it’s doing something that is potentially dangerous. It even provides details of what to do in order to allow libcudart to load - run this as root:
chcon -t textrel_shlib_t /usr/local/cuda/lib/libcudart.so.1.1
If anyone from NVIDIA is interested in fixing these problems, they will probably request details on what SELinux has to say about their libcudart.so. I wish I knew how to access these details, but my knowledge on selinux is very close to 0. In any the description of the problems is in Spanish (as is my system), so a translation would probably be in order,
I will try to access this info, and provide more details in a later post.
well, good night.
Saludos,
apano