阿里云的主机宝 php5.2 出现 502错误原因总结

  • sqlite 3  可能导致 php 5.2 版本出现 502错误 。解决方法:把/usr/lib/libsqlite-3 移走
  • openssl问题可能导致,解决方法,安装openssl-devel 然后重新编译 php ,附录为主机宝官方给的ssl方面的解决方法(未实验, 可能X86_64位需要修改)

============1======================
wget dl2.admin5.com/php/curl-7.37.1.tar.gz
tar zxvf curl-7.37.1.tar.gz
cd curl-7.37.1
./configure –prefix=/usr/local/curl
make && make install
cd ..
rm -rf curl-7.37.1*
============2======================
cd /a/apps/
wget dl2.admin5.com/php/php-5.2.17-have.tar.gz
rm -rf php-5.2.17
tar zxvf php-5.2.17-have.tar.gz
rm -rf php-5.2.17-have.tar.gz

===========3(镜像1.0)==============
cd /root
wget dl2.admin5.com/php/openssl-1.0.1h.tar.gz
tar zxvf openssl-1.0.1h.tar.gz
cd openssl-1.0.1h
./config –prefix=/usr/local/ssl shared zlib
make && make install
mv /usr/bin/openssl /usr/bin/openssl.old
mv /usr/include/openssl /usr/include/openssl.old
ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl
ln -s /usr/local/ssl/include/openssl /usr/include/openssl
echo “/usr/local/ssl/lib” >> /etc/ld.so.conf
ldconfig -v
cd ..
rm -rf openssl-1.0.1h*
===========4=======================
killall -9 php-cgi
killall -9 php-cgi
service php-fpm start
service zadmin start

zhujibao

发表评论

电子邮件地址不会被公开。 必填项已用*标注