php5.3升级脚本
在lanmp/wdcp/wdOS的当前版本中,默认的php都是用到5.2.17的版本如需要升级到php5.3的,可使用如下脚本升级
([color=#ff0000]注:此升级无安全漏洞等原因,只为某些追求高版本或应用需求需要高版本,对于无这个必要的同学,可不用升级[/color])
wget [url=http://down.wdlinux.cn/in/php_up53.sh]http://down.wdlinux.cn/in/php_up53.sh[/url]
sh php_up53.sh
看到"php update is OK"提示
表示,顺利完成
如有错误或不行,将问题反馈上来
备注:
该升级只是升级PHP的版本,相应的zend,eaccelerator没有升级
且zend opt从php5.3开始已不再支持,也就是说有用到zend opt的,就不要升级了,否则只会瞎折腾
不过可以使用Zend Guard Loader
安装
wget [url=http://down.wdlinux.cn/in/ZendGL_ins.sh]http://down.wdlinux.cn/in/ZendGL_ins.sh[/url]
sh ZendGL_ins.sh
eaccelerator也只要最新的0.9.6.1版本
安装
wget [url=http://down.wdlinux.cn/in/eac0961_ins.sh]http://down.wdlinux.cn/in/eac0961_ins.sh[/url]
sh eac0961_ins.sh wdcp_v2.5(20120929)升级PHP 5.3 先后出现如下问题及解决方式:
1、configure: error: xml2-config not found. Please check your libxml2 installation
# yum install libxml2
# yum install libxml2-devel
2、Checking for pkg-config… /usr/bin/pkg-config
configure: error: Cannot find OpenSSL’s <evp.h>
# yum install openssl openssl-devel
3、checking if we should use cURL for url streams... no
checking for cURL in default path... not found
configure: error: Please reinstall the libcurl distribution -
easy.h should be in <curl-dir>/include/curl/
# yum -y install curl-devel
4、configure: error: jpeglib.h not found.
make: *** No targets specified and no makefile found. Stop.
# yum install libjpeg.x86_64 libpng.x86_64 freetype.x86_64 libjpeg-devel.x86_64 libpng-devel.x86_64 freetype-
devel.x86_64 -y
5、configure: error: mcrypt.h not found. Please reinstall libmcrypt.
# yum install libmcrypt libmcrypt-devel 升级后探针显示版本为5.3.17,但是探针的
上传文件最大限制(upload_max_filesize)
脚本占用最大内存(memory_limit)
POST方法提交最大限制(post_max_size)
脚本超时时间(max_execution_time)
……等好多项都没有值,打红叉了,是不是不支持了? 探针里打红叉?
这些是PHP里的基本功能,肯定要支持的 确实如同3楼说的,很多参数都是叉.... 而且我的wordpress出现502 gateway错误,已经重装系统了。。 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14213&ptid=3737]5#[/url] [i]hoteri[/i] [/b]
哪里显示叉?探针里还是后台里? [i=s] 本帖最后由 HookOS 于 2012-10-8 19:20 编辑 [/i]
wget [url]http://down.wdlinux.cn/in/eac0961_ins.sh[/url]
sh eac0961_ins.sh
管理员,运行这个sh安装后,如何保证开启呢
安装后重启vps探针里的这个组建还是叉叉,DZ论坛系统也显示这个组建的php不支持
补充:
只是想用到dz2.5里的内存优化功能
内存接口 PHP 扩展环境 Config 设置 内存清理
Redis 不支持 打开 --
memcache 不支持 关闭 --
APC 不支持 打开 --
Xcache 不支持 打开 --
eAccelerator 不支持 打开 --
wincache 不支持 打开 --
都显示不支持,我之前也安装过memcache,今天安装eAccelerator 也不行,探针里都是叉叉 [attach]2023[/attach]
[attach]2024[/attach] DZ不支持高版本的EAC
你可以用回5.2版的PHP就可以 悲催了,dz要求用php5.3的,怎么到这里这个组建不支持了
还有我按照论坛里的步骤安装了memcache怎么也用不起来啊,求管理员指点 老大,我先升级了mysql,现在升级用这里的脚本升级php不行了
目前是从该版本起,继续提供RPM包的安装,方便,快速,5分钟就可安装完
wget [url]http://down.wdlinux.cn/in/lanmp_wdcp_24_in.sh[/url]
sh lanmp_wdcp_24_in.sh
升级mysql的代码
wget [url]http://down.wdlinux.cn/in/mysql_up55.sh[/url]
sh mysql_up55.sh
升级php的代码
wget [url]http://down.wdlinux.cn/in/php_up53.sh[/url]
sh php_up53.sh
显示信息
php-5.3.17/buildconf
php-5.3.17/README.SUBMITTING_PATCH
php-5.3.17/pear/
php-5.3.17/pear/Makefile.frag
php-5.3.17/pear/install-pear-nozlib.phar
php-5.3.17/pear/install-pear.txt
php-5.3.17/pear/fetch.php
php-5.3.17/LICENSE
php-5.3.17/README.input_filter
php is not update
[b]直接用[url]http://www.wdlinux.cn/bbs/thread-1494-1-1.html[/url]这里的升级方式,make时提示出错,错误信息如下;[/b]
/tmp/php-5.3.17/sapi/cli/php: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory
make: *** [ext/phar/phar.php] Error 127
看了网上的部分教程,还是没解决问题,求救啊!!!! [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14241&ptid=3737]11#[/url] [i]HookOS[/i] [/b]
不是到这里不支持是DZ里不支持高版本的EAC,只支持0.9.5.3
论坛有过相关的说明
之前的DZ是这样的,不确定现在新的是否有做过调整
而我在测试PHP5.3时,在编译EAC 0.9.5.3时有错误,但0.9.6.1是正常
所以我觉得可能是PHP5.3不支持EAC 0.9.5.3了
memcached用不起来,有什么错误提示或信息? [i=s] 本帖最后由 夏筱羽 于 2012-10-8 23:21 编辑 [/i]
終於等到了,趁現在GOOGLE ADWORDS匯款還沒入帳,趕緊升級當白老鼠= =
編譯的可以直接用這個升級嗎? [i=s] 本帖最后由 夏筱羽 于 2012-10-8 23:40 编辑 [/i]
報告老大php.ini出錯了喔~
php.ini全空了
只剩下如下內容[code][Zend]
zend_extension_manager.optimizer=/www/wdlinux/Zend/lib/Optimizer-3.3.3
zend_extension_manager.optimizer_ts=/www/wdlinux/Zend/lib/Optimizer_TS-3.3.3
zend_optimizer.version=3.3.3
zend_optimizer.enable_loader = 1
zend_optimizer.optimization_level=1023
[eaccelerator]
extension_dir="/www/wdlinux/apache_php/lib/php/extensions/no-debug-non-zts-20090626/"
extension="eaccelerator.so"
eaccelerator.shm_size="8"
eaccelerator.cache_dir="/www/wdlinux/eaccelerator_cache"
eaccelerator.enable="1"
eaccelerator.optimizer="1"
eaccelerator.check_mtime="1"
eaccelerator.debug="0"
eaccelerator.filter=""
eaccelerator.shm_max="0"
eaccelerator.shm_ttl="3600"
eaccelerator.shm_prune_period="3600"
eaccelerator.shm_only="0"
eaccelerator.compress="1"
eaccelerator.compress_level="9"[/code] [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14244&ptid=3737]12#[/url] [i]ngibo1278[/i] [/b]
重起下,再升级PHP试下 [i=s] 本帖最后由 夏筱羽 于 2012-10-9 00:37 编辑 [/i]
升級5.3 php.ini被清空了,先拿5.2.17的php.ini來頂著先
memcache 後台有啟用 phpinfo 確實顯示不支持,還在查原因當中。 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14225&ptid=3737]7#[/url] [i]admin[/i] [/b]
探针里 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14259&ptid=3737]17#[/url] [i]夏筱羽[/i] [/b]
5.2的php.ini可能不同,在源码目录里找下php.ini-product就可以了
memcache看下是不是PHP扩展支持没安装好 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14260&ptid=3737]18#[/url] [i]hoteri[/i] [/b]
奇怪,我这边测试的都可以呀 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14267&ptid=3737]20#[/url] [i]admin[/i] [/b]
等下我用全新安装一次试验 谢谢老大,重启了服务器,按照教程升级了MYSQL、PHP,显示升级成功,在phpadmin中查看,里面显示mysql版本已经正确;只是探针、端口测试,发现php版本还是原来的老样子,显示的是php 5.2.17P1,同时在WDCP面板后台修改php设置,发现php.ini文件不存在;通过端口测试IP地址,返回的信息同样是php 5.2.17P1
网页返回HEAD信息如下
Server: nginx/1.0.15
Date: Tue, 09 Oct 2012 05:22:39 GMT
Content-Type: text/html
Connection: keep-alive
Vary: Accept-Encoding
X-Powered-By: PHP/5.2.17p1
Content-Length: 2597
重启nginx的时候发现
Starting nginx: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use)
我用的是centos 6.2,使用lanmp,这是升级成功了?还是要修改下什么设置?另外,直接把php压缩包的php.ini文件复制WDCP面板设置php.ini文件的位置行不行? 怎么我的php版本升级后重启了两次,还是5.2.17p1呢。这是怎么回事,
还有就是Zend Guard Loader安装时,下载不了.rmp的一个什么编译包。 开始升级2.5到后 接着php版本 升级后php.ini也不在了,这是搞什么。php版本还是显示php5.2.17p1
网站还能运行。系统切换,检测不到nginx或php-cgi,这是怎么了,只能用apache了。 [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14283&ptid=3737]22#[/url] [i]ngibo1278[/i] [/b]
如果php.ini 文件为空的话,从PHP的源码目录里拷一份即可,
如cd php-5.3.17
cp php.ini-production /www/wdlinux/apache_php/etc/php.ini
cp php.ini-production /www/wdlinux/nginx_php/etc/php.ini [b]回复 [url=http://www.wdlinux.cn/bbs/redirect.php?goto=findpost&pid=14290&ptid=3737]24#[/url] [i]chen7413[/i] [/b]
还是显示php5.2.17的话,是没升级成功,可以把相关提示信息贴上来 [attach]2027[/attach]
[b]貌似这个升级的程序真的有问题,上图显示php is update,实际上不管是探针,还是直接去/www/wdlinux/目录查看,都没有找到对应的文件,依然是php 5.2.17P1[/b]
apache环境下的:libmysqlclient.so.18: cannot open shared object file: No such file or directory
make: *** [ext/phar/phar.php] Error 127
另外,nginx环境下的php貌似压根没安装过,似乎是读写失败什么的
[b]我的运行环境:centos 6.2 64位 通过rpm快速安装的lanmp组合,先升级的mysql,随后升级的php[/b]
升级mysql的方法
wget [url]http://down.wdlinux.cn/in/mysql_up55.sh[/url]
sh mysql_up55.sh
升级php的方法
wget [url=http://down.wdlinux.cn/in/php_up53.sh]http://down.wdlinux.cn/in/php_up53.sh[/url]
sh php_up53.sh 是因为libmysqlclient.so这个没有编译成功,但脚本又没判断,所以这样
已经做过调整
mysql是否正常?有没重起过
如果没有重起过,重起下,再次安装试试
重新下载php_up53.sh,下载前先删php_up53.sh 折腾了两个夜晚,终于成功了,谢谢老大的耐心指导!
正确的升级流程是:先安装WDCP面板,随后安装cmake,一定要安装这个文件,随后升级php,随后升级相关的php缓存插件,随后升级mysql,这样才完全升级成功。之前出错可能是cmake文件的版本问题,开始用的高版本,后来换到低版本,再先升级php,这样才行;先升级mysql,后面安装php要调整很多地方。 wget [url=http://down.wdlinux.cn/in/ZendGL_ins.sh]http://down.wdlinux.cn/in/ZendGL_ins.sh[/url]
sh ZendGL_ins.sh
zend 安装不成功