Home >Backend Development >PHP Tutorial >php: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No

php: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOriginal
2016-06-23 13:49:291901browse

解决方法:

1、进入mysql安装目录查看,确认有libmysqlclient.so.16.0.0 文件, 于是需要在/usr/lib目录下建立一个软链接来指向libmysqlclient.so.16

2、在php lib目录下下建立个软链接:(格式为:ln -s mysql lib路径  php lib路径)

ln -s /home/openpf/app/mysql-5.1.56-2/lib/mysql/libmysqlclient.so.16  /home/openpf/app/php-5.3.3/lib/php/extensions/no-debug-non-zts-20090626/libmysqlclient.so



Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn