How to know the default root password of MYSQL 5.7


After the installation MySQL-community-server 5.7 on linux, you will need to find the default root password. How to know it?

You can find the password you need at /var/log/mysqld.log

find default root password mysql

Or you can use the command:

cat /var/log/mysqld.log|grep "A temporary password is generated for"

Result:

[root@tutorialspots ~]# cat /var/log/mysqld.log|grep "A temporary password
is generated for"
2016-11-06T16:12:21.171890Z 1 [Note] A temporary password is generated for root@
localhost: oB&Vl>cdm7Fq

You can see the default password is oB&Vl>cdm7Fq

1 Comment

Leave a Reply