4、获取超级数据库用户临时密码,登录,修改密码 [root@hhu MySQL]# grep 'temporary password' /var/log/mysqld.log 2017-02-23T01:36:39.249352Z 1 [Note] A temporary password is generated for root@localhost: i7NmqxstDZ?L [root@hhu MySQL]# mysql -uroot -p Enter password: Welcome to the MySQL monitor. Commands end with ; or /g. Your MySQL connection id is 4 Server version: 5.7.17