Running Folding@home on Amazon EC2 instances

Folding@home is a long running project focused on disease research using distributed computing, and they recently launched a number of projects related to COVID-19.

This blog post will show you how to use Amazon EC2 GPU instances with Folding@home. This is a great way to help researchers, so please consider donating some GPU time.

Initial setup

First, I fire up an Amazon EC2 P3 instance, which hosts an NVIDIA V100 GPU. I use the NVIDIA Deep Learning AMI 19.11.3 in order to make sure that I have the latest NVIDIA drivers. This should also work on other AMIs, but your mileage may vary.

Spot instances would be a great choice here!

Then, I simply follow these instructions to manually install the Folding@home client. Here are my exact steps:

wget https://download.foldingathome.org/releases/public/release/fahclient/debian-testing-64bit/v7.4/fahclient_7.4.4_amd64.deb
wget https://download.foldingathome.org/releases/public/release/fahcontrol/debian-testing-64bit/v7.4/fahcontrol_7.4.4-1_all.deb
sudo dpkg -i --force-depends fahclient_7.4.4_amd64.deb
sudo dpkg -i --force-depends fahcontrol_7.4.4-1_all.deb

Once I’ve completed the wizard setup, the client starts automatically. ‘htop’ confirms that the ‘a7’ Folding@Home core is crunching data.

Illustration for Enabling GPU training

By default, training is only running on the CPU. Let’s put that GPU to work!

Enabling GPU training

I need to edit /etc/fahclient/config.xml (sudo required):

<config>
<! — Client Control →
<fold-anon v=’true’/>
<! — Folding Slot Configuration →
<gpu v=’true’/>
<! — Slot Control →
<power v=’full’/>
<! — User Information →
<user v=’JulienS’/>
<! — Folding Slots →
<slot id=’0' type=’CPU’/>
<slot id=’1' type=’GPU’/>
</config>

Then, I just stop and start the client:

sudo /etc/init.d/FAHClient stop
sudo /etc/init.d/FAHClient start

This fires up a GPU-optimized Folding@home core (core ‘22’).

Step 3 screenshot from Running Folding Home on Amazon Ec2 Instances

Pretty soon, nvidia-smi tells me that the GPU is now crunching as well.

Screenshot from Running Folding Home on Amazon Ec2 Instances tutorial

Take that, COVID-19. Your days are counted.

Again, please consider donating some GPU time if you can. Thank you.


About the Author

Julien Simon is the Chief Evangelist at Arcee AI , specializing in Small Language Models and enterprise AI solutions. Recognized as the #1 AI Evangelist globally by AI Magazine in 2021, he brings over 30 years of technology leadership experience to his role.

With 650+ speaking engagements worldwide and 350+ technical blog posts, Julien is a leading voice in practical AI implementation, cost-effective AI solutions, and the democratization of artificial intelligence. His expertise spans open-source AI, Small Language Models, enterprise AI strategy, and edge computing optimization.

Previously serving as Principal Evangelist at AWS and Chief Evangelist at Hugging Face, Julien has authored books on Amazon SageMaker and contributed to the open-source AI ecosystem. His mission is to make AI accessible, understandable, and controllable for everyone.