场景:某网站由于程序的问题,会造成httpd进程个数爆增,w显示400左右,机器负载很高,重启后httpd正常!
由于用户无法将程序中的bug找出来,只好想着先升级试试看
下面是从php5.2.15----->php-5.3.25
和
httpd2.2.15----->http2.2.24,版本升级一般都要使用原来的编译参数和配置文件,擅自删除编译参数和配置文件,会导致各种各样的问题,系统升级和新建一个系统不相同!
1:安装完httpd2.2.24后,启动报错 libiconv.so.2: cannot open shared object file
解决方法:
echo “/usr/local/lib” >>/etc/ld.so.conf
如果是64的系统,则如果是64位的则加/usr/local/lib64
ldconfig -v
然后即可正常启动!
2:
undefined reference to `libiconv_close'collect2: ld returned 1 exit statusmake
./configure ............ ##configure是正常的 ,但make时出错,报错见上方!
解决方法:
vi Makefile找到下面这行:EXTRA_LIBS = -lcrypt ...在最后添加-liconv保存后make即可通过;
3
:make: *** [ext/mysqli/mysqli.lo] Error 1
3.1:/usr/local/mysql/include/mysql/m_string.h:285:26:error: mysql/plugin.h: No such file or directory
解决方法:
echo “/usr/local/mysql/lib/mysql”>> /etc/ld.so.conf
ldconfig -v
ln -s /usr/local/mysql/lib/mysql /usr/lib/mysql
ln -s /usr/local/mysql/include/mysql /usr/include/mysql
3.2:/usr/local/mysql/include/mysql/my_sys.h:1027:27:error: mysql/psi/psi.h: No such file or directory
解决方法:
mkdir -p /usr/local/mysql/include/mysql/psi
cp psi.h psi
目录结构如下:
4:/usr/local/php/bin/phpize 时出错 : warning: AC_CACHE_VAL(pdo_inc_path, ...): suspicious cache-id, must
这个问题仅仅是一个warning,不碍事的!可以不解决的!
有文章说autoconf的版本的问题, 我也没去试!
5:
httpd: Syntax error on line 53 of /usr/local/apache/conf/httpd.conf: Cannot load /usr/local/apache/modules/libphp5.so into server: /usr/local/apache/modules/libphp5.so: cannot restore segment prot after reloc: Permission denied
解决方法:
vi /etc/selinux/config 将SELINUX=enforcing 改成SELINUX=disabled
或setenforce 0 也可以
阅读(1339) | 评论(0) | 转发(0) |