CentOS 6.5/6.6 安裝(install)mysql 5.7 最完整版教程

Step1: 檢測系統是否自帶安裝mysqlhtml

# yum list installed | grep mysql

Step2: 刪除系統自帶的mysql及其依賴
命令:mysql

# yum -y remove mysql-libs.x86_64

Step3: 給CentOS添加rpm源,而且選擇較新的源
命令:linux

# wget dev.mysql.com/get/mysql-community-release-el6-5.noarch.rpm
# yum localinstall mysql-community-release-el6-5.noarch.rpm
# yum repolist all | grep mysql
# yum-config-manager --disable mysql55-community
# yum-config-manager --disable mysql56-community
# yum-config-manager --enable mysql57-community-dmr
# yum repolist enabled | grep mysql

Step4:安裝mysql 服務器
命令:sql

# yum install mysql-community-server

Step5: 啓動mysql
命令:centos

# service mysqld start

Step6: 查看mysql是否自啓動,而且設置開啓自啓動
命令:安全

# chkconfig --list | grep mysqld
# chkconfig mysqld on

Step7: mysql安全設置
命令:服務器

# mysql_secure_installation

參考相關文檔地址:
http://www.rackspace.com/know...
http://dev.mysql.com/doc/refm...
http://www.cnblogs.com/xiaolu...spa

相關文章
相關標籤/搜索