WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud
  • Tanzu
    • Application Modernization
    • Tanzu services
    • Tanzu Community Edition
    • Tanzu Kubernetes Grid
    • vSphere with Tanzu
  • Home Lab
  • Nested Virtualization
  • Apple
You are here: Home / Automation / How to manually install Folding @ Home on VMware Photon OS?

How to manually install Folding @ Home on VMware Photon OS?

03.22.2020 by William Lam // 21 Comments

As many of you may already know, VMware just released the VMware Appliance for Folding @ Home Fling last week and you can check out this blog post A Force for Good: VMware Appliance for Folding @ Home by Amanda Blevins for all the details. For those new to [email protected] and wish to participate, the VMware [email protected] Appliance is highly recommended as it is optimized and makes it very easy to setup and all configurations are driven through OVF properties. We certainly would appreciate it if you supported Team VMware (52737) which is the default team configuration but you can technical specify any valid [email protected] team ID during the deployment wizard.

Early next week, I expect to release another update to the appliance which will include support for vHW11, VMware Fusion and Workstation and several other enhancements and fixes. Having said that, there are a handful of folks who may not be able to use the appliance as-is or prefer to run this on another Hypervisor platform which does not support OVF properties but still wish to support Team VMware's effort with [email protected] For these reasons, here are the instructions for using VMware Photon OS, a free and tiny Linux distribution for running the [email protected] home software.

Disclaimer: VMware does not officially support the Folding At Home application. For more details or questions, please refer to the official [email protected] documentation as well as their technical forums.

Step 1 - Download Photon OS 3.0 Revision 2 Minimal ISO and install that into a new 64-bit Linux VM with 1 or more vCPU, 1GB memory and 4GB storage. For those planning to use a GPU (details for setting up NVIDIA GRID with vGPU can be found in the download instructions here), you will need to configure the VM to have EFI Firmware.

Step 2 - Once Photon OS has been installed, enable root to login via SSH and then run the following commands to update the OS and install the following package dependencies:

tdnf -y update
tdnf -y install wget

Step 3 - Run the following commands to download and install the Folding @ Home packages:

ln -s /usr/lib/libssl.so.1.0.0 /usr/lib/libssl.so.10
ln -s /usr/lib/libcrypto.so.1.0.0 /usr/lib/libcrypto.so.10
wget https://download.foldingathome.org/releases/beta/release/fahclient/centos-6.7-64bit/v7.6/fahclient-7.6.13-1.x86_64.rpm
wget https://download.foldingathome.org/releases/beta/release/fahcontrol/centos-6.7-64bit/v7.6/fahcontrol-7.6.13-1.noarch.rpm
wget https://download.foldingathome.org/releases/beta/release/fahviewer/centos-6.7-64bit/v7.6/fahviewer-7.6.13-1.x86_64.rpm
rpm -i --nodeps fahclient-7.6.13-1.x86_64.rpm
rpm -i --nodeps fahcontrol-7.6.13-1.noarch.rpm
rpm -i --nodeps fahviewer-7.6.13-1.x86_64.rpm
rm -f fahclient-7.6.13-1.x86_64.rpm
rm -f fahcontrol-7.6.13-1.noarch.rpm
rm -f fahviewer-7.6.13-1.x86_64.rpm

Step 4 - Run the following commands to allow port 36330 (remote management of [email protected] Client using FAHControl) and port 7396 (local web management of [email protected] Client using FAH Web Control via http://[FAHCLIENT]:7396) and ensure the configurations are persisted:

iptables -A INPUT -p tcp --dport 36330 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
iptables -A OUTPUT -p tcp --dport 36330 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
iptables -A INPUT -p tcp --dport 7396 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
iptables -A OUTPUT -p tcp --dport 7396 -m conntrack --ctstate NEW,ESTABLISHED -j ACCEPT
iptables-save > /etc/systemd/scripts/ip4save
systemctl restart iptables

Note: You will also need to ensure that either port 80 or 8080 is enabled on the network which is [email protected] Client is connected to and this must be bi-directional as this is how Work Units (WU) are assigned from the [email protected] Service. For those that wish to whitelist the specific source servers, you can refer to the [email protected] documentation found here.

Step 5 - Edit the [email protected] Configuration file at /etc/fahclient/config.xml with your respective configurations. Below is a working example (yes, I included my passkey in case you wish to fold as me ;)). If you have more than 16 vCPU configure, make sure to set client-type with value of "bigadv" (more details can be found here) for larger [email protected] Work Units.

<config>
  <!-- Folding Slot Configuration -->
  <gpu v="false"/>

  <!-- Slot Control -->
  <power v="light"/>

  <!-- User Information -->
  <passkey v="e6cf014f62ba0f60e6cf014f62ba0f60"/>
  <team v="52737"/>
  <user v="lamw"/>

  <!-- Network -->
  <proxy-enable v="false"/>
  <proxy v=""/>
  <proxy-user v=""/>
  <proxy-pass v=""/>

  <!-- Folding Slots -->
  <slot id='0' type='CPU'/>
  <client-type v=""/>

  <!-- Remote Command Server -->
  <command-allow v="127.0.0.1 0.0.0.0/0"/>
  <password v="VMware1!"/>

  <!-- Web Server -->
  <web-allow v="0.0.0.0/0"/>
</config>

Note: For any issues with [email protected] software or configurations, please refer to [email protected] documentation as well as their technical forums.

Step 6 - Start the [email protected] Client by running the following command:

/etc/init.d/FAHClient start

Note: If you wish to automatically start the [email protected] Client upon startup, create the following file /etc/rc.d/rc.local with the following content and ensure it has executable permissions:

#!/bin/bash

/etc/init.d/FAHClient start

If you plan to clone your configured [email protected] VM, make sure to run the following command below prior or you will have duplicate instances on your network.

echo -n > /etc/machine-id

This configuration is already handled for you within the VMware [email protected] Appliance and you simply run a quick PowerCLI script or clone using the vSphere UI (offline state) and you will not have this issue 🙂

More from my site

  • Cluster API BYOH Provider on Photon OS (Arm) with Tanzu Community Edition (TCE) and ESXi-Arm
  • Packer reference for PhotonOS Arm NFS Virtual Appliance using OVF properties for ESXi-Arm
  • Configuring Github Actions self-hosted runners on PhotonOS 
  • Packer reference for building PhotonOS Virtual Appliance using OVF properties 
  • Building your own Virtual Appliances using OVF properties Part 2

Categories // Automation, Not Supported Tags // Folding @ Home, Photon

Comments

  1. Alexandru says

    03/22/2020 at 5:31 pm

    What is the default username and password to login into the VMware [email protected] image?

    Reply
    • William Lam says

      03/22/2020 at 7:22 pm

      There’s no default password, you set it as part of deployment. Please carefully read the requirements on the Fling site

      Reply
  2. Marcelo Costa says

    03/23/2020 at 6:41 am

    Hi William, why did you not used the newer versions of [email protected] packages on the following links?
    https://download.foldingathome.org/releases/public/release/fahclient/centos-6.7-64bit/v7.5/fahclient-7.5.1-1.x86_64.rpm
    https://download.foldingathome.org/releases/public/release/fahcontrol/centos-6.7-64bit/v7.5/fahcontrol-7.5.1-1.noarch.rpm
    https://download.foldingathome.org/releases/public/release/fahviewer/centos-6.7-64bit/v7.5/fahviewer-7.5.1-1.x86_64.rpm

    Reply
    • William Lam says

      03/23/2020 at 7:42 am

      Hi Marcelo,

      I wasn't aware they had a newer version, I was simply following their official documentation on their site https://foldingathome.org/support/faq/installation-guides/linux/manual-installation-advanced/ and it looks like it points to 7.4 ... we can certainly look at 7.5 in a future update (v1.0.1 was just released a few minutes ago)

      Reply
      • Marcelo Ferreira da Costa says

        03/23/2020 at 7:52 am

        Hi William. That is a commom issue with [email protected] project. They usually do not update documentation. Sometimes it takes three years or more to them do that.

        Reply
        • DanCoco says

          03/26/2020 at 2:17 am

          I tried a fresh VM using the 7.5.1 links provided but cannot get FAHClient to start.

          [email protected] [ /etc/init.d ]# ./FAHClient restart -v
          Starting fahclient ... /usr/bin/FAHClient: error while loading shared libraries: libssl.so.10: cannot open shared object file: No such file or directory
          FAIL

          Is there another package I need?

          I tried the guide instructions as above and I couldn't get FAHControl to connect properly. It would show online, but then toggle to updating without ever loading. The Web control worked fine and it finished a work unit without issue. I'm giving up for tonight and will try again tomorrow after sleep.

          Reply
          • William Lam says

            03/26/2020 at 3:37 am

            If you look at my instructions, I'm using 7.4 and NOT 7.5. I've not tried the latest version but recommend using 7.4 and see if that works for you as that's what we're using in the official [email protected] Appliance

          • William Lam says

            04/01/2020 at 6:57 am

            I figured out how to get latest 7.5.1 working, it looks like its expecting specific shared libraries which aren't available. The fix was simple and the instructions have now been updated to use 7.5.1.

            FYI - I just published v1.0.2 which also includes 7.5.1 by default now

  3. Doug Billings says

    03/23/2020 at 7:01 am

    What are some recommended FW rules for a folding appliance on my home network?

    Reply
    • William Lam says

      03/23/2020 at 7:40 am

      Did you see the Note under Step 4?

      Reply
  4. Christopher Hoffman says

    03/23/2020 at 1:19 pm

    William, if you get the chance, please determine what is required to make an Nvidia GPU work in this scenario. Thanks.

    Reply
    • William Lam says

      03/23/2020 at 1:28 pm

      Please see the documentation found on the Fling page, it has instructions for setting up NVIDIA GRID 🙂 This is outside of the scope of this article

      Reply
  5. DMX says

    03/28/2020 at 8:00 am

    William thanks for this concise write up. Im a n00bie to linux so i have some easy questions for you. How do i edit the xml file? I tried at the CL of the virtual and tried SSH using putty. Actually i cant login via ssh it tells me access denied. I confirmed im using the correct pw. also when i try to start the fahclient i get a message the file or folder cant be found. TIA

    Reply
  6. Erik says

    04/01/2020 at 4:23 pm

    How to I view the status in a browser, it says I don't have access with I enter the IP:7396

    Reply
  7. Saqib-s says

    04/20/2020 at 5:53 am

    Great write up, got it working, just can't get the client to autostart on reboot, I've created the "/etc/rc.local/local.sh" file and it's executable, running this files does start up the FaH Client, but it does not seem to run on reboot.

    Any ideas?

    Reply
    • William Lam says

      04/20/2020 at 6:30 am

      My bad, I just realized the path to local.sh was incorrect :X

      It should be /etc/rc.d/rc.local/local.sh

      I've updated the blog post, this should auto-run now

      Reply
      • Saqib-s says

        04/20/2020 at 8:03 am

        done this and it does not seem to have made a difference

        Reply
        • tux says

          05/13/2020 at 8:22 am

          For me it is working using /etc/rc.d/rc.local as startup script (file, not directory) - instead of rc.local/local.sh

          Reply
          • Saqib-s says

            05/22/2020 at 7:11 am

            Thank you Tux this works!!! Author please correct to: /etc/rc.d/rc.local

  8. Saqib Sabir says

    05/23/2020 at 6:25 am

    Noticed today that my vm had an alert about pending updates referring me to tdnf, i ran "tdnf -y update" again and this seems to have installed the updates.

    I'd like the VM to installs updates periodically, and think inserting this command into the startup script might be simplest, Is there way to have the VM regularly reboot in order to refresh and update? The FaH workload seems to be happy with reboots in middle of processing?

    Reply
    • William Lam says

      05/24/2020 at 6:16 am

      Security/Update patches for PhotonOS is released monthly IIRC, so you could create a simple cronjob that runs a script that'll check for updates and then reboot. I'm sure you can find many examples online on how to create basic cron script

      Reply

Thanks for the comment! Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Author

William Lam is a Senior Staff Solution Architect working in the VMware Cloud team within the Cloud Infrastructure Business Group (CIBG) at VMware. He focuses on Cloud Native technologies, Automation, Integration and Operation for the VMware Cloud based Software Defined Datacenters (SDDC)

Connect

  • Email
  • GitHub
  • LinkedIn
  • RSS
  • Twitter
  • Vimeo

Recent

  • Self-Contained & Automated VMware Cloud Foundation (VCF) deployment using new VLC Holodeck Toolkit 03/29/2023
  • ESXi configstorecli enhancement in vSphere 8.0 Update 1 03/28/2023
  • ESXi on Intel NUC 13 Pro (Arena Canyon) 03/27/2023
  • Quick Tip - Enabling ESXi Coredumps to be stored on USB 03/26/2023
  • How to disable the Efficiency Cores (E-cores) on an Intel NUC? 03/24/2023

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2023

 

Loading Comments...