centos7.2自带的php5.4升级为5.6
参考:http://jingyan.baidu.com/article/380abd0a1f176c1d91192c4b.html
今天在新购的阿里云上部署个phpmyadmin,结果显示了个如下信息:
PHP 5.5+ is required.
Currently installed version is: 5.4.16
系统是centos7.2,phpmyadmin的版本是4.6.5.2最新,降版本的妥协方法不是自己的性格,在参考一番资料后部署正常,记录如下。进入终端后查看php版本:php -v
输出可能如下:
PHP 5.4.35 (cli) (built: Nov 14 2014 07:04:10) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2015 Zend Technologies with Zend OPcache v7.0.4-dev, Copyright (c) 1999-2015, by Zend Technologies
- 执行下面的命令升级软件仓库
rpm -Uvh https://mirror.webtatic.com/yum/el7/epel-release.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
- 执行下面的命令删除php
yum remove php-common
然后像安装那样问你是否继续的,输入yes即可
- 安装php 5.6版本(php56w-devel这个不是必需的)
yum install -y php56w php56w-opcache php56w-xml php56w-mcrypt php56w-gd php56w-devel php56w-mysql php56w-intl php56w-mbstring
- 重启httpd
service httpd restart
查看最新的版本
php -v
现在应该是5.6了!
Php网站运行不正常,发现上面遗漏
yum install -y php56w-fpm
service php-fpm start
service nginx restart
Ok, 网站正常运行起来啦
centos7.2自带的php5.4升级为5.6的更多相关文章
- Linux版 php5.4 升级php7
开篇 本操作是在VirtualBox里面进行的,所以开篇先说下,本地如何操作VB里面的Linux 1.secureCRT登陆虚拟机ubuntu 直接连接虚拟机的ip (ifconfig)会提示拒绝访问 ...
- centos7下只需两个命令升级php版本
我的php5.4 升级到5.6 sudo yum clean allsudo yum install -y php56w Resolving Dependencies --> Running t ...
- CentOS7中_带sqlite3_CGO的golang程序_交叉编译到arm中
CentOS7中_带sqlite3_CGO的golang程序_交叉编译到arm中 转载注明来源: 本文链接 来自osnosn的博客,写于 2019-10-28. 编写了个golang程序,用到了这个C ...
- centos7升级自带的php5.4版本到php5.6
history命令历史 8 yum provides php #自带的只有5.4版本 9 rpm -Uvh https://mirror.webtatic.com/yum/el7/epel-relea ...
- Linux PHP5.3升级PHP5.5.33 (CentOS)
由于要使用了laravel5.1,php要升级到5.5以上.具体环境是Aliyun Cent OS 7.0.由于阿里的yum源lastest只有5.4,laravel5.1必须php5.5,加了几个网 ...
- CentOS7安装Nginx-1.9.9+PHP5.6
linux系统CentOS7 Nginx 下载地址http://nginx.org/en/download.html wget下载路径http://nginx.org/download/nginx-1 ...
- php5.3升级到5.5
在网站中发布中: / 开启调试模式 建议开发阶段开启 部署阶段注释或者设为falsedefine('APP_DEBUG',true); true没问题,改为:false就报错 报错如下: PHP Fa ...
- centos7 下安装Apache2+MariaDB+PHP5过程详解
1.启用Apache2 Centos7默认已经安装httpd服务,只是没有启动.如果你需要全新安装,可以 yum install -y httpd 启动服务:systemctl start httpd ...
- centos6.8上PHP5.3升级到PHP5.4及更高版本方法
执行命令下载.安装yum源,当前是针对Centos6并且64位版本的源: [root@T_249 yum.repos.d]# rpm -ivh http://dl.fedoraproject.org/ ...
随机推荐
- OC基础面试题
1.iOS中delegate代理对象使用weak 之前不停的使用assign,今天在调试一段的时候,发现使用assgin的时候程序会crash,报错EXC_BAD_ACCESS, 经过一番研讨,发明如 ...
- jquery如何获取url中问号后面的数值
假如路径是这样的:www.domain.com/list/?menu=1 var locationUrl = location.search.substring(6); switch(location ...
- android判断文件是否是图片文件的方法
判断一个文件是否是图片文件的方法,采用BitmapFactory去decode然后根据返回的Options参数来确定: public static boolean isImageFile(String ...
- Github朝花夕拾
删除fork的项目 下载指定revision的repository 通过git log查看提交历史,最好是GUI查看 然后执行命令git reset –hard <sha1> 同步到最 ...
- cuckoo相关
Q1:pefile is out of date 现象:ERROR: Your version of pefile is out of date. Please update to the late ...
- Finish and error to: Error Domain=NSURLErrorDomain Code=-1001 "请求超时。
错误显示:Finish and error to: Error Domain=NSURLErrorDomain Code=-1001 "请求超时." UserInfo={NSUnd ...
- angularjs uigrid 中celltemplate的写浮动框
columnDefs: [ {field: 'collegename', enableFiltering: false ,width:"12%",displayName:" ...
- Java线程的几种状态
一. 线程状态类型1. 新建状态(New):新创建了一个线程对象.2. 就绪状态(Runnable):线程对象创建后,其他线程调用了该对象的start()方法.该状态的线程位于可运行线程池中,变得可运 ...
- L3-002. 堆栈
L3-002. 堆栈 题目链接:https://www.patest.cn/contests/gplt/L3-002 线段树 线段树的数据修改和查询都是O(lgn)的,此题只需维护各个区间内的数的个数 ...
- hibernate与spring整合实现transaction
实现transaction时出现了大大小小的问题,这里会一一详解. 先贴出applicationContext.xml <?xml version="1.0" encodin ...