Linux Installation Instructions for the SMP client

Table of contents

Requirements

Before you install the Linux SMP client, here is some requirements to check :

  • You must be running a 64 bit Linux OS. The client is not supported on 32 bit (this is due to the MPI layer SMP is using for inter-core communications).
  • Even though the core requires a 64 bit OS, the client needs the 32 bit library so you will have to install it.

Note: With some distributions, you may need to add su or sudo to execute the command if you are not logged as root.

Debian-based distributions :

 apt-get install ia32-libs

Redhat-based distributions :

 yum install compat-libstdc++

Installation of the SMP client

Here are the basic command-line instructions to install and run the v6.xx Folding@home (FAH) client.

Open the Terminal application. Depending of your desktop engine (KDE, GNOME, etc.) the Terminal application may be found in a variety of locations.

Ubuntu GNOME: Applications / Accessories / Terminal
Fedora GNOME: Applications / System Tools / Terminal
Kubuntu KDE: K-menu / System / Konsole
Fedora KDE: Applications / System / Konsole

The Terminal window contains a prompt with the user name, and the computer name. In this guide, the prompt will be represented as:

user@box:~$

Install the cURL application, which is a command line tool for getting or sending files using web links.

Note: Depending on the linux distro, cURL may already be installed. Installing cURL again will not hurt anything. Use the command appropriate for your linux type.

Ubuntu:

 sudo apt-get install curl

Fedora:

 su -c 'yum install curl' 

When prompted for your password, type it in and press enter.

To download the FAH client for 64 bit versions of linux, a requirement for SMP, type in (or copy/paste) the following commands. Enter one line at a time, in to the terminal command line, and press enter:

 mkdir -p ~/folding
 cd ~/folding
 curl -O http://www.stanford.edu/group/pandegroup/folding/release/FAH6.34-Linux64.tgz
 tar xzf FAH6.34-Linux64.tgz

After the FAH client is downloaded, the client needs to be configured. Please run these 2 commands:

 chmod +x fah6
 ./fah6 -configonly -smp 

After the client is configured, there are different methods for starting the FAH client. The most basic method is to enter in following command:

 ./fah6 -smp -verbosity 9

OPTIONAL: To make starting FAH a little easier, make a script by running the following commands:

 echo "./fah6 -smp -verbosity 9 $* &" > fah
 chmod +x fah

Now simply enter this command to run FAH...

 ./fah

...and all those additional FAH client flags will get added automatically.

Note: All of these listed commands can be typed or copied/pasted from this install GUIDE to the terminal (window) of your machine. Only enter the command text to the right of the command prompt (right of the $). Do not enter or copy the text user@box:~$

Example:

 user@box:~$ mkdir -p ~/folding
 user@box:~$ cd ~/folding
 user@box /folding:~$ curl -O http://www.stanford.edu/group/pandegroup/folding/release/FAH6.34-Linux64.tgz

 user@box /folding:~$ tar xzf FAH6.34-Linux64.tgz
 user@box /folding:~$ chmod +x fah6
 user@box /folding:~$ ./fah6 -configonly -smp
 ...

That's it. 6 commands, answering the FAH client setup questions, and the folding client is installed and running.

How to start the linux SMP client as a service

Note: Adding the client as a service in Linux depends on which distribution you are using. The instructions below should work for the majority of distributions available in the market. You might need to do some research to find out what your distribution needs to install as a service. Also, the fah client must not be running when adding the service option. Stop the client first if needed.

Do not change accounts or change directory location. Create a script named folding by pasting the following commands:

Debian-based distributions:

 echo "# chkconfig: 345 93 14" > ./folding
 echo "# description: will start FAH client as a service" >> ./folding
 echo "sudo - $USER -c \"cd $PWD; ./fah6 -smp -verbosity 9 < /dev/null > 
  /dev/null 2>&1 &\"" >> ./folding
 chmod +x ./folding

For other distributions run:

 echo "# chkconfig: 345 93 14" > ./folding
 echo "# description: will start FAH client as a service" >> ./folding
 echo "su - $USER -c \"cd $PWD; ./fah6 -smp -verbosity 9 < /dev/null > 
  /dev/null 2>&1 &\"" >> ./folding
 chmod +x ./folding

Note: In the following steps, replace [fahdir] with the value you saw on screen during the previous installation steps (don't include the brackets). Typically, that [fahdir] value is /home/username

To mark down where you installed the FAH client just run:

 echo "[fahdir] = $PWD"

Note: All the following steps need root privileges to be carried out successfully.

For Debian-based distributions run:

 sudo cp [fahdir]/folding /etc/init.d/

For other distributions run:

 su - -c "cp [fahdir]/folding /etc/init.d/"

Note: If you installed the client under root user account, do this instead :

 echo "# chkconfig: 345 93 14" > ./folding
 echo "# description: will start FAH client as a service" >> ./folding
 echo "cd $PWD; ./fah6 -smp -verbosity 9 < /dev/null > /dev/null 2>&1 &" >>
  /etc/init.d/folding
 chmod +x /etc/init.d/folding

Last step is to register the folding service.

For Debian-based distributions run:

 sudo update-rc.d folding defaults

For other distributions run:

 su - -c "chkconfig --add folding"

That's all so reboot the computer to make the new script start the client. To check if it is working fine, just go to your folding folder and open fahlog.txt or run:

 tail -f [fahdir]/FAHlog.txt


Install Guide Updates

I found a better way to install the Linux client, where can I make a suggestion?

The install guides are written and updated by the folding community, and managed by the Pande Group. Please post any suggestions, corrections, or update recommendations to the corresponding Guides topic in the Folding Forum. And thank you for helping to improve the install guides.


For More Information, Please See:


Last Updated on April 19, 2009, at 01:27 PM