Centos 6.5安装mysql 5.5

#列出安装的mysql 
rpm -qa | grep mysql
#centos6.5 basic server 版本 默认安装了mysql5.1,所以先卸载mysql5
yum -y remove mysql-libs-5.1* 


 1.安装service:

rpm -ivh MySQL-server-5.5.48-1.linux2.6.x86_64.rpm

Centos 6.5安装mysql 5.5

2:安装client:

rpm -ivh MySQL-client-5.5.48-1.linux2.6.x86_64.rpm

Centos 6.5安装mysql 5.5

3.启动服务and修改密码
service mysql start

/usr/bin/mysql_secure_installation

Centos 6.5安装mysql 5.5

Remove anonymous users?   删除匿名用户?
Disallow root login remotely? 禁止root远程登录?
Remove test database and access to it? 删除测试数据库并访问它?

Reload privilege tables now?  现在重新加载权限表?

Centos 6.5安装mysql 5.5

4.登录: 

startmysql -uroot -p123456

安装mysql方法,一定记得修改密码

所需mysql安装包下载地址:http://download.****.net/download/sq347216161/10271544

MySQL-5.5.48-1.linux2.6.x86_64.rpm-bundle.tar

解压出所需service以及client