Linux Centos 6.2 装好PHP启动Apache错误libmysqlclient.so.18:
Linux Centos 6.2 装好PHP启动Apache错误libmysqlclient.so.18:
今天在装了一个LAMP的环境在最后装好PHP后重启apace服务报错如下
[root@localhost php-5.2.17]# /etc/init.d/httpd restart
httpd: Syntax error on line 53 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/modules/libphp5.so into server: libmysqlclient.so.18: cannot open shared object file: No such fileor directory
主要问题是找不到libmysqlclient.so.18这个库很费解原来我的服务器X64的系统默认的库路径在 /usr/lib64需要建立一个软连接路径
X64操作系统如下
ln -s /usr/local/mysql/lib/libmysqlclient.so.18 /usr/lib64
x86 32位系统如下
ln -s /usr/local/mysql/lib/libmysqlclient.so.18 /usr/lib