Mysql安装教程
2017-01-31 00:15
525 查看
1.change root user
su
2.install mysql yum repository
## Fedora 24 ## dnf install https://dev.mysql.com/get/mysql57-community-release-fc24-8.noarch.rpm ## CentOS 7 and Red Hat (RHEL) 7 ## yum localinstall https://dev.mysql.com/get/mysql57-community-release-el7-8.noarch.rpm[/code]
3.update or install mysql## Fedora 24/23/22 dnf install mysql-community-server ## Fedora 21, CentOS 7.2/6.8/5.11 and Red Hat (RHEL) 7.2/6.8/5.11 yum install mysql-community-server
3.start mysql server and autostart mysql on boot## Fedora 24/23/22 and CentOS 7.2 systemctl start mysqld.service ## use restart after update systemctl enable mysqld.service ## CentOS 6.8/5.11 and Red Hat (RHEL) 6.8/5.11 /etc/init.d/mysql start ## use restart after update ## OR ## service mysql start ## use restart after update chkconfig --levels 235 mysqld on
5.get your generated random root passwordgrep 'A temporary password is generated for root@localhost' /var/log/mysqld.log |tail -1 ## Example Output: 2015-11-20T21:11:44.229891Z 1 [Note] A temporary password is generated for root@localhost: -et)QoL4MLid
6.login mysqlmysql -u password -p et)QoL4MLid
7.change validate_password_policymysql> set global validate_password_policy=0; Query OK, 0 rows affected (0.00 sec)
8.change password again!mysql> alter user 'root'@'localhost' identified by '123';
相关文章推荐
- IIS+PHP+MYSQL安装教程
- (转)MySQL 5.0安装图文教程
- Linux/Centos安装Litespeed+PHP+MYSQL+PHPMYADMIN教程
- #1045无法登录phpmyadmin,连接不上mysql服务器,先把ubuntu安装lamp教程贴上吧
- PHP环境搭建:Windows 7下安装配置PHP+Apache+Mysql环境教程
- Win2003+IIS6.0+php5.2.2+MySQL 5.0.41+ZendOptimizer 3.2.8 +phpMyAdmin 2.10.1环境配置安装教程详解
- PHP环境搭建:Windows 7下安装配置PHP+Apache+Mysql环境教程
- mysql安装教程
- mysql 5.0.67-win32.zip的安装教程
- Poechant 快速安装配置教程:Windows 7下Apache+MySQL+PHP开发环境
- mysql安装图解教程 1
- MySql 安装教程-实录
- MySQL 5.1自定义安装教程(Custom)
- MySQL 5.0安装图文教程
- MySQL 5.1 免安装版的配置(图文教程)
- MySQL最新版安装图解完整教程
- UBUNTU10.10安装LAMP(Linux、Apache、Mysql、Php)环境图文教程
- mysql安装图解 mysql图文安装教程(详细说明)
- Win7 IIS7.5+PHP Manager安装配置PHP5+Mysql教程
- PHP环境搭建:Windows 7下安装配置PHP+Apache+Mysql环境教程