I'll start off by saying that I am by no means a linux expert, I just messed around with this all day and after I figured everything out (and made a few of my own tweaks) figured I'd share it with everyone else.
to start off, this guide assumes you have a fresh installation of arch linux x64, and may not work otherwise. I may eventually broaden it to include the x86 variety as well, but at this point I will not.
first, uncomment the multilib repository from your pacman.conf. I will use nano as the editor for it's simplicity, but feel free to use whatever you like.
then uncomment these 2 lines by removing the # in front of them.
after this, do a full system upgrade with
next, install the nvidia drivers and wine with
once these are installed, you will need to install the nvidia cuda toolkit from the arch user repository (aur).
this can be done by first downloading the PKGBUILD file, and using the makepkg command, as shown
this will install the x86 version of the cuda toolkit, since the x64 variety will not work for our purposes.
next, run a program in wine (notepad is usually good) to set up the folder structure where we're going to put the modified dlls needed, then download the files to ~/.wine/drive_c/windows/system32
then, test the progress so far with the following command
if any part of the output says "not found" something is wrong, and you should recheck your linking.
next, we will download and run a script that will initialize every nvidia gpu in the system.
then use the following command to check to see if it worked
the output should have an nvidia<gpu number starting with 0> for every gpu in the system. if not, recheck the previous steps.
if your gpus are properly initialized, you may continue on.
next, we need to download the nvclock utility, which handles overclocking (and who doesn't love overclocking?) and more importantly, fan control for our cards, since the fans don't change speeds in console mode.
then use the command
to set the fan to automatic control based on the card's bios.
finally, we can download the folding client.
then install unzip (to be able to open zip files) and extract the client. copy the nvcuda.dll file you downloaded earlier into the directory with the client after it is unzipped.
please note the folder name gpu0 is important here, as I will upload a modified initialization script that will also start a client for each gpu it initializes.
next, I find it easier to run the first client with the configonly flag set to generate a config file, and then copy it to every additional client.
configure your client as normal. after finishing, use the cd command to return to the previous directory, and then make as many copies of your client as needed. I have 3 folding cards, so I made 2 additional copies.
then, edit the client.cfg file in each directory to have a different machine id using your preferred text editor.
I did not edit the first, since it did not need changing.
now, test your clients to see if they will run without error using the following commands (substitute your flags as necessary)
note, this will be just like starting a windows client in a command prompt menu, and you will not be able to enter any additional commands. to avoid this, append a & to the end of the command like so. the output will still be returned to that terminal though, so you may also want to redirect the output to null after you are sure it's working.
as promised above, you can also download a modified initialization script that will automatically start a client for every gpu initialized as long as there is a folder for each client (set up for gpu2 only with the -forcegpu nvidia_g80 flag set)
to get and run it, use the following commands
If followed properly, everything above should allow you to take a system running a clean installation of Arch Linux x64 and download and run a gpu folding client for every one of your nvidia gpus. If it doesn't, I want to know so that I can work to improve this guide so that it works for everyone.
I must give credit to the other's whose work I used, so here it is:
http://foldingforum.org/viewtopic.php?f=54&t=6793 for all the headless features
and I can't seem to find the other guide I used that was based on gpu2 and ubuntu (no it wasn't zodac's) but I will add it when I find it again.
to start off, this guide assumes you have a fresh installation of arch linux x64, and may not work otherwise. I may eventually broaden it to include the x86 variety as well, but at this point I will not.
first, uncomment the multilib repository from your pacman.conf. I will use nano as the editor for it's simplicity, but feel free to use whatever you like.
Code:
nano /etc/pacman.conf
Code:
[multilib]
Include = /etc/pacman.d/mirrorlist
Code:
pacman -Syu
Code:
pacman -S wine nvidia
this can be done by first downloading the PKGBUILD file, and using the makepkg command, as shown
Code:
wget aur.archlinux.org/packages/lib32-cuda-toolkit/lib32-cuda-toolkit.tar.gz
tar -xzf lib32-cuda-toolkit.tar.gz
cd lib32-cuda-toolkit
makepkg -s --asroot
pacman -U lib32-cuda-toolkit-3.0-1-x86_64.pkg.tar.xz
next, run a program in wine (notepad is usually good) to set up the folder structure where we're going to put the modified dlls needed, then download the files to ~/.wine/drive_c/windows/system32
Code:
wine notepad
wget http://www.linuxfah.info/wrapper-3.0/cudart/cudart.dll.so
wget http://www.linuxfah.info/wrapper-3.0/cufft.dll.so
cp cudart.dll.so ~/.wine/drive_c/windows/system32/cudart.dll
cp cufft.dll.so ~/.wine/drive_c/windows/system32/cufft.dll
cd ~/.wine/drive_c/windows/system32
ln -s cudart.dll nvcuda.dll
ln -s cudart.dll cudart32_20_14.dll
ln -s cufft.dll cufft32_20_14.dll
Code:
ldd cudart.dll
next, we will download and run a script that will initialize every nvidia gpu in the system.
Code:
cd
wget http://www.overclock.net/attachment.php?attachmentid=181391&stc=1&d=1290295988
mv initgpu.txt initgpu
chmod u+x initgpu
./initgpu
Code:
ls /dev/nv*
if your gpus are properly initialized, you may continue on.
next, we need to download the nvclock utility, which handles overclocking (and who doesn't love overclocking?) and more importantly, fan control for our cards, since the fans don't change speeds in console mode.
Code:
pacman -S nvclock
Code:
nvclock -f -C <card number 1-?> -F auto
finally, we can download the folding client.
Code:
wget http://www.stanford.edu/group/pandegroup/folding/release/Folding@home-Win32-GPU_Vista-623.zip
Code:
pacman -S unzip
mkdir gpu0
unzip Folding@home-Win32-GPU_vista-623.zip -d gpu0
cp nvcuda.dll.so gpu0/nvcuda.dll
next, I find it easier to run the first client with the configonly flag set to generate a config file, and then copy it to every additional client.
Code:
cd gpu0 # the cd command is important here
nice -n 19 wine Folding\\@home-Win32-GPU.exe -configonly
Code:
cd
cp -r gpu0 gpu1
cp -r gpu0 gpu2
Code:
nano gpu1/client.cfg
nano gpu2/client.cfg
now, test your clients to see if they will run without error using the following commands (substitute your flags as necessary)
Code:
cd gpu0
nice -n 19 wine Folding\\@home-Win32-GPU.exe -gpu 0 -forcegpu nvidia_g80
Code:
nice -n 19 wine Folding\\@home-Win32-GPU.exe -gpu 0 -forcegpu nvidia_g80 & #starts in background
cd ..
cd gpu1
nice -n 19 wine Folding\\@home-Win32-GPU.exe -gpu 0 -forcegpu nvidia_g80 >/dev/null & #starts in background and discards normal output
cd ..
cd gpu2
nice -n 19 wine Folding\\@home-Win32-GPU.exe -gpu 0 -forcegpu nvidia_g80 >/dev/null 2>&1 & #starts in background and discards all output
cd ..
to get and run it, use the following commands
Code:
cd
wget http://www.overclock.net/attachment.php?attachmentid=181397&stc=1&d=1290298396
mv initandfold.txt initandfold
chmod u+x initandfold
./initandfold
If followed properly, everything above should allow you to take a system running a clean installation of Arch Linux x64 and download and run a gpu folding client for every one of your nvidia gpus. If it doesn't, I want to know so that I can work to improve this guide so that it works for everyone.
I must give credit to the other's whose work I used, so here it is:
http://foldingforum.org/viewtopic.php?f=54&t=6793 for all the headless features
and I can't seem to find the other guide I used that was based on gpu2 and ubuntu (no it wasn't zodac's) but I will add it when I find it again.








