No OpenCL library found, Mint Linux on AMD CPU/GPU.

KarmannGaz
KarmannGaz
Joined: 25 Mar 09
Posts: 10
Credit: 17839880
RAC: 1758
Topic 198225

Hi,
I am trying to get Einstein to run GPU tasks under Linux OS (again). I have an AMD Athlon X2 based PC running Mint Linux 17.2, and an Asus AMD Radeon HD6670 GPU card installed. AMD SDK 3.0 installed from the AMD site.
BOINC starts up and recognises the GPU ok, but says it cant find the OpenCL library :

Thu 10 Sep 2015 17:19:28 BST |  | Starting BOINC client version 7.2.42 for x86_64-pc-linux-gnu
Thu 10 Sep 2015 17:19:28 BST |  | log flags: file_xfer, sched_ops, task, coproc_debug
Thu 10 Sep 2015 17:19:28 BST |  | Libraries: libcurl/7.35.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 librtmp/2.3
Thu 10 Sep 2015 17:19:28 BST |  | Data directory: /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] launching child process at /usr/bin/boinc
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] relative to directory /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] with data directory /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | CAL: ATI GPU 0: AMD Radeon HD 6570/6670/7570/7670 series (Turks) (CAL version 1.4.1848, 2048MB, 1959MB available, 1536 GFLOPS peak)
Thu 10 Sep 2015 17:19:28 BST |  | NVIDIA drivers present but no GPUs found
Thu 10 Sep 2015 17:19:28 BST |  | No OpenCL library found
Thu 10 Sep 2015 17:19:28 BST |  | Host name: ColinsCorner
Thu 10 Sep 2015 17:19:28 BST |  | Processor: 2 AuthenticAMD AMD Athlon(tm) 64 X2 Dual Core Processor 5000+ [Family 15 Model 107 Stepping 2]
Thu 10 Sep 2015 17:19:28 BST |  | Processor features: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt rdtscp lm 3dnowext 3dnow rep_good nopl extd_apicid pni cx16 lahf_lm cmp_legacy svm extapic cr8_legacy 3dnowprefetch lbrv vmmcall
Thu 10 Sep 2015 17:19:28 BST |  | OS: Linux: 3.16.0-38-generic
Thu 10 Sep 2015 17:19:28 BST |  | Memory: 3.86 GB physical, 1.91 GB virtual
Thu 10 Sep 2015 17:19:28 BST |  | Disk: 69.74 GB total, 59.13 GB free
Thu 10 Sep 2015 17:19:28 BST |  | Local time is UTC +1 hours
Thu 10 Sep 2015 17:19:28 BST |  | Config: use all coprocessors
Thu 10 Sep 2015 17:19:28 BST |  | Config: GUI RPCs allowed from:
Thu 10 Sep 2015 17:19:28 BST | Einstein@Home | URL http://einstein.phys.uwm.edu/; Computer ID 12029403; resource share 101


I can see libOpenCL.so and libOpenCL.so.1 on /usr/lib32/
I have also checked this is in LD_LIBRARY_PATH :

echo $LD_LIBRARY_PATH
/opt/AMDAPPSDK-3.0/lib/x86_64/:/usr/lib32


and have added the following to my .bashrc file :

# for BOINC Einstein GPU to find OpenCL
export LD_LIBRARY_PATH="/opt/AMDAPPSDK-3.0/lib/x86_64/:/usr/lib32"


but BOINC refuses to see that the OpenCL library is there. I even tried copying libOpenCL.so to the AMDAPPSDK-3.0 library as well, but it still cant find it. Where is BOINC looking, exactly? I notice there is a line in the output saying Libraries: libcurl/7.35.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 librtmp/2.3 - yet when I search, for example, for the first one (libcurl), it is ME who can't find it! How can it search libraries that do not exist, yet skip ones that do?
I just wondered if anyone has successfully got a Radeon card working for Einstein under a Linux OS, or am I wasting my time here? It seems so close, just a silly search library pointer to get right perhaps, but where?

floyd
floyd
Joined: 12 Sep 11
Posts: 133
Credit: 186610495
RAC: 0

No OpenCL library found, Mint Linux on AMD CPU/GPU.

Why lib32 I wonder. You seem to be running a 64 bit system.

AgentB
AgentB
Joined: 17 Mar 12
Posts: 915
Credit: 513211304
RAC: 0

RE: Hi, I am trying to get

Quote:

Hi,
I am trying to get Einstein to run GPU tasks under Linux OS (again). I have an AMD Athlon X2 based PC running Mint Linux 17.2, and an Asus AMD Radeon HD6670 GPU card installed. AMD SDK 3.0 installed from the AMD site.

I am not entirely sure you need the SDK. Are you sure you have installed the right drivers? (as mentioned by floyd below).

I'm not a Mint flavoured linux myself, but you must have fglrx installed to run OpenCL apps here

Read carefully the library dependencies, and OS versions supported.

clinfo should reveal

agentb@gluon:~/ATI$ clinfo
Number of platforms: 1
Platform Profile: FULL_PROFILE
Platform Version: OpenCL 2.0 AMD-APP (1702.3)
Platform Name: AMD Accelerated Parallel Processing
Platform Vendor: Advanced Micro Devices, Inc.
Platform Extensions: cl_khr_icd cl_amd_event_callback cl_amd_offline_devices

Platform Name: AMD Accelerated Parallel Processing
Number of devices: 3
Device Type: CL_DEVICE_TYPE_GPU
Vendor ID: 1002h
Board name: AMD Radeon HD 7900 Series

I am running 15.5 and my struggles were posted here

That boinc GPU forum has several related issues, which you may have read. you need to search longer than the default month to find Mint related posts.

Quote:

BOINC starts up and recognises the GPU ok, but says it cant find the OpenCL library :
but BOINC refuses to see that the OpenCL library is there. I even tried copying libOpenCL.so to the AMDAPPSDK-3.0 library as well, but it still cant find it. Where is BOINC looking, exactly? I notice there is a line in the output saying Libraries: libcurl/7.35.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 librtmp/2.3 - yet when I search, for example, for the first one (libcurl), it is ME who can't find it! How can it search libraries that do not exist, yet skip ones that do?
I just wondered if anyone has successfully got a Radeon card working for Einstein under a Linux OS, or am I wasting my time here?

Yes, many of the ubercrunchers are AMD+Linux based and no you are not.

Quote:

It seems so close, just a silly search library pointer to get right perhaps, but where?

maybe... good luck.

Anonymous

RE: Hi, I am trying to get

Quote:
Hi,
I am trying to get Einstein to run GPU tasks under Linux OS (again). I have an AMD Athlon X2 based PC running Mint Linux 17.2, and an Asus AMD Radeon HD6670 GPU card installed. AMD SDK 3.0 installed from the AMD site.
BOINC starts up and recognises the GPU ok, but says it cant find the OpenCL library :
Thu 10 Sep 2015 17:19:28 BST |  | Starting BOINC client version 7.2.42 for x86_64-pc-linux-gnu
Thu 10 Sep 2015 17:19:28 BST |  | log flags: file_xfer, sched_ops, task, coproc_debug
Thu 10 Sep 2015 17:19:28 BST |  | Libraries: libcurl/7.35.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 librtmp/2.3
Thu 10 Sep 2015 17:19:28 BST |  | Data directory: /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] launching child process at /usr/bin/boinc
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] relative to directory /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | [coproc] with data directory /var/lib/boinc-client
Thu 10 Sep 2015 17:19:28 BST |  | CAL: ATI GPU 0: AMD Radeon HD 6570/6670/7570/7670 series (Turks) (CAL version 1.4.1848, 2048MB, 1959MB available, 1536 GFLOPS peak)
Thu 10 Sep 2015 17:19:28 BST |  | NVIDIA drivers present but no GPUs found
Thu 10 Sep 2015 17:19:28 BST |  | No OpenCL library found
Thu 10 Sep 2015 17:19:28 BST |  | Host name: ColinsCorner
Thu 10 Sep 2015 17:19:28 BST |  | Processor: 2 AuthenticAMD AMD Athlon(tm) 64 X2 Dual Core Processor 5000+ [Family 15 Model 107 Stepping 2]
Thu 10 Sep 2015 17:19:28 BST |  | Processor features: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt rdtscp lm 3dnowext 3dnow rep_good nopl extd_apicid pni cx16 lahf_lm cmp_legacy svm extapic cr8_legacy 3dnowprefetch lbrv vmmcall
Thu 10 Sep 2015 17:19:28 BST |  | OS: Linux: 3.16.0-38-generic
Thu 10 Sep 2015 17:19:28 BST |  | Memory: 3.86 GB physical, 1.91 GB virtual
Thu 10 Sep 2015 17:19:28 BST |  | Disk: 69.74 GB total, 59.13 GB free
Thu 10 Sep 2015 17:19:28 BST |  | Local time is UTC +1 hours
Thu 10 Sep 2015 17:19:28 BST |  | Config: use all coprocessors
Thu 10 Sep 2015 17:19:28 BST |  | Config: GUI RPCs allowed from:
Thu 10 Sep 2015 17:19:28 BST | Einstein@Home | URL http://einstein.phys.uwm.edu/; Computer ID 12029403; resource share 101

I can see libOpenCL.so and libOpenCL.so.1 on /usr/lib32/
I have also checked this is in LD_LIBRARY_PATH :
echo $LD_LIBRARY_PATH
/opt/AMDAPPSDK-3.0/lib/x86_64/:/usr/lib32

and have added the following to my .bashrc file :
# for BOINC Einstein GPU to find OpenCL
export LD_LIBRARY_PATH="/opt/AMDAPPSDK-3.0/lib/x86_64/:/usr/lib32"

but BOINC refuses to see that the OpenCL library is there. I even tried copying libOpenCL.so to the AMDAPPSDK-3.0 library as well, but it still cant find it. Where is BOINC looking, exactly? I notice there is a line in the output saying Libraries: libcurl/7.35.0 OpenSSL/1.0.1f zlib/1.2.8 libidn/1.28 librtmp/2.3 - yet when I search, for example, for the first one (libcurl), it is ME who can't find it! How can it search libraries that do not exist, yet skip ones that do?
I just wondered if anyone has successfully got a Radeon card working for Einstein under a Linux OS, or am I wasting my time here? It seems so close, just a silly search library pointer to get right perhaps, but where?

I believe your problem is with this line:
Thu 10 Sep 2015 17:19:28 BST | | NVIDIA drivers present but no GPUs found

Normally I see "No GPUs found" in Boinc Manager when the driver is the problem.

I am running a CAL AMD Radeon HD 7850/7870 series (Pitcairn) (2048MB) driver: 1.4.1848 on Ubuntu 14 LTS. I am not familiar with Mint but would suggest that you try to install the drivers from the MINT software repository. First remove what you have installed from the AMD website.

Launch Mint's equivalent of "Software Center/manager" and look for:

1. ATI binary X.Org driver - install it.

2. fglrx-dev - install it (other prerequisites will install)

3. reboot

4. launch BOINC and see if it "sees" your gpu. It might have to download GPU work so give it some time and be sure that it is configured to run GPU tasks.

This is what I had to do recently on an ubuntu box after an update. For some reason the update blew away my drivers/config stuff and I was forced to reinstall. Better to stay with the distro's drivers. Makes for easier updates.

Mint's naming convention might be different from what I list above in steps 1 and 2 so look before uninstalling what you have already done.

KarmannGaz
KarmannGaz
Joined: 25 Mar 09
Posts: 10
Credit: 17839880
RAC: 1758

Thanks for the responses,

Thanks for the responses, I'll have a careful read through and try to understand it all then have a go at the suggestions and see what happens. It'll probably take me a couple of days but I'll post back with the results.

Yes, it is a 64 bit system, I originally had the 64 bit lib but added lib32 after reading something else hinting it might be a 32/64 bit compatibility error. Made no difference, so I'll take that off again too.

clinfo
Number of platforms:                             1
  Platform Profile:                              FULL_PROFILE
  Platform Version:                              OpenCL 2.0 AMD-APP (1729.3)
  Platform Name:                                 AMD Accelerated Parallel Processing
  Platform Vendor:                               Advanced Micro Devices, Inc.
  Platform Extensions:                           cl_khr_icd cl_amd_event_callback cl_amd_offline_devices 

Platform Name: AMD Accelerated Parallel Processing
Number of devices: 2
Device Type: CL_DEVICE_TYPE_GPU
Vendor ID: 1002h
Board name: AMD Radeon HD 6670
Device Topology: PCI
etc.

and my driver is fglrx-updates at the moment.

The NVIDIA drivers got added by mistake, I'll try remove those too! That'll all keep me busy for a while anyway. Thanks again for the suggestions, at least I know there's light at the end of the tunnel now. Cheers!

AgentB
AgentB
Joined: 17 Mar 12
Posts: 915
Credit: 513211304
RAC: 0

RE: I am running a CAL AMD

Quote:

I am running a CAL AMD Radeon HD 7850/7870 series (Pitcairn) (2048MB) driver: 1.4.1848 on Ubuntu 14 LTS.

@robl What does boinc report for OpenCL (for you) ?

I see

OpenCL: AMD/ATI GPU 0: Tahiti (driver version 1702.3 (VM), device version OpenCL 1.2 AMD-APP (1702.3) ...


Quote:

For some reason the update blew away my drivers/config stuff and I was forced to reinstall.


ditto^3

Quote:

Better to stay with the distro's drivers. Makes for easier updates.

and the occasional re-install. :P that said, i am a fond follower of the Ubuntu boinc repo.

Gary Roberts
Gary Roberts
Moderator
Joined: 9 Feb 05
Posts: 5872
Credit: 117584093180
RAC: 35197008

RE: ... and my driver is

Quote:
... and my driver is fglrx-updates at the moment.


I'm running a lot of machines, many with both AMD and nvidia GPUs on 64bit PCLinuxOS. The problem you are seeing is probably being caused by BOINC looking for (precisely) libOpenCL.so in /usr/lib64 whilst your lib is somewhere else, perhaps /usr/lib64/fglrx-updates/libOpenCl.so.1 or somesuch.

For me, when a new fglrx driver is provided by my distro, it's always in /usr/lib64/fglrx-current/libOpenCL.so.1. To allow BOINC (I'm using 7.2.42 from berkeley, not from a repo) to find the libs and so 'detect' the AMD GPU, all I do (as root from /usr/lib64) is :-

# ln -s fglrx-current/libOpenCl.so.1 libOpenCL.so Just adjust the command as needed for correct paths/names.

As mentioned by AgentB you don't need the SDK. For my distro, the driver and the OpenCL libs are in separate packages and only the driver is installed by default. It's an extremely simple matter for me to install the libs using synaptic which is the standard package management system for PCLinuxOS. I don't know anything about Ubuntu or Mint so you'll need to check if the libs are automatically installed or not. Another thing to be aware of is whether the package maintainers for your distro modify BOINC in anyway to have the client look for the libs somewhere else. My distro doesn't package BOINC any more but I'm fine with the berkeley version which has the advantage for me of not having to wait for package maintainers if I want to test an alpha version - not that I'm adventurous enough to do that very often :-).

Cheers,
Gary.

Anonymous

RE: @robl What does boinc

Quote:

@robl What does boinc report for OpenCL (for you) ?

I see

OpenCL: AMD/ATI GPU 0: Tahiti (driver version 1702.3 (VM), device version OpenCL 1.2 AMD-APP (1702.3) ...

I am showing:
OpenCL: AMD/ATI GPU 0: AMD Radeon HD 7850/7870 series (Pitcairn) (driver version 1729.3 (VM), device version OpenCL 1.2 AMD-APP (1729.3), 2048MB, 1880MB available, 6720 GFLOPS peak)

[EDIT] and

 OpenCL CPU: Intel(R) Core(TM) i7-4770 CPU @ 3.40GHz (OpenCL driver vendor: Advanced Micro Devices, Inc., driver version 1729.3 (sse2,avx), device version OpenCL 1.2 AMD-APP (1729.3))

[EDIT] I am NOT running my distro's version on BOINC. I have downloaded the Berkeley Version.

KarmannGaz
KarmannGaz
Joined: 25 Mar 09
Posts: 10
Credit: 17839880
RAC: 1758

Woo-hoo, it works! :-) I

Woo-hoo, it works! :-)

I tried removing the NVIDIA bits first (using Mint's Software Manager). Apart from now reporting No NVIDIA libraries found, no difference.

Then I got it to install fglrx-amdcccle, which said it would remove fglrx-updates and fglrx-updates-core at the same time. Sounded a bit worrying, but I let it go ahead, then rebooted. Twice actually, the first reboot just left me with a black screen for some reason, but it worked ok the second time and started up normally. Still got the No OpenCL libraries found message though.

Finally, I had a look in /usr/lib (which I think is Mint's equivalent to what Gary Roberts described as /usr/lib64 in his comments above, as I don't have that library) - it had libOpenCL.so.1 in it, but not libOpenCL.so without the version number suffix. I've seen this mentioned before as a potential problem, as BOINC may be looking for the filename without the suffix, but hadn't worked out where exactly it would reside on my Mint distro. So, I did a sudo cp rather than a ln -s, to create a complete copy in there without the suffix, rather than just a link to it, as something else I read said a link might not be enough and it needs an actual copy (may have got the wrong end of the stick there, but I have a big hard drive and thought I'd just duplicate it to save another restart if the link didn't work)... restarted the boinc-client, and it found the OpenCL libraries at last! I let Einstein download some GPU tasks, and it's been ticking away for the last few hours without any problems. The first one has completed ok and is awaiting validation.

I can't tell you how happy I am to have got to the bottom of this at last! Thanks for the hints and suggestions all.

Cheers,
Gary.

AgentB
AgentB
Joined: 17 Mar 12
Posts: 915
Credit: 513211304
RAC: 0

RE: Woo-hoo, it works!

Quote:
Woo-hoo, it works! :-)


good news, keep an eye on temps and gpu load. You can now tune E@H to find what works best.

I tend to run one GPU application to find a base line, and then run the GPUs on that app at x2, x3 and x4. Then add cpu work if there is processing power left over.

You should see the RAC pick up.

Gary Roberts
Gary Roberts
Moderator
Joined: 9 Feb 05
Posts: 5872
Credit: 117584093180
RAC: 35197008

RE: Woo-hoo, it works!

Quote:
Woo-hoo, it works! :-)


Congrats on getting things working!! :-).

Quote:
Finally, I had a look in /usr/lib (which I think is Mint's equivalent to what Gary Roberts described as /usr/lib64...


In the old days before 64bit OSes, the /lib and /usr/lib directories would be where to look for libs. These days, some distros separate 32bit and 64bit libs into separate directories like /usr/lib (for 32bit) and /usr/lib64 (for 64bit). My distro has both and both have different versions of libOpenCL. In other words, even though the OS is 64bit, if I happened to run a 32bit app that required OpenCL support, I'm guessing that that the app would look in /usr/lib where I have a corresponding symlink to the 32bit version. You mentioned 64bit so I just quoted where I thought the 64bit libs might be. I did say to adjust paths/names as appropriate.

Quote:
So, I did a sudo cp rather than a ln -s, to create a complete copy in there without the suffix, rather than just a link to it ...


The symlink is by far the better way to do it and not at all for disk space reasons. When the next version of the driver is released, you might want to install it. If so, the libOpenCL.so.1 will be replaced, but not your copy of it under a different name. BOINC will start up and still be happy because it will find the old one. You'd better remember to delete the old one if you ever update the driver. If you use a symlink, you won't have to worry about remembering - it will be pointing to the new version, unless the new version is no longer called libOpenCL.so.1. In this case BOINC will alert you with the 'no usable GPUs' message, rather than use the wrong version of the lib, with probably disastrous consequences :-).

Quote:
... something else I read said a link might not be enough ...


For this function, symlinks are perfect. Have a look through your libs sometime and observe how commonly they are used to have a short name point to a much more complex one.

Cheers,
Gary.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.