You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I installed ArrayFire 3.9.0 for a user on our cluster. They encounter the following error:
In file src/api/unified/symbol_manager.cpp:250: Failed to load dynamic library. See http://www.arrayfire.com/docs/unifiedbackend.htm for instructions to set up environment for Unified backend.
0# 0x00002AF55D6B1716 in /cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/CUDA/gcc9/cuda12.2/arrayfire/3.9.0/lib/libaf.so.3
1# 0x00005556FB0F926B in target/release/examples/figure1b
2# 0x00005556FB0AA3D5 in target/release/examples/figure1b
3# 0x00005556FB0A9E43 in target/release/examples/figure1b
4# 0x00005556FB0A9E59 in target/release/examples/figure1b
5# 0x00005556FB10CF7E in target/release/examples/figure1b
6# 0x00005556FB0AA575 in target/release/examples/figure1b
7# __libc_start_main in /cvmfs/soft.computecanada.ca/gentoo/2020/lib64/libc.so.6
8# 0x00005556FB0A9D7A in target/release/examples/figure1b
', /home/brosnany/.cargo/git/checkouts/arrayfire-rust-78c6296114c4c65d/bd3be3e/src/core/error.rs:37:14
We have a number of CUDA libraries available, and all of the shared objects are properly found without LD_LIBRARY_PATH, through RPATH in the shared objects (see below).
if you want to avoid using LD_LIBRARY_PATH and you don't want to install ArrayFire in standard library locations you can add the path to ArrayFire libraries in /etc/ld.so.conf.d/arrayfire.conf and call sudo ldconfig. This will instruct the linker to search in those paths.
That is not possible either. There are multiple versions of the CUDA toolkit installed, and there is not a single one of them that is prioritized. Users load the ArrayFire module after loading a given version of the cuda toolkit, and the ArrayFire binaries are already aware of where to look for the libraries based on their embedded RPATH.
If the library somehow won't honour RPATH that is embedded in the shared objects, is there an ArrayFire-specific environment variable or other mechanism that can be used to tell it where to look ? No global mechanism will work on a cluster environment where we have multiple versions of everything.
Note that our linker already knows where to look (hence why the correct RPATH are set in the library's shared objects). Linkers use LIBRARY_PATH, NOTLD_LIBRARY_PATH which is meant for runtime, not compile time.
Do you know which library its failing on? One way to find out is calling your executable and setting the LD_DEBUG=libs environment variable. It will show you which paths are being checked and which library is failing.
I installed ArrayFire 3.9.0 for a user on our cluster. They encounter the following error:
We have a number of CUDA libraries available, and all of the shared objects are properly found without
LD_LIBRARY_PATH
, through RPATH in the shared objects (see below).Yet, the "unifiedbackend" complains about not finding libraries. The page pointed here http://www.arrayfire.com/docs/unifiedbackend.htm points to setting
LD_LIBRARY_PATH
, which will not happen because http://xahlee.info/UnixResource_dir/_/ldpath.htmlIs there any solution to make it work ?
The text was updated successfully, but these errors were encountered: