Admin panel shows error: "error while loading shared libraries: <some.file.name.so>: cannot open shared object file: No such file or directory"

Refers to:

  • Plesk 12.5 for Linux
  • Plesk 11.5 for Linux
  • Plesk 12.0 for Linux

Created:

2016-11-16 13:16:02 UTC

Modified:

2017-01-18 16:14:50 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Admin panel shows error: "error while loading shared libraries: <some.file.name.so>: cannot open shared object file: No such file or directory"

Symptoms

The following error appears in the Plesk upon logging in:

ERROR: PleskUtilException

Fatal error: plesk::Exc<&(plesk::ExecCmd::Failed(bool))>(Execution of /usr/sbin/postconf -d -h mail_version failed with return code 127.
Stderr is
/usr/sbin/postconf: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No such file or directory
)

'/usr/lib64/mysql/libmysqlclient.so.16' exists, however 'ldd' command indicates that dynamic library is not found:

[root@ ~]# ldd /usr/sbin/postconf
linux-vdso.so.1 => (0x00007fff6cdfe000)
libsasl2.so.2 => /usr/lib64/libsasl2.so.2 (0x00007fdbb1e9d000)
libpcre.so.0 => /lib64/libpcre.so.0 (0x00007fdbb1c71000)
libmysqlclient.so.16 => not found

Or

/opt/psa/admin/bin/webmailmng: error while loading shared libraries: libmariadb.so.1: cannot open shared object file: No such file or directory

Cause

Dynamic library is being searched in the '/usr/lib64' or '/usr/lib' folders, but subfolders not mentioned in /etc/ld.so.conf are ignored.

Resolution

Find the folder where shared libraries are located, for example, /usr/lib64/mysql or /usr/lib64/sw

~# echo '/usr/lib64/mysql' >> /etc/ld.so.conf.d/mysqlclient.conf
~# echo '/usr/lib64/sw' >> /etc/ld.so.conf.d/sw_libs.conf
~# echo '/usr/lib/sw' >> /etc/ld.so.conf.d/sw_libs.conf
~# echo '/usr/lib/libboost-plesk-1.54.0/' >> /etc/ld.so.conf.d/sw_libs.conf
~# ldconfig -v
Have more questions? Submit a request
Please sign in to leave a comment.