1.第一步就是看linu是否安装了mysql,经过rpm -qa|grep mysql查看到centos下安装mysql
如果有安装就卸载以前低版本
rpm -qa|grep mysql
rpm -e --nodeps 跟mysql版本
配置下面两个源
rpm -Uvh http://mirror.steadfast.net/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
安装mysql
yum --enablerepo=remi,remi-test list mysql mysql-server
yum --enablerepo=remi,remi-test install mysql mysql-server
启动mysql
/etc/init.d/mysqld start
设置开机启动
chkconfig --levels 345 mysqld on
重置密码
/usr/bin/mysql_secure_installation
稍后自己选择并设定密码
2.PHP
Yum安装php
rpm -Uvh http://repo.webtatic.com/yum/el6/latest.rpm
yum install php70w php70w-opcache
改成56就是php5.6.30