Everyman's Guide to Nvidia GPU Folding on Ubuntu Server
Posted: Sat Mar 28, 2015 10:41 pm
Preface
I am writing this in hope of saving someone else the time and trouble that I have gone through to get my system folding on Linux.
This guide assumes the following:
That you want to install Linux for FAH and not much else.
That you have read this guide and the links therein before you started.
That you already know how the GNU/Linux file system is structured.
That you are familiar with Bash and the basic command line tools.
That you have some knowledge of Ubuntu and Debian package management tools.
That you can install the latest LTS version of Ubuntu Server on your own.
That you know your hardware.
It is also assumed that you don't mind reading a few biased statements from myself about Linux and Ubuntu. If you don't feel comfortable or are worried about any part of this guide I highly recommend that you just don't follow it. In any case it is always a good idea to have a second PC close by that you can use to use to access the internet and look for help, Wiki's, HowTo's, and forums if you get stuck. The only thing I would recommend you download and have ready on removable media is the install file for Nvidia's drivers (http://www.nvidia.com/object/unix.html).
Installing the OS: Keeping It Simple.
The only packages I chose to install with the base server were those needed for OpenSSH, and that was just because I wanted a way to access the system over my network on the off chance I lost the display or keyboard. In My Not So Humble Opinion: One of biggest hurdles FAH users must overcome to fold in Linux is the complexity of Desktop distros. The fewer packages you start with the easier it is control the whole system.
Once you have the completed your install and rebooted the first thing to do is edit the blacklist file for the kernel modules in order to stop the FOSS Nvidia drivers from loading:
Add this line (I put it right at the top, but anywhere should do):
Save and exit, then reboot.
Installing what we need and what we need in order to test what we installed.
When you have logged back in, install the build-essential package in order to get the tools needed to install Nvidia's drivers:
Next (re?)read about and add the xorg-edgers ppa:
Now install Xorg and a light weight desktop:
Now insert and mount your removable media with Nvidia's drivers:
i.e. For cdrom it would be something like
or for a USB drive something like
Next, install Nvidia's drivers with a command something like this:
Once it is finished:
A few words about Enlightenment and OpenGL.
Enlightenment (e17) is a very light weight GUI that won't get in your way too much. However, if you tell it to it will use OpenGL and compositing effects. That in turn will lead to lower GPU performance for FAH. So during these next steps, I turned that stuff off.
Testing what we have installed so far.
First make sure the nvidia modules are loaded:
If you see both Nvidia modules then skip the next step. If not then do this:
Next we start the Xorg server:
After a few questions about where you are, what language you speak, and how much GPU power you want to waste on OpenGL, you should be looking at a desktop! If not, reboot. This will force the system to load all the new stuff we installed. If that doesn't work, something has gone wrong that is outside of the scope of this Guide. Please post all questions to the appropriate forums/mailing lists. IMPORTANT NOTE: Following this guide gives you a system that will not start the GUI automatically at boot time. It must be started manually with the "startx" command. The GUI does NOT need to be running to fold. We just install it in order to make sure the Nvidia drivers are working as expected and so you can have access to FAHControl and a graphical web browser if needed.
Next, install your favorite web browser. Something like:
And once it's installed go here and follow the instructions for a manual install:
On my system this was enough to start CPU folding, but the GPUs.txt didn't get downloaded/installed. If that happens to you as well then you can simply manually download it from the link in this thread:
Then do this:
And then manually add your GPU slot(s) in FAHControl.
That's it, you're done! Go outside and play while your computer does all the hard work!
Yours,
E
P.S. If you happen to find an error or a spelling mistake or just have something to add please let me know so I can take care of it. In the mean time I will continue to edit this post with after thoughts and what not.
I am writing this in hope of saving someone else the time and trouble that I have gone through to get my system folding on Linux.
This guide assumes the following:
That you want to install Linux for FAH and not much else.
That you have read this guide and the links therein before you started.
That you already know how the GNU/Linux file system is structured.
That you are familiar with Bash and the basic command line tools.
That you have some knowledge of Ubuntu and Debian package management tools.
That you can install the latest LTS version of Ubuntu Server on your own.
That you know your hardware.
It is also assumed that you don't mind reading a few biased statements from myself about Linux and Ubuntu. If you don't feel comfortable or are worried about any part of this guide I highly recommend that you just don't follow it. In any case it is always a good idea to have a second PC close by that you can use to use to access the internet and look for help, Wiki's, HowTo's, and forums if you get stuck. The only thing I would recommend you download and have ready on removable media is the install file for Nvidia's drivers (http://www.nvidia.com/object/unix.html).
Installing the OS: Keeping It Simple.
The only packages I chose to install with the base server were those needed for OpenSSH, and that was just because I wanted a way to access the system over my network on the off chance I lost the display or keyboard. In My Not So Humble Opinion: One of biggest hurdles FAH users must overcome to fold in Linux is the complexity of Desktop distros. The fewer packages you start with the easier it is control the whole system.
Once you have the completed your install and rebooted the first thing to do is edit the blacklist file for the kernel modules in order to stop the FOSS Nvidia drivers from loading:
Code: Select all
sudo nano /etc/modprobe.d/blacklist.conf
Code: Select all
blacklist nouveau
Installing what we need and what we need in order to test what we installed.
When you have logged back in, install the build-essential package in order to get the tools needed to install Nvidia's drivers:
Code: Select all
sudo apt-get install build-essential
Code: Select all
Instructions and warnings can be found here:
https://launchpad.net/~xorg-edgers/+archive/ubuntu/ppa
Code: Select all
sudo apt-get update
sudo apt-get install xorg e17
Code: Select all
sudo mount /path/to/device /path/to/mount/point
Code: Select all
sudo mount /dev/sr0 /mnt
Code: Select all
sudo mount /dev/sdb1 /mnt
Code: Select all
cd /mnt
sudo sh ./NVIDIA-Linux-x86_64-<Your.Version.Number.Here>.run
Code: Select all
cd
sudo umount /mnt
Enlightenment (e17) is a very light weight GUI that won't get in your way too much. However, if you tell it to it will use OpenGL and compositing effects. That in turn will lead to lower GPU performance for FAH. So during these next steps, I turned that stuff off.
Testing what we have installed so far.
First make sure the nvidia modules are loaded:
Code: Select all
sudo lsmod | grep nvidia
Code: Select all
sudo modprobe nvidia-uvm
sudo modprobe nvidia
Code: Select all
startx
Next, install your favorite web browser. Something like:
Code: Select all
sudo apt-get install firefox
Code: Select all
http://folding.stanford.edu/home/guide/linux-install-guide/
Code: Select all
https://foldingforum.org/viewtopic.php?f=83&t=26208
Code: Select all
sudo service FAHClient stop
sudo cp /home/yourusername/Downloads/GPUs.txt /var/lib/fahclient/
sudo service FAHClient start
That's it, you're done! Go outside and play while your computer does all the hard work!
Yours,
E
P.S. If you happen to find an error or a spelling mistake or just have something to add please let me know so I can take care of it. In the mean time I will continue to edit this post with after thoughts and what not.