Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

It seems that a lot of GPU problems revolve around specific versions of drivers. Though AMD has their own support structure, you can often learn from information reported by others who fold.

Moderators: Site Moderators, FAHC Science Team

Post Reply
muziqaz
Posts: 1073
Joined: Sun Dec 16, 2007 6:22 pm
Hardware configuration: 9950x, 7950x3D, 5950x, 5800x3D
7900xtx, Radeon 7, 5700xt, 6900xt, RX 550 640SP
Location: London
Contact:

Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by muziqaz »

Since things have improved on AMD's side and on FAH side, I thought it would be good idea to write a guide on how to get your AMD GPU folding.
I know there are many old threads regarding this, but boy, did things have simplified and improved on AMD's delivery of their ROCm OpenCL platform.
So, the catalyst for all of this is AMD GPU (newer than Polaris, sorry) and rocm-opencl-sdk (NOTE: not rocm-opencl, not opencl-sdk, not rocm-opencl, not opencl-runtime).
People, who know how to add Radeon repo to their distro sources, you need to add rocm 6.3.4 repo, and then install rocm-opencl-sdk, restart fah-client service, or reboot the system, and you should be good to go. Your FAHclient v8 should report your GPU as supported in web UI system info section.
For others:

--Ubuntu, Kubuntu, Lubuntu, Pop_OS:
Ubuntu might still have ROCm stored in its repos. Write "sudo apt install rocm-opencl" and tap TAB couple of times for suggestions to be listed, if "rocm-opencl-sdk" is one of them, skip adding radeon repo, and continue reading the guide from "sudo apt install rocm-opencl-sdk" line below. Otherwise, continue from next sentence.
Go to https://repo.radeon.com/amdgpu-install/6.2.3/ubuntu/, click on your version codename (Noble=24.04, Jammy=22.04, Focal=20.04) and download amdgpu-install_6.2.60203-1_all.deb. DO NOT download anything from 6.3 branch, unless you have $20k-200k+ AMD Instinct MI300A/X!!
Go to your Downloads folder, double click on downloaded package, enter your root password, and click install, to install it. This will add rocm repository to your sources, from which you will be able to grab ROCm related packages.
From console enter following:
sudo apt update && sudo apt upgrade
sudo apt install rocm-opencl-sdk
sudo systemctl restart fah-client
<---if you have fah-client already installed and running
groups fah-client <---it should return following: fah-client : fah-client video render
sudo usermod -a -G render fah-client <---if "groups fah-client" command does not show fahclient being in render group (system restart is needed after this command)
Check Web UI System Info section if your GPU is now supported (Should say True next to Supported)

--Linux Mint:
Go to https://repo.radeon.com/amdgpu-install/6.2.3/ubuntu/, click on your version codename (Noble=22, Jammy=21, Focal=20) and download amdgpu-install_6.2.60203-1_all.deb. DO NOT download anything from 6.3 branch, unless you have $20k-200k+ AMD Instinct MI300A/X!!
Go to your Downloads folder, double click on downloaded package, enter your root password, and click install, to install it. This will add rocm repository to your sources, from which you will be able to grab ROCm related packages.
From console enter following:
sudo apt update && sudo apt upgrade
sudo apt install rocm-opencl-sdk
sudo systemctl restart fah-client
<---if you have fah-client already installed and running
groups fah-client <---it should return following: fah-client : fah-client video render
sudo usermod -a -G render fah-client <---if "groups fah-client" command does not show fahclient being in render group (system restart is needed after this command)
Check Web UI System Info section if your GPU is now supported (Should say True next to Supported)

--Debian:
Older than Debian 12 might have issues with drivers, but with more recent kernels, hopefully things would work.
Go to https://repo.radeon.com/amdgpu-install/6.2.3/ubuntu/, click on your version codename (Noble=13, Jammy=12, Focal=11) and download amdgpu-install_6.2.60203-1_all.deb. DO NOT download anything from 6.3 branch, unless you have $20k-200k+ AMD Instinct MI300A/X!!
Go to your Downloads folder, double click on downloaded package, enter your root password, and click install, to install it. This will add rocm repository to your sources, from which you will be able to grab ROCm related packages.
From console enter following:
sudo apt update && sudo apt upgrade
sudo apt install rocm-opencl-sdk
sudo systemctl restart fah-client
<---if you have fah-client already installed and running
groups fah-client <---it should return following: fah-client : fah-client video render
sudo usermod -a -G render fah-client <---if "groups fah-client" command does not show fahclient being in render group (system restart is needed after this command)
Check Web UI System Info section if your GPU is now supported (Should say True next to Supported)

--Fedora 40+:
Go to https://repo.radeon.com/amdgpu-install/6.2.3/el/ or https://repo.radeon.com/amdgpu-install/6.2.3/rhel/ (both are identical), find out which version your Fedora is based on (Geese Geese Go is failing me miserably, but I think Fedora 40 likes anything from el9.x/rhel9.x) and download amdgpu-install-6.2.60203-1.el9.noarch.rpm. DO NOT download anything from 6.3 branch, unless you have $20k-200k+ AMD Instinct MI300A/X!!
Go to your Downloads folder, double click on downloaded package, enter your root password, and click install, to install it. This will add rocm repository to your sources, from which you will be able to grab ROCm related packages.
From console enter following:
sudo dnf update
sudo dnf install rocm-opencl-sdk
sudo systemctl restart fah-client
<---if you have fah-client already installed and running
groups fah-client <---it should return following: fah-client : fah-client video render
sudo usermod -a -G render fah-client <---if "groups fah-client" command does not show fahclient being in render group (system restart is needed after this command)
Check Web UI System Info section if your GPU is now supported (Should say True next to Supported)

--ArchLinux, Manjaro, Endeavours:
There is no Radeon repo for you, btw, hm, I need to ask AMD, why...
But I heard you are quite resourceful ladies and gents. I believe rocm-opencl-sdk is available in AUR repos (it is present in Endeavours), so if that is the case you can adapt your installation sequence from any above examples. Best of luck :)

--OpenSuse: Following has issues with dependencies
Add https://repo.radeon.com/rocm/zyp/6.2.3/main/ to your Yast Repositories app. DO NOT add anything from 6.3 branch, unless you have $20k-200k+ AMD Instinct MI300A/X!!
From console enter following:
sudo zypper in rocm-opencl-sdk <---Choose solution 2, to ignore the dependency (I asked AMD why this is the issue, hope they'll fix it)
sudo systemctl restart fah-client <---if you have fah-client already installed and running
groups fah-client <---it should return following: fah-client : fah-client video render, or at least render
sudo usermod -a -G render fah-client <---if "groups fah-client" command does not show fahclient being in render group (system restart is needed after this command)
Check Web UI System Info section if your GPU is now supported (Should say True next to Supported)

If things are not working out, I'll post few more optional suggestions in the second post of this thread
FAH Omega tester
muziqaz
Posts: 1073
Joined: Sun Dec 16, 2007 6:22 pm
Hardware configuration: 9950x, 7950x3D, 5950x, 5800x3D
7900xtx, Radeon 7, 5700xt, 6900xt, RX 550 640SP
Location: London
Contact:

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by muziqaz »

In the past sudo usermod -a -G render your-linux-username and a reboot would help, but I was told that fah-client v8 installer sorts that upon installation by adding fah-client as a user to render group. I tested this on Debian 12, and it does indeed do that, yay

Sometimes installing rocm opencl icd loader helps with the cause

In the past I used to use clinfo to see if opencl platform and device are correctly set up. This apparently no longer is needed. My Debian 12 test set up showed no opencl devices, yet fah-client was folding on my GPU without issues.
clinfo might wake up if you add your linux user to render and video groups (just guessing).

This guide will be obsolete once/if FAH releases HIP fahcore for AMD. That will most likely require new guide (ultimate plus max pro ai), or maybe just rocm-hip-sdk installation from same repos mentioned in this guide. Not sure yet.

Penultimate thanks goes to calxalot for clarification about fah-client user in render group :D :P
FAH Omega tester
Marcos FRM
Posts: 27
Joined: Fri Feb 23, 2024 6:26 pm

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by Marcos FRM »

I looked into what this AMD rocm-opencl-sdk package consists of in Fedora. It is an empty package that depends on the following packages:

hsa-rocr-devel
hsakmt-roct-devel
rocm-core
rocm-opencl-devel
rocm-opencl-runtime

Fedora packages several ROCm packages. Maybe it's a matter of figuring out which ones are equivalent to those above. I remember reading that the mesa-libOpenCL package needs to be uninstalled, otherwise it causes problems.
muziqaz
Posts: 1073
Joined: Sun Dec 16, 2007 6:22 pm
Hardware configuration: 9950x, 7950x3D, 5950x, 5800x3D
7900xtx, Radeon 7, 5700xt, 6900xt, RX 550 640SP
Location: London
Contact:

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by muziqaz »

Marcos, you are not the first to look into what that rocm-opencl-sdk package does or contains, even people around AMD looked into this ;)
There also was investigation into what of rocm Fedora packages now, since they stripped everything after Fedora 39. I spent good part of last year narrowing this down, don't really want to spend more time on the API which soon will be replaced by HIP, and I will have to start from zero again :D
What is easier? A separate different guide for each distro, or one guide encompassing all the popular distros with near identical steps? :)
FAH Omega tester
Marcos FRM
Posts: 27
Joined: Fri Feb 23, 2024 6:26 pm

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by Marcos FRM »

Excluding the -devel packages, which, in theory, aren't needed, installing the rocm-opencl package from the Fedora repository would be the equivalent, which you've already proven doesn't work. :lol:

Have you tried installing just the rocm-opencl-runtime package from the AMD repository (it should bring in rocm-core as a dependency, but I haven't checked)? Or let's just leave it as it is... hehe
muziqaz
Posts: 1073
Joined: Sun Dec 16, 2007 6:22 pm
Hardware configuration: 9950x, 7950x3D, 5950x, 5800x3D
7900xtx, Radeon 7, 5700xt, 6900xt, RX 550 640SP
Location: London
Contact:

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by muziqaz »

To be fair, I found the working formula, and called it quits. By the time I would find the more precise package, AMD would probably change something, or distros would come up with new filing "solutions". It doesn't help my mental health when AMD decides to package consumer oriented rocm 6.2.x version and then continue with 6.3.x version which is completely different and is meant for HPC products, and does not work for desktop GPUs, and then expect desktop users to follow their documentations, which suggest to use 6.2.3 as well as has a very short list of their products which are tested and supported, while I myself already went through majority of AMD products myself with several ROCm versions to validate them for FAH making the whole documentation completely pointless for me. At this point I'm kinda exhausted with all this, and am just too happy that there is something consistent which works across all the distros :D until HIP hits the streets, that is :D
FAH Omega tester
muziqaz
Posts: 1073
Joined: Sun Dec 16, 2007 6:22 pm
Hardware configuration: 9950x, 7950x3D, 5950x, 5800x3D
7900xtx, Radeon 7, 5700xt, 6900xt, RX 550 640SP
Location: London
Contact:

Re: Ultimate AMD GPU Linux FAH Guide for OpenCL (FAH-Client v8 only)

Post by muziqaz »

Oh, to add, I did try rocm-opencl-runtime, and I think devel package, they did not work. That's when I updated to fedora 40 which has stripped everything but few packages of rocm, and suggested users to compile their rocm libraries themselves :D That was not a very good month :D
FAH Omega tester
Post Reply