If you’re thinking without writing, you only think you’re thinking.
(Leslie B. Lamport)

Reset a MySQL root password

Stop the MySQL service

service mysql stop

Connect to MySQL

mysql -uroot

Set a new MySQL root password

use mysql;

update user set password=PASSWORD(“mynewpassword”) where User=‘root’;

flush privileges;

quit

Start the MySQL service

service mysql start