Rumah > Artikel > pembangunan bahagian belakang > CentOS65下升级php
最近在云服务器部署环境时,用的CentOS6.5的系统,默认是用的php.5.3.3,不过这个有点小低,就试着升级下。
以下方法来源于网络,经测试可用
1、移除之前安装的php相关文件
<span>yum remove php php</span><span>-</span><span>bcmath php</span><span>-</span><span>cli php</span><span>-</span><span>common php</span><span>-</span><span>devel php</span><span>-</span><span>fpm php</span><span>-</span><span>gd php</span><span>-</span><span>imap php</span><span>-</span><span>ldap php</span><span>-</span><span>mbstring php</span><span>-</span><span>mcrypt php</span><span>-</span><span>mysql php</span><span>-</span><span>odbc php</span><span>-</span><span>pdo php</span><span>-</span><span>pear php</span><span>-</span><span>pecl</span><span>-</span><span>igbinary php</span><span>-</span><span>xml php</span><span>-</span><span>xmlrpc</span>
2、安装rpm
<span>rpm </span><span>-</span><span>Uvh</span><span> http</span><span>:</span><span>//mirror.webtatic.com/yum/el6/latest.rpm</span>
3、安装php5.5
<pre class="brush:php;toolbar:false"><span>yum install php55w php55w</span><span>-</span><span>bcmath php55w</span><span>-</span><span>cli php55w</span><span>-</span><span>common php55w</span><span>-</span><span>devel php55w</span><span>-</span><span>fpm php55w</span><span>-</span><span>gd php55w</span><span>-</span><span>imap php55w</span><span>-</span><span>ldap php55w</span><span>-</span><span>mbstring php55w</span><span>-</span><span>mcrypt php55w</span><span>-</span><span>mysql php55w</span><span>-</span><span>odbc php55w</span><span>-</span><span>pdo php55w</span><span>-</span><span>pear php55w</span><span>-</span><span>pecl</span><span>-</span><span>igbinary php55w</span><span>-</span><span>xml php55w</span><span>-</span><span>xmlrpc php55w</span><span>-</span><span>opcache php55w</span><span>-</span><span>intl php55w</span><span>-</span><span>pecl</span><span>-</span><span>memcache</span>
以上就介绍了CentOS65下升级php,包括了方面的内容,希望对PHP教程有兴趣的朋友有所帮助。