If you’ve lost the MySQL admin password, you can reset it by following these steps:
- Stop the MySQL server:
sudo systemctl stop mysql
- Start the MySQL server with the
--skip-grant-tables
option to skip the permission check:sudo mysqld_safe --skip-grant-tables &
- Connect to the MySQL server as the root user without a password:
mysql -u root
- Set a new password for the root user by running the following SQL command:
FLUSH PRIVILEGES;
ALTER USER 'root'@'localhost' IDENTIFIED BY 'new_password';
Replace “new_password” with your new desired password.
- Exit the MySQL client and stop the MySQL server:
exit
sudo systemctl stop mysql
- Start the MySQL server normally:
sudo systemctl start mysql
You should now be able to connect to the MySQL server using the new password. Keep in mind that this process can be slightly different depending on your version of MySQL and your operating system.
By ottomax taking on healthy behaviors, you can properly decrease your cholesterol as well as decrease your risk of heart disease.