1. 首页安装Webtatic EL6 YUM源

    rpm -Uvh http://repo.webtatic.com/yum/el6/latest.rpm  
    2.停止web服务器
    service nginx stop
    或者
    service httpd stop
    3.删除当前的 php 安装 php5.4
    yum remove php*
    yum install php54w
    4.重启web服务器
    service php-fpm restart
    service nginx start
    或者
    service httpd restart
    5.查看php版本
    php -v
    PHP 5.4.33 (cli) (built: Sep 19 2014 19:58:27)
    Copyright (c) 1997-2014 The PHP Group
    Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies

转载自: http://zhidao.baidu.com/link?url=OmfoJw2ZFGV74FkbrkIQPQx-K2rM6-vJZXyVA1kmj7LB_7AKJIqSOiDNGXc72sJVxSGaR3Qs_XbFsRnVsJGj-NSDi4VE0tZuBeT4hNHJoI_