LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 12-06-2018, 04:24 AM   #1
trite
Member
 
Registered: Feb 2016
Location: Sweden
Distribution: Slackware64-current
Posts: 81

Rep: Reputation: 54
Cuda 10?


Hello!
The cudatoolkit in slackbuilds is very old. I need Cuda 10 to be able to play around with python and tensorflow.

Anyone out there managed to install _any_ Cuda version above version 8 and have any directions for me?
 
Old 12-06-2018, 06:56 AM   #2
aragorn2101
Member
 
Registered: Dec 2012
Location: Mauritius
Distribution: Slackware
Posts: 552

Rep: Reputation: 272Reputation: 272Reputation: 272
Hi,

First you'll need to get the appropriate version of the nvidia driver which will work with CUDA 10. Check out the release notes to get info on this: https://docs.nvidia.com/cuda/cuda-to...tes/index.html.

Then, there are two ways to proceed. You can either tweak the SlackBuilds script to install the CUDA 10 and be on the safe side as it will all be packaged, so it will be easy to remove if somethings goes wrong.

Or, you can install it manually by running the CUDA "runfile" script.

When you are sure your nvidia module has been loaded at boot, you download and run the script from https://developer.nvidia.com/cuda-downloads (the runfile from Fedora usually works) and run it as root:
Code:
# bash cuda_10..._linux-run
The script is interactive and it will ask you about configuration parameters and where to install what. You just have to plan the install paths well so that you keep track of where everything is.

One possible glitch with running such a new CUDA version is with gcc. In the past, I once encountered a problem in Slackware 14.1 when my native Slackware gcc was a version behind the CUDA gcc. I don't remember which versions exactly, but sometimes these things happen because the CUDA compiler is not built from source when you install. If you encounter this problem you might need to upgrade Slackware's gcc.
 
1 members found this post helpful.
Old 08-06-2019, 04:14 AM   #3
aragorn2101
Member
 
Registered: Dec 2012
Location: Mauritius
Distribution: Slackware
Posts: 552

Rep: Reputation: 272Reputation: 272Reputation: 272
Hi again,

I know this thread is relatively old, but I think I have something relevant to add.

I recently upgraded my computer at the university and I got myself a GTX Titan Xp. So, I decided to upgrade from CUDA 8 to CUDA 10. Turns out that much have changed.

So, like it was said before, the SlackBuilds for the cudatoolkit is old, I was not able to just change the version and expect that everything else would work fine. Therefore, I wrote my own SlackBuilds script for CUDA 10. You can check it out at https://github.com/aragorn2101/Slack...er/cudatoolkit.

As I mention in the README, it is not official SlackBuilds and I didn't test with the nvidia-driver and nvidia-kernel available from SlackBuilds.org. Instead I worked with driver and kernel version 430.34 and it worked well. I guess version 430.14 (from SlackBuilds.org at time of writing) will work as well.

I am not going to postulate to replace the cudatoolkit 8 on SlackBuilds as, in a near future, I might not be at the university anymore and I am not sure I will still have a CUDA capable GPU at hand to test.

So, I make this available for all those out there wanting to use CUDA in Slackware. Feel free to adapt depending on your needs or if Nvidia changes stuff again.

I hope this helps.
Cheers.

Last edited by aragorn2101; 08-06-2019 at 04:16 AM.
 
4 members found this post helpful.
Old 08-06-2019, 10:31 PM   #4
3rensho
Member
 
Registered: Mar 2008
Location: Switzerland
Distribution: Slackware64-current
Posts: 441

Rep: Reputation: 111Reputation: 111
Thank you for sharing aragorn2101.
 
Old 07-11-2020, 04:15 PM   #5
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
I need to get latest CUDA library and toolkit working on a modern slackware64-current. Unfortunately aragorn2101's Slackbuild script is dated at least for my AMD box with nvidia GPU GP108 [GeForce GT 1030] (rev a1).

I can't seem to find a recent build. Any suggestions?
 
Old 07-11-2020, 04:38 PM   #6
MDKDIO
Member
 
Registered: Mar 2004
Location: Sweden
Distribution: Slackware 14.2 & Current
Posts: 120

Rep: Reputation: 17
Have you tried Ponce slackbuild for current?

https://github.com/Ponce/slackbuilds...nt/cudatoolkit

I have not tried this my self as I don't have Nvidia
 
Old 07-12-2020, 08:54 AM   #7
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
Ponce? I take it that's either gperon or willsr on GIT?

After having spent several hours trying to get the 'old' builds working yesterday I suppose I will give this a try. It's a 2GB package and 'only' takes up 3GB of disk space...Yikes!

It will probably take longer than a few kernels to build

Someone should make a torrent for downloading!

Thanks MDKDIO. Stay tuned....
 
Old 07-12-2020, 09:32 AM   #8
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
Ok this doesn't look promising..right out of the gate I can't run the Slackbuild script as it html based it won't run in a shell as most normal Slackbuilds do:
./cudatoolkit.SlackBuild: line 6: syntax error near unexpected token `newline'
./cudatoolkit.SlackBuild: line 6: `<!DOCTYPE html>'
 
Old 07-12-2020, 09:35 AM   #9
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
Oops...disregard. That's because I tried to use Chrome's "Save link as" to download all of the source. That doesn't work on GIT apparently!
 
Old 07-12-2020, 11:38 AM   #10
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
git clone isn't working for this URL. Is there an official URL for git clone? I'll email support@github.com in case I don't hear back from anyone here first.
Cloning into 'cudatoolkit'...
fatal: remote error:
Ponce/slackbuilds/tree/current/development/cudatoolkit is not a valid repository name
Email support@github.com for help
 
Old 07-12-2020, 12:31 PM   #11
bifferos
Member
 
Registered: Jul 2009
Posts: 367

Rep: Reputation: 136Reputation: 136
You could just use afterpkg:

Code:
$ wget https://github.com/bifferos/afterpkg/archive/master.zip
$ unzip master.zip
$ cd afterpkg-master
$ ./afterpkg cudatoolkit
It will download the ponce master as zip and then build the dependencies for you if you don't have them.
 
Old 07-12-2020, 12:58 PM   #12
MDKDIO
Member
 
Registered: Mar 2004
Location: Sweden
Distribution: Slackware 14.2 & Current
Posts: 120

Rep: Reputation: 17
Am slow typing here....

Never mind this post...

Last edited by MDKDIO; 07-12-2020 at 12:59 PM.
 
Old 07-12-2020, 05:45 PM   #13
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 7,240

Rep: Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932Reputation: 4932
Quote:
Originally Posted by wirelessmc View Post
git clone isn't working for this URL. Is there an official URL for git clone? I'll email support@github.com in case I don't hear back from anyone here first.
Cloning into 'cudatoolkit'...
fatal: remote error:
Ponce/slackbuilds/tree/current/development/cudatoolkit is not a valid repository name
Email support@github.com for help
Git is designed to download the whole repo, not just that folder.

Code:
git clone https://github.com/Ponce/slackbuilds
There are ways to download individual folders, including using svn if you're connecting to github.
 
Old 07-12-2020, 06:33 PM   #14
wirelessmc
Member
 
Registered: Aug 2008
Posts: 61

Rep: Reputation: 10
Yes thanks bassmadrigal and MDKDIO. Admittedly like many other code things I am a newbie to GitHub.

Running the below command get's Ponce's entire repository which includes cudnn (the library) which I will most definitely need.

git clone https://github.com/Ponce/slackbuilds.git (not sure if the .git extension is required or not)

The update is: Once I downloaded the correct revision of Nvidia's .run script into the cudatoolkit directory ( i.e. cuda_10.2.89_440.33.01_linux.run ) I was able to build the toolkit with Ponce's Slackbuild script. It only took a couple hours!
That version of the Nvidia's run script is a whopping 2.5GB and not the latest which is 11.something.

Now on to building cudnn.

In case anyone is interested I am building these packages so I can (hopefully) run the cuda version of KataGo (8-dan on IGS). I currently have the OpenCL version running on a Windows machine.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Start a QT+CUDA+C/C++ Project? eddiep Linux - Software 4 02-18-2010 02:10 PM
Ubuntu Nvidia / CUDA driver installation gourox Linux - Hardware 1 08-14-2009 12:36 AM
LXer: Security distribution BackTrack 4 with CUDA support LXer Syndicated Linux News 0 06-22-2009 01:00 PM
CUDA on Jaunty, Installation successful, but cannot run? beaute Ubuntu 0 06-01-2009 04:42 AM
Anyone tried nvidia CUDA toolkit sniff Programming 0 02-28-2007 05:40 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 08:33 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration