当前位置:Gxlcms > 数据库问题 > apache + php + mysql 安装出错

apache + php + mysql 安装出错

时间:2021-07-01 10:21:17 帮助过:1人阅读

.
The Apache error log may have more information.
apache2_reload: Your configuration is broken. Not restarting Apache 2
Setting up php5 (5.5.9+dfsg-1ubuntu4.11) ...

此时去 restart Apache,会出现如下错误:

root@ubuntu:/home/adu# /etc/init.d/apache2 restart
 * Restarting web server apache2                                                                                                                                                                                                      [fail]
 * The apache2 configtest failed.
Output of config test was:
apache2: Syntax error on line 140 of /etc/apache2/apache2.conf: Syntax error on line 1 of /etc/apache2/mods-enabled/php5.load: Cannot load /usr/lib/apache2/modules/libphp5.so into server: /usr/lib/apache2/modules/libphp5.so: symbol xmlOutputBufferGetSize, version LIBXML2_2.9.0 not defined in file libxml2.so.2 with link time reference
Action ‘configtest‘ failed.
The Apache error log may have more information.

以为是 libxml2.so.2 版本不对,跑去升级,还造成了其他错误。经过一下午的折腾和找资料,最后发现是由于 linux 版本混乱导致的。执行下面命令就可以了:

root@ubuntu:/usr/local/lib# rm /usr/local/lib/libxml2.so*

这期间还发生了一些其他错误,如
root@ubuntu:/usr/local/lib# sudo apt-get dist-upgrade     
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
156 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Do you want to continue? [Y/n] y
Setting up shared-mime-info (1.2-0ubuntu3) ...
update-mime-database.real: /usr/local/lib/libxml2.so.2: no version information available (required by update-mime-database.real)
Warning: program compiled against libxml 209 using older 207

也可以通过上述操作解决。

 

apache + php + mysql 安装出错

标签:

人气教程排行