转载地址:https://www.cnblogs.com/reid21/p/9314376.html
从日志中获取随机生成的密码
[root@node1 db]# grep password /
var
/log/mysqld.log
2018-07-15T09:01:09.735836Z 1 [Note] A temporary password
is
generated
for
root@localhost: ViFg8pWf+,lU
[root@node1 db]# mysql -uroot -pViFg8pWf+,lU
mysql: [Warning] Using a password
on
the command line
interface
can be insecure.