MOCKSTACKS
EN
Questions And Answers

More Tutorials









MYSQL Recover and reset the default root password for MySQL 5Point7 PLUS

What happens when the initial start up of the server


Given that the data directory of the server is empty:

.The server is initialized.

.SSL certificate and key files are generated in the data directory.

.The validate_password plugin is installed and enabled.

.The superuser account 'root'@'localhost' is created. The password for the superuser is set and stored in the error log file.

How to change the root password by using the default password


To reveal the default "root" password:

shell> sudo grep 'temporary password' /var/log/mysqld.log

Change the root password as soon as possible by logging in with the generated temporary password and set a custom password for the superuser account:

shell> mysql -uroot -p
mysql> ALTER USER 'root'@'localhost' IDENTIFIED BY 'MyNewPass5!';

Note:

MySQL's validate_password plugin is installed by default. This will require that passwords contain at least one upper case letter, one lower case letter, one digit, and one special character, and that the total password length is at least 8 characters.

Conclusion

In this page (written and validated by ) you learned about MYSQL Recover and reset the default root password for MySQL 5Point7 PLUS . What's Next? If you are interested in completing MYSQL tutorial, your next topic will be learning about: MYSQL Recover from lost root password.



Incorrect info or code snippet? We take very seriously the accuracy of the information provided on our website. We also make sure to test all snippets and examples provided for each section. If you find any incorrect information, please send us an email about the issue: mockstacks@gmail.com.


Share On:


Mockstacks was launched to help beginners learn programming languages; the site is optimized with no Ads as, Ads might slow down the performance. We also don't track any personal information; we also don't collect any kind of data unless the user provided us a corrected information. Almost all examples have been tested. Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. By using Mockstacks.com, you agree to have read and accepted our terms of use, cookies and privacy policy.