Page 2 of 3

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Thu Nov 28, 2019 3:06 pm
by Paragon
I can confirm that this problem exists, and I believe it is an issue with the Folding@Home client. I am running into the same thing with my Ubuntu 18.04 installation.

My system specs are:
OS: Ubuntu 18.04.3 LTS
Board: ASRock Socket FM2+
CPU: AMD Pro A10-8750B
Memory: 8 GB DDR3
Graphics: MSR Radeon RX 580 8 GB
HDD: Western Digital 250 GB
Power Supply: Seasonic Focus 550 Watt

I am using the latest Ubuntu Folding Client (V7.5.1). I got Proprietary Drivers from AMD for the RX 580. These are drivers specifically for Ubuntu 18.04. They are here: https://www.amd.com/en/support/graphics ... eon-rx-580

I followed the install guide here: https://amdgpu-install.readthedocs.io/en/latest/
I used the instruction

Code: Select all

$ ./amdgpu-pro-install -y --opencl=pal,legacy
to install all the open CL packages. From reading the release notes, this should have worked. I verified the existence of Open CL on the system using the CLINFO command:

Code: Select all

chris@Defiant:~$ clinfo
Number of platforms                               2
  Platform Name                                   Clover
  Platform Vendor                                 Mesa
  Platform Version                                OpenCL 1.1 Mesa 19.0.8
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             MESA

  Platform Name                                   AMD Accelerated Parallel Processing
  Platform Vendor                                 Advanced Micro Devices, Inc.
  Platform Version                                OpenCL 2.1 AMD-APP (2906.7)
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd cl_amd_event_callback cl_amd_offline_devices 
  Platform Host timer resolution                  1ns
  Platform Extensions function suffix             AMD

  Platform Name                                   Clover
Number of devices                                 1
  Device Name                                     Radeon RX 580 Series (POLARIS10, DRM 3.33.0, 5.0.0-36-generic, LLVM 8.0.0)
  Device Vendor                                   AMD
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 1.1 Mesa 19.0.8
  Driver Version                                  19.0.8
  Device OpenCL C Version                         OpenCL C 1.1 
  Device Type                                     GPU
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes
  Max compute units                               36
  Max clock frequency                             1380MHz
  Max work item dimensions                        3
  Max work item sizes                             256x256x256
  Max work group size                             256
  Preferred work group size multiple              64
  Preferred / native vector sizes                 
    char                                                16 / 16      
    short                                                8 / 8       
    int                                                  4 / 4       
    long                                                 2 / 2       
    half                                                 8 / 8        (cl_khr_fp16)
    float                                                4 / 4       
    double                                               2 / 2        (cl_khr_fp64)
  Half-precision Floating-point support           (cl_khr_fp16)
    Denormals                                     No
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 No
    Round to infinity                             No
    IEEE754-2008 fused multiply-add               No
    Support is emulated in software               No
  Single-precision Floating-point support         (core)
    Denormals                                     No
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 No
    Round to infinity                             No
    IEEE754-2008 fused multiply-add               No
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  No
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              8589934592 (8GiB)
  Error Correction support                        No
  Max memory allocation                           6871947673 (6.4GiB)
  Unified memory for Host and Device              No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       32768 bits (4096 bytes)
  Global Memory cache type                        None
  Image support                                   No
  Local memory type                               Local
  Local memory size                               32768 (32KiB)
  Max number of constant args                     16
  Max constant buffer size                        2147483647 (2GiB)
  Max size of kernel argument                     1024
  Queue properties                                
    Out-of-order execution                        No
    Profiling                                     Yes
  Profiling timer resolution                      0ns
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
  Device Extensions                               cl_khr_byte_addressable_store cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_fp64 cl_khr_fp16

  Platform Name                                   AMD Accelerated Parallel Processing
Number of devices                                 1
  Device Name                                     Ellesmere
  Device Vendor                                   Advanced Micro Devices, Inc.
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 1.2 AMD-APP (2906.7)
  Driver Version                                  2906.7
  Device OpenCL C Version                         OpenCL C 1.2 
  Device Type                                     GPU
  Device Board Name (AMD)                         Radeon RX 580 Series
  Device Topology (AMD)                           PCI-E, 01:00.0
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes
  Linker Available                                Yes
  Max compute units                               36
  SIMD per compute unit (AMD)                     4
  SIMD width (AMD)                                16
  SIMD instruction width (AMD)                    1
  Max clock frequency                             1380MHz
  Graphics IP (AMD)                               8.0
  Device Partition                                (core)
    Max number of sub-devices                     36
    Supported partition types                     None
  Max work item dimensions                        3
  Max work item sizes                             1024x1024x1024
  Max work group size                             256
  Preferred work group size (AMD)                 256
  Max work group size (AMD)                       1024
  Preferred work group size multiple              64
  Wavefront width (AMD)                           64
  Preferred / native vector sizes                 
    char                                                 4 / 4       
    short                                                2 / 2       
    int                                                  1 / 1       
    long                                                 1 / 1       
    half                                                 1 / 1        (cl_khr_fp16)
    float                                                1 / 1       
    double                                               1 / 1        (cl_khr_fp64)
  Half-precision Floating-point support           (cl_khr_fp16)
    Denormals                                     No
    Infinity and NANs                             No
    Round to nearest                              No
    Round to zero                                 No
    Round to infinity                             No
    IEEE754-2008 fused multiply-add               No
    Support is emulated in software               No
  Single-precision Floating-point support         (core)
    Denormals                                     No
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
    Correctly-rounded divide and sqrt operations  Yes
  Double-precision Floating-point support         (cl_khr_fp64)
    Denormals                                     Yes
    Infinity and NANs                             Yes
    Round to nearest                              Yes
    Round to zero                                 Yes
    Round to infinity                             Yes
    IEEE754-2008 fused multiply-add               Yes
    Support is emulated in software               No
  Address bits                                    64, Little-Endian
  Global memory size                              8060907520 (7.507GiB)
  Global free memory (AMD)                        7843820 (7.48GiB)
  Global memory channels (AMD)                    8
  Global memory banks per channel (AMD)           16
  Global memory bank width (AMD)                  256 bytes
  Error Correction support                        No
  Max memory allocation                           4244635648 (3.953GiB)
  Unified memory for Host and Device              No
  Minimum alignment for any data type             128 bytes
  Alignment of base address                       2048 bits (256 bytes)
  Global Memory cache type                        Read/Write
  Global Memory cache size                        16384 (16KiB)
  Global Memory cache line size                   64 bytes
  Image support                                   Yes
    Max number of samplers per kernel             16
    Max size for 1D images from buffer            134217728 pixels
    Max 1D or 2D image array size                 2048 images
    Base address alignment for 2D image buffers   256 bytes
    Pitch alignment for 2D image buffers          256 pixels
    Max 2D image size                             16384x16384 pixels
    Max 3D image size                             2048x2048x2048 pixels
    Max number of read image args                 128
    Max number of write image args                8
  Local memory type                               Local
  Local memory size                               32768 (32KiB)
  Local memory syze per CU (AMD)                  65536 (64KiB)
  Local memory banks (AMD)                        32
  Max number of constant args                     8
  Max constant buffer size                        4244635648 (3.953GiB)
  Preferred constant buffer size (AMD)            16384 (16KiB)
  Max size of kernel argument                     1024
  Queue properties                                
    Out-of-order execution                        No
    Profiling                                     Yes
  Prefer user sync for interop                    Yes
  Profiling timer resolution                      1ns
  Profiling timer offset since Epoch (AMD)        1574952467819615576ns (Thu Nov 28 09:47:47 2019)
  Execution capabilities                          
    Run OpenCL kernels                            Yes
    Run native kernels                            No
    Thread trace supported (AMD)                  Yes
    Number of async queues (AMD)                  2
    Max real-time compute queues (AMD)            0
    Max real-time compute units (AMD)             1920226060
    SPIR versions                                 1.2
  printf() buffer size                            4194304 (4MiB)
  Built-in kernels                                
  Device Extensions                               cl_khr_fp64 cl_amd_fp64 cl_khr_global_int32_base_atomics cl_khr_global_int32_extended_atomics cl_khr_local_int32_base_atomics cl_khr_local_int32_extended_atomics cl_khr_int64_base_atomics cl_khr_int64_extended_atomics cl_khr_3d_image_writes cl_khr_byte_addressable_store cl_khr_fp16 cl_khr_gl_sharing cl_amd_device_attribute_query cl_amd_vec3 cl_amd_printf cl_amd_media_ops cl_amd_media_ops2 cl_amd_popcnt cl_khr_image2d_from_buffer cl_khr_spir cl_khr_gl_event 

NULL platform behavior
  clGetPlatformInfo(NULL, CL_PLATFORM_NAME, ...)  No platform
  clGetDeviceIDs(NULL, CL_DEVICE_TYPE_ALL, ...)   No platform
  clCreateContext(NULL, ...) [default]            No platform
  clCreateContext(NULL, ...) [other]              Success [MESA]
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_DEFAULT)  Success (1)
    Platform Name                                 Clover
    Device Name                                   Radeon RX 580 Series (POLARIS10, DRM 3.33.0, 5.0.0-36-generic, LLVM 8.0.0)
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CPU)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_GPU)  Success (1)
    Platform Name                                 Clover
    Device Name                                   Radeon RX 580 Series (POLARIS10, DRM 3.33.0, 5.0.0-36-generic, LLVM 8.0.0)
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ACCELERATOR)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_CUSTOM)  No devices found in platform
  clCreateContextFromType(NULL, CL_DEVICE_TYPE_ALL)  Success (1)
    Platform Name                                 Clover
    Device Name                                   Radeon RX 580 Series (POLARIS10, DRM 3.33.0, 5.0.0-36-generic, LLVM 8.0.0)
As you can see, Open CL is installed and recognized by the system. However, the folding client does not detect it (although it does detect the RX 580):

Code: Select all

4:49:23:***********************************************************************
14:49:23:<config>
14:49:23:  <!-- Client Control -->
14:49:23:  <fold-anon v='true'/>
14:49:23:
14:49:23:  <!-- Network -->
14:49:23:  <proxy v=':8080'/>
14:49:23:
14:49:23:  <!-- User Information -->
14:49:23:  <team v='54345'/>
14:49:23:  <user v='_QC_Defiant'/>
14:49:23:
14:49:23:  <!-- Folding Slots -->
14:49:23:  <slot id='0' type='CPU'>
14:49:23:    <paused v='true'/>
14:49:23:  </slot>
14:49:23:  <slot id='1' type='GPU'>
14:49:23:    <paused v='true'/>
14:49:23:  </slot>
14:49:23:</config>
14:49:23:Switching to user fahclient
14:49:23:Trying to access database...
14:49:23:Successfully acquired database lock
14:49:23:Enabled folding slot 00: PAUSED cpu:2 (by user)
14:49:23:Enabled folding slot 01: PAUSED gpu:0:Ellesmere XT [Radeon RX 470/480/570/580] (by user)
14:49:23:ERROR:No compute devices matched GPU #0 AMD:5 Ellesmere XT [Radeon RX 470/480/570/580].  You may need to update your graphics drivers.
In summary, I have a successful install of the proprietary AMD Radeon drivers for Ubuntu 18.04, which include Open CL. I verified that those Open CL drivers are present. Yet, the folding client does not recognize any Open CL Devices. What next? Is folding on AMD Hardware in Ubuntu impossible?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Thu Nov 28, 2019 4:48 pm
by Paragon
I found a workaround based on this post:

viewtopic.php?f=74&t=31096

Basically you need to tweak the startup script for the client (/etc/init.d/FAHClient), changing the username from "fahclient" to "root". With root access, the client can see Open CL devices and fold correctly. This seems like a problem unique to AMD GPUs on Linux, since Nvidia GPUs work fine (once open CL is installed). It would be great to fix this, because giving the client root access seems like a bad idea...

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Thu Nov 28, 2019 4:51 pm
by bruce
What device code is shown by lspci?


It is not the x731f Ellesmere XT device and newer navi devices are not yet supported.

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 2:10 am
by Paragon
The RX 580, along with the RX 570 and older RX 4xx cards are all Polaris architecture (Ellesmere chip). This is one generation prior to Vega and two generations prior to Navi. The card was working fine in Windows previously...just switched it over to Linux.

lspci output:

Code: Select all

01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X] (rev e7)
I am happy to report that switching the fahclient's username to "Root" continues to work...it's cranking along nicely. Looks like fahclient can't see AMD OpenCL devices under the default install for some reason.

Note I think this fix will solve all of these people's issues, for when trying: "sudo apt install ocl-icd-opencl-dev" doesn't work. The issue isn't that OpenCL isn't installed, it's that the clien't can't see it (permissions issue solved by either setting the client's username to "root" or setting it to your own admin user name / giving the folder admin permissions)

viewtopic.php?f=81&t=31809
viewtopic.php?f=81&t=29534
viewtopic.php?f=81&t=28535
viewtopic.php?p=282991#p282991

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 4:55 am
by bruce
First: I wonder? Is it a permissions problem or a path problem?
Does the path change when you su to root?

Second, lspci should have given you the device codes... something like this:
0x1002 0x67df Ellesmere XT [Radeon RX 470/480/570/580]
I asked specifically for the codes on the left.


Third: post the **system** segment near the top of FAH's log.

It looks something like this:

19:40:28:******************************* System ********************************
19:40:28: CPU: Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz
19:40:28: CPU ID: GenuineIntel Family 6 Model 15 Stepping 11
19:40:28: CPUs: 4
19:40:28: Memory: 3.86GiB
19:40:28:Free Memory: 1.61GiB
19:40:28: Threads: POSIX_THREADS
19:40:28: OS Version: 4.7
19:40:28:Has Battery: false
19:40:28: On Battery: false
19:40:28: UTC Offset: 5
19:40:28: PID: 2495
19:40:28: CWD: /opt/fah
19:40:28: OS: Linux 4.7.2-1-ARCH x86_64
19:40:28: OS Arch: AMD64
19:40:28: GPUs: 1
19:40:28: GPU 0: ATI:4 Juniper [Radeon HD 5700/6750]
19:40:28: CUDA: Not detected
19:40:28:***********************************************************************
19:40:28:<config>
19:40:28: <!-- Folding Slot Configuration -->
19:40:28: <cause v='ALZHEIMERS'/>
19:40:28:
19:40:28: <!-- Network -->
19:40:28: <proxy v=':8080'/>
19:40:28:
19:40:28: <!-- Slot Control -->
19:40:28: <power v='MEDIUM'/>
19:40:28:
19:40:28: <!-- User Information -->
19:40:28: <passkey v='********************************'/>
19:40:28:
19:40:28: <!-- Folding Slots -->
19:40:28: <slot id='0' type='CPU'>
19:40:28: <paused v='true'/>
19:40:28: </slot>
19:40:28: <slot id='1' type='GPU'>
19:40:28: <paused v='true'/>
19:40:28: </slot>
19:40:28:</config>
(obviously yours will be different)

Is that segment different for root and your normal user?

Fourth: If you have installed the OpenCL from Intel, most people find it useful to remove it. In any case, for FAH to work, an Intel GPU should NOT be associated with a functional FAH GPU slot. (The last link you referenced specifically asked how to enable OpenCL on BOTH the CPU and the GPU, but it has been edited to the point of not being useful for FAH.)

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 1:10 pm
by Paragon
Bruce, thanks for the help, I appreciate you digging into this! I didn't see any change to the path when the client logs in as root. The only difference I saw in the log file is that of the user name (root vs fahclient). Specifically, where it says "switching to user root". Also it is finding the openCL devices when logged in as root.

Here is the full output from LSPCI. I didn't see any of those device ID codes...

Code: Select all

chris@Defiant:~$ lspci
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Root Complex
00:02.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Root Port
00:02.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Device 1425
00:03.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Root Port
00:04.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Root Port
00:10.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB XHCI Controller (rev 09)
00:10.1 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB XHCI Controller (rev 09)
00:11.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 40)
00:12.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB OHCI Controller (rev 11)
00:12.2 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB EHCI Controller (rev 11)
00:13.0 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB OHCI Controller (rev 11)
00:13.2 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB EHCI Controller (rev 11)
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 16)
00:14.1 IDE interface: Advanced Micro Devices, Inc. [AMD] FCH IDE Controller
00:14.2 Audio device: Advanced Micro Devices, Inc. [AMD] FCH Azalia Controller (rev 01)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 11)
00:14.4 PCI bridge: Advanced Micro Devices, Inc. [AMD] FCH PCI Bridge (rev 40)
00:14.5 USB controller: Advanced Micro Devices, Inc. [AMD] FCH USB OHCI Controller (rev 11)
00:15.0 PCI bridge: Advanced Micro Devices, Inc. [AMD] Hudson PCI to PCI bridge (PCIE port 0)
00:15.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Hudson PCI to PCI bridge (PCIE port 1)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 15h (Models 30h-3fh) Processor Function 5
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X] (rev e7)
01:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 580]
04:00.0 Ethernet controller: Qualcomm Atheros QCA8171 Gigabit Ethernet (rev 10)
Here is the output from lshw

Code: Select all

chris@Defiant:~$ sudo lshw -c video
  *-display                 
       description: VGA compatible controller
       product: Ellesmere [Radeon RX 470/480/570/570X/580/580X]
       vendor: Advanced Micro Devices, Inc. [AMD/ATI]
       physical id: 0
       bus info: pci@0000:01:00.0
       version: e7
       width: 64 bits
       clock: 33MHz
       capabilities: pm pciexpress msi vga_controller bus_master cap_list rom
       configuration: driver=amdgpu latency=0
       resources: irq:41 memory:c0000000-cfffffff memory:d0000000-d01fffff ioport:e000(size=256) memory:fea00000-fea3ffff memory:c0000-dffff
chris@Defiant:~$ 
Here is what I saw in the log file this morning. It is successfully folding, doing about 370K PPD, which is similar to what I saw in Windows for the RX580.

Code: Select all

*********************** Log Started 2019-11-29T04:33:04Z ***********************
04:33:04:************************* Folding@home Client *************************
04:33:04:        Website: https://foldingathome.org/
04:33:04:      Copyright: (c) 2009-2018 foldingathome.org
04:33:04:         Author: Joseph Coffland <joseph@cauldrondevelopment.com>
04:33:04:           Args: --child --lifeline 1777 /etc/fahclient/config.xml --run-as root
04:33:04:                 --pid-file=/var/run/fahclient.pid --daemon
04:33:04:         Config: /etc/fahclient/config.xml
04:33:04:******************************** Build ********************************
04:33:04:        Version: 7.5.1
04:33:04:           Date: May 11 2018
04:33:04:           Time: 19:59:04
04:33:04:     Repository: Git
04:33:04:       Revision: 4705bf53c635f88b8fe85af7675557e15d491ff0
04:33:04:         Branch: master
04:33:04:       Compiler: GNU 6.3.0 20170516
04:33:04:        Options: -std=gnu++98 -O3 -funroll-loops
04:33:04:       Platform: linux2 4.14.0-3-amd64
04:33:04:           Bits: 64
04:33:04:           Mode: Release
04:33:04:******************************* System ********************************
04:33:04:            CPU: AMD PRO A10-8750B R7, 12 Compute Cores 4C+8G
04:33:04:         CPU ID: AuthenticAMD Family 21 Model 56 Stepping 1
04:33:04:           CPUs: 4
04:33:04:         Memory: 7.73GiB
04:33:04:    Free Memory: 6.70GiB
04:33:04:        Threads: POSIX_THREADS
04:33:04:     OS Version: 5.0
04:33:04:    Has Battery: false
04:33:04:     On Battery: false
04:33:04:     UTC Offset: -5
04:33:04:            PID: 1780
04:33:04:            CWD: /var/lib/fahclient
04:33:04:             OS: Linux 5.0.0-36-generic x86_64
04:33:04:        OS Arch: AMD64
04:33:04:           GPUs: 1
04:33:04:          GPU 0: Bus:1 Slot:0 Func:0 AMD:5 Ellesmere XT [Radeon RX
04:33:04:                 470/480/570/580]
04:33:04:           CUDA: Not detected: Failed to open dynamic library 'libcuda.so':
04:33:04:                 libcuda.so: cannot open shared object file: No such file or
04:33:04:                 directory
04:33:04:OpenCL Device 0: Platform:0 Device:0 Bus:NA Slot:NA Compute:1.1 Driver:19.0
04:33:04:OpenCL Device 1: Platform:1 Device:0 Bus:1 Slot:0 Compute:1.2 Driver:2906.7
04:33:04:***********************************************************************
04:33:04:<config>
04:33:04:  <!-- Client Control -->
04:33:04:  <fold-anon v='true'/>
04:33:04:
04:33:04:  <!-- Network -->
04:33:04:  <proxy v=':8080'/>
04:33:04:
04:33:04:  <!-- Slot Control -->
04:33:04:  <power v='full'/>
04:33:04:
04:33:04:  <!-- User Information -->
04:33:04:  <passkey v='********************************'/>
04:33:04:  <team v='54345'/>
04:33:04:  <user v='_QC_Defiant'/>
04:33:04:
04:33:04:  <!-- Folding Slots -->
04:33:04:  <slot id='1' type='GPU'/>
04:33:04:</config>
04:33:04:Switching to user root
04:33:04:Trying to access database...
04:33:04:Successfully acquired database lock
04:33:04:Enabled folding slot 01: READY gpu:0:Ellesmere XT [Radeon RX 470/480/570/580]
04:33:04:WU01:FS01:Starting
04:33:05:WU01:FS01:Running FahCore: /usr/bin/FAHCoreWrapper /var/lib/fahclient/cores/cores.foldingathome.org/v7/lin/64bit/Core_21.fah/FahCore_21 -dir 01 -suffix 01 -version 705 -lifeline 1780 -checkpoint 15 -gpu-vendor amd -opencl-platform 1 -opencl-device 0 -gpu 0
04:33:05:WU01:FS01:Started FahCore on PID 1803
04:33:05:WU01:FS01:Core PID:1807
04:33:05:WU01:FS01:FahCore 0x21 started
04:33:09:WU01:FS01:0x21:*********************** Log Started 2019-11-29T04:33:09Z ***********************
04:33:09:WU01:FS01:0x21:Project: 14185 (Run 48, Clone 82, Gen 7)
04:33:09:WU01:FS01:0x21:Unit: 0x000000150002894c5d38972a77515355
04:33:09:WU01:FS01:0x21:CPU: 0x00000000000000000000000000000000
04:33:09:WU01:FS01:0x21:Machine: 1
04:33:09:WU01:FS01:0x21:Digital signatures verified
04:33:09:WU01:FS01:0x21:Folding@home GPU Core21 Folding@home Core
04:33:09:WU01:FS01:0x21:Version 0.0.20
04:33:09:WU01:FS01:0x21:  Found a checkpoint file
04:33:24:WU01:FS01:0x21:Completed 9250000 out of 12500000 steps (74%)
04:33:24:WU01:FS01:0x21:Temperature control disabled. Requirements: single Nvidia GPU, tmax must be < 110 and twait >= 900
04:35:13:WU01:FS01:0x21:Completed 9375000 out of 12500000 steps (75%)
04:37:04:WU01:FS01:0x21:Completed 9500000 out of 12500000 steps (76%)
04:38:54:WU01:FS01:0x21:Completed 9625000 out of 12500000 steps (77%)
04:40:45:WU01:FS01:0x21:Completed 9750000 out of 12500000 steps (78%)
04:42:35:WU01:FS01:0x21:Completed 9875000 out of 12500000 steps (79%)
04:44:26:WU01:FS01:0x21:Completed 10000000 out of 12500000 steps (80%)
04:46:17:WU01:FS01:0x21:Completed 10125000 out of 12500000 steps (81%)
04:48:07:WU01:FS01:0x21:Completed 10250000 out of 12500000 steps (82%)
04:49:58:WU01:FS01:0x21:Completed 10375000 out of 12500000 steps (83%)
04:51:48:WU01:FS01:0x21:Completed 10500000 out of 12500000 steps (84%)
04:53:38:WU01:FS01:0x21:Completed 10625000 out of 12500000 steps (85%)
04:55:29:WU01:FS01:0x21:Completed 10750000 out of 12500000 steps (86%)
04:57:20:WU01:FS01:0x21:Completed 10875000 out of 12500000 steps (87%)
04:59:10:WU01:FS01:0x21:Completed 11000000 out of 12500000 steps (88%)
05:01:00:WU01:FS01:0x21:Completed 11125000 out of 12500000 steps (89%)
05:02:51:WU01:FS01:0x21:Completed 11250000 out of 12500000 steps (90%)
05:04:42:WU01:FS01:0x21:Completed 11375000 out of 12500000 steps (91%)
05:06:32:WU01:FS01:0x21:Completed 11500000 out of 12500000 steps (92%)
05:08:22:WU01:FS01:0x21:Completed 11625000 out of 12500000 steps (93%)
05:10:12:WU01:FS01:0x21:Completed 11750000 out of 12500000 steps (94%)
05:12:03:WU01:FS01:0x21:Completed 11875000 out of 12500000 steps (95%)
05:13:52:WU01:FS01:0x21:Completed 12000000 out of 12500000 steps (96%)
05:15:42:WU01:FS01:0x21:Completed 12125000 out of 12500000 steps (97%)
05:17:32:WU01:FS01:0x21:Completed 12250000 out of 12500000 steps (98%)
05:19:21:WU01:FS01:0x21:Completed 12375000 out of 12500000 steps (99%)
05:19:22:WU00:FS01:Connecting to 65.254.110.245:8080
05:19:23:WU00:FS01:Assigned to work server 155.247.166.219
05:19:23:WU00:FS01:Requesting new work unit for slot 01: RUNNING gpu:0:Ellesmere XT [Radeon RX 470/480/570/580] from 155.247.166.219

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 6:13 pm
by bruce
Have you tried "locate opencl" and then change the permissions so that anybody can Read and eXecute them?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 7:51 pm
by Paragon
I haven't tried adjusting permissions yet. Based on some of the other threads I linked earlier, plus this:

https://askubuntu.com/questions/632045/ ... ks-as-root

I am going to try adding the fahclient user name to the video user group (apparently this is a requirement for opencl). If that doesn't work I'll start opening up permissions on the opencl directories. Currently I'm just waiting to make sure this system is stable (I want to get 10 work units out of it now that I finally have it working).

Here is the output from the locate command:

Code: Select all

chris@Defiant:~$ locate opencl
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/libopencl1-amdgpu-pro_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/libopencl1-amdgpu-pro_19.30-934563_i386.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-amdgpu-pro-comgr_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-amdgpu-pro-dev_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-amdgpu-pro-icd_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-amdgpu-pro_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-orca-amdgpu-pro-icd_19.30-934563_amd64.deb
/home/chris/Downloads/amdgpu-pro-19.30-934563-ubuntu-18.04/opencl-orca-amdgpu-pro-icd_19.30-934563_i386.deb
/opt/amdgpu-pro/include/CL/opencl.h
/snap/gnome-3-28-1804/110/usr/share/gtksourceview-3.0/language-specs/opencl.lang
/snap/gnome-3-28-1804/110/usr/share/mime/text/x-opencl-src.xml
/snap/gnome-3-28-1804/67/usr/share/gtksourceview-3.0/language-specs/opencl.lang
/snap/gnome-3-28-1804/67/usr/share/mime/text/x-opencl-src.xml
/snap/gnome-calculator/406/usr/share/gtksourceview-4/language-specs/opencl.lang
/snap/gnome-calculator/544/usr/share/gtksourceview-4/language-specs/opencl.lang
/usr/include/CL/opencl.h
/usr/lib/libreoffice/program/opencl
/usr/lib/libreoffice/program/opencl/cl-test.ods
/usr/lib/libreoffice/share/config/soffice.cfg/cui/ui/optopenclpage.ui
/usr/lib/llvm-8/lib/clang/8.0.0/include/opencl-c.h
/usr/share/bug/mesa-opencl-icd
/usr/share/bug/mesa-opencl-icd/control
/usr/share/bug/mesa-opencl-icd/script
/usr/share/doc/libopencl1-amdgpu-pro
/usr/share/doc/mesa-opencl-icd
/usr/share/doc/ocl-icd-libopencl1
/usr/share/doc/ocl-icd-opencl-dev
/usr/share/doc/opencl-amdgpu-pro-comgr
/usr/share/doc/opencl-amdgpu-pro-dev
/usr/share/doc/opencl-amdgpu-pro-icd
/usr/share/doc/opencl-c-headers
/usr/share/doc/opencl-orca-amdgpu-pro-icd
/usr/share/doc/libopencl1-amdgpu-pro/changelog.Debian.gz
/usr/share/doc/libopencl1-amdgpu-pro/copyright
/usr/share/doc/mesa-opencl-icd/changelog.Debian.gz
/usr/share/doc/mesa-opencl-icd/copyright
/usr/share/doc/ocl-icd-libopencl1/NEWS.Debian.gz
/usr/share/doc/ocl-icd-libopencl1/README
/usr/share/doc/ocl-icd-libopencl1/README.Debian.gz
/usr/share/doc/ocl-icd-libopencl1/changelog.Debian.gz
/usr/share/doc/ocl-icd-libopencl1/copyright
/usr/share/doc/ocl-icd-libopencl1/html
/usr/share/doc/ocl-icd-libopencl1/html/libOpenCL.html
/usr/share/doc/ocl-icd-opencl-dev/changelog.Debian.gz
/usr/share/doc/ocl-icd-opencl-dev/copyright
/usr/share/doc/opencl-amdgpu-pro-comgr/changelog.Debian.gz
/usr/share/doc/opencl-amdgpu-pro-comgr/copyright
/usr/share/doc/opencl-amdgpu-pro-dev/changelog.Debian.gz
/usr/share/doc/opencl-amdgpu-pro-dev/copyright
/usr/share/doc/opencl-amdgpu-pro-icd/changelog.Debian.gz
/usr/share/doc/opencl-amdgpu-pro-icd/copyright
/usr/share/doc/opencl-c-headers/changelog.Debian.gz
/usr/share/doc/opencl-c-headers/copyright
/usr/share/doc/opencl-orca-amdgpu-pro-icd/changelog.Debian.gz
/usr/share/doc/opencl-orca-amdgpu-pro-icd/copyright
/usr/share/doc-base/ocl-icd-libopencl1
/usr/share/gtksourceview-3.0/language-specs/opencl.lang
/usr/share/lintian/overrides/mesa-opencl-icd
/usr/share/lintian/overrides/ocl-icd-libopencl1
/usr/share/lintian/overrides/opencl-c-headers
/usr/share/mime/text/x-opencl-src.xml
/var/lib/app-info/icons/ubuntu-bionic-universe/64x64/openclonk_openclonk.png
/var/lib/dpkg/info/libopencl1-amdgpu-pro:amd64.list
/var/lib/dpkg/info/libopencl1-amdgpu-pro:amd64.md5sums
/var/lib/dpkg/info/libopencl1-amdgpu-pro:amd64.shlibs
/var/lib/dpkg/info/libopencl1-amdgpu-pro:amd64.triggers
/var/lib/dpkg/info/mesa-opencl-icd:amd64.conffiles
/var/lib/dpkg/info/mesa-opencl-icd:amd64.list
/var/lib/dpkg/info/mesa-opencl-icd:amd64.md5sums
/var/lib/dpkg/info/mesa-opencl-icd:amd64.shlibs
/var/lib/dpkg/info/mesa-opencl-icd:amd64.triggers
/var/lib/dpkg/info/ocl-icd-libopencl1:amd64.list
/var/lib/dpkg/info/ocl-icd-libopencl1:amd64.md5sums
/var/lib/dpkg/info/ocl-icd-libopencl1:amd64.shlibs
/var/lib/dpkg/info/ocl-icd-libopencl1:amd64.symbols
/var/lib/dpkg/info/ocl-icd-libopencl1:amd64.triggers
/var/lib/dpkg/info/ocl-icd-opencl-dev:amd64.list
/var/lib/dpkg/info/ocl-icd-opencl-dev:amd64.md5sums
/var/lib/dpkg/info/opencl-amdgpu-pro-comgr.list
/var/lib/dpkg/info/opencl-amdgpu-pro-comgr.md5sums
/var/lib/dpkg/info/opencl-amdgpu-pro-dev.list
/var/lib/dpkg/info/opencl-amdgpu-pro-dev.md5sums
/var/lib/dpkg/info/opencl-amdgpu-pro-icd.conffiles
/var/lib/dpkg/info/opencl-amdgpu-pro-icd.list
/var/lib/dpkg/info/opencl-amdgpu-pro-icd.md5sums
/var/lib/dpkg/info/opencl-c-headers.list
/var/lib/dpkg/info/opencl-c-headers.md5sums
/var/lib/dpkg/info/opencl-orca-amdgpu-pro-icd:amd64.conffiles
/var/lib/dpkg/info/opencl-orca-amdgpu-pro-icd:amd64.list
/var/lib/dpkg/info/opencl-orca-amdgpu-pro-icd:amd64.md5sums
/var/opt/amdgpu-pro-local/libopencl1-amdgpu-pro_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/libopencl1-amdgpu-pro_19.30-934563_i386.deb
/var/opt/amdgpu-pro-local/opencl-amdgpu-pro-comgr_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/opencl-amdgpu-pro-dev_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/opencl-amdgpu-pro-icd_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/opencl-amdgpu-pro_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/opencl-orca-amdgpu-pro-icd_19.30-934563_amd64.deb
/var/opt/amdgpu-pro-local/opencl-orca-amdgpu-pro-icd_19.30-934563_i386.deb
chris@Defiant:~$ 
Which folder do you think is the one that the client uses?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Fri Nov 29, 2019 11:01 pm
by bruce
None of those. (dot)DEB files are (compressed) files which can be installed (but may not have been installed yet). Either OpenCL is not installed or you didn't find the library and the run-time moddules.

Maybe they're in the same place as clinfo. Have you tried locate clinfo and seeing what else is in that directory?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Sat Nov 30, 2019 6:41 am
by MeeLee
Does AMD show any performance improvements on Linux VS Windows?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Tue Dec 03, 2019 1:29 pm
by Paragon
Ill try to look into the permissions a bit more this week...have been busy. The machine is cranking along with anywhere between 280 and 420k PPD depending on work unit. On windows it averaged around 350-375K PPD...so I am seeing more variation in Linux but it's not unreasonable. One thing I haven't been able to figure out is how to enable compute mode in the AMD Linux driver. There is a toggle in the Windows AMD Crimson ReLive GUI to switch the GPU workload from graphics to compute...this yields about a 10 percent improvement on some work units according to my testing. Can't find a similar toggle in Ubuntu...there also is no GUI for the driver there.

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Sun Mar 15, 2020 11:32 pm
by senecaso
This is exactly the issue I am facing as well. At first I noticed that `clinfo` would not list any devices unless I ran as root, so I added my user and the `fahclient` user to the `video` group. This allowed both users to run `clinfo` and have it correctly list the CL platform and device (AMD RX 560). I have another machine running nvidia with no problems at all, so somehow this is specific to AMD.

Has anyone figured out what the issue is? Running as `root` is not really an acceptable solution for me, and this seems like it should just be a permission issue somewhere.

Is there a way to get more debug output? Either from the FAHClient itself, or from FAHBench? Both of them seem to have the same issue:

Code: Select all

user@computer:~/FAHBench-2.3.2-Linux$ ./bin/FAHBench-cmd -v
FAHBench version 2.3.2
OpenMM version 6.2 FAH Core 0x21 v0.0.18

user@computer:~/FAHBench-2.3.2-Linux$ ./bin/FAHBench-cmd -d
Device                    Type        Dev Plat  Platform version             Device version              
----------------------------------------------------------------------------------------------------
OpenCL Error: Cannot get platforms.

Code: Select all

user@compute:~/FAHBench-2.3.2-Linux$ sudo -u fahclient clinfo | head -n 20
[sudo] password for senecaso: 
Number of platforms                               1
  Platform Name                                   Clover
  Platform Vendor                                 Mesa
  Platform Version                                OpenCL 1.1 Mesa 20.1.0-devel (git-b93a195 2020-03-14 bionic-oibaf-ppa)
  Platform Profile                                FULL_PROFILE
  Platform Extensions                             cl_khr_icd
  Platform Extensions function suffix             MESA

  Platform Name                                   Clover
Number of devices                                 1
  Device Name                                     Radeon RX 560 Series (POLARIS11, DRM 3.33.0, 5.3.0-40-generic, LLVM 9.0.0)
  Device Vendor                                   AMD
  Device Vendor ID                                0x1002
  Device Version                                  OpenCL 1.1 Mesa 20.1.0-devel (git-b93a195 2020-03-14 bionic-oibaf-ppa)
  Driver Version                                  20.1.0-devel
  Device OpenCL C Version                         OpenCL C 1.1 
  Device Type                                     GPU
  Device Profile                                  FULL_PROFILE
  Device Available                                Yes
  Compiler Available                              Yes

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Mon Mar 16, 2020 11:20 am
by lordasshat
not running ubuntu my self but this form post here https://setiathome.berkeley.edu/forum_t ... p?id=84737 got me on the right track for Arch Linux it appears f@h, boinc, and setti require the legacy options of opencl. But amd cards can fold as i am doing it in arch/manjaro with a vega 64
This info may not help but i hope it does.

Edit failed to see you already had this info. should refrain from posting untill i have been awake for more than an hour. cheers.

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Tue Mar 24, 2020 2:54 pm
by mreich
Has someone found a fix for this issue? With the recent boom in F@H demand, and the recent global virus issue, I joined in too (I have been running BOINC for a very long time, and Rosetta@Home is also running a COVID-19 work unit). But on Ubuntu 19.10, with everything up-to-date and with OpenCL installed, the

Code: Select all

clGetDeviceIDs() returned -1
continues to be an issue. The Control client has registered a slot for the GPU, but I'm not sure if it is going to get any tasks. No one on the F@H dev team can do a check on this bug?

Re: Ubuntu 18.04 / 16.04 with AMD Rx 570s

Posted: Tue Mar 24, 2020 10:38 pm
by Paragon
Other than by running the client as root, I haven't been able to get it to fold. The user group stuff didn't work for me.