How to fix "error while loading shared libraries"?

Error


online2-wav-nnet3-latgen-faster: error while loading shared libraries: libcublas.so.10: cannot open shared object file: No such file or directory

ldd command is good at figuring out dependencies


$ ldd $(which online2-wav-nnet3-latgen-faster)
linux-vdso.so.1 (0x00007ffca4654000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f6508feb000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f6508dcc000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f6508a2e000)
libcuda.so.1 => /usr/lib/x86_64-linux-gnu/libcuda.so.1 (0x00007f650730c000)
libcublas.so.10 => not found
libcusparse.so.10 => not found
libcudart.so.10.2 => not found
libcurand.so.10 => /usr/local/cuda/lib64/libcurand.so.10 (0x00007f6501b7e000)
libcusolver.so.10 => not found
libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f65017f5000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f65015dd000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f65011ec000)
/lib64/ld-linux-x86-64.so.2 (0x00007f650d587000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f6500fe4000)

The correct fix is to reinstall the correct version of packages.  

------------------------------------------------------------------------------

The fix below is temporary and only works if no GPU's are used:

Put all asked files into a folder and add the folder to the path. I think it tricks the system that we have them. In reality we don't use them.

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/np/npovey/lib

Comments