Your Question: How Do I Change the Mysql Root Password in Linux?
Contents How Do I Change the Root Password in Mysql? Use the Mysqladmin Command-Line Utility to Alter the Mysql Password, Using the Following Syntax...
Contents
How do I change the root password in MySQL?
Use the mysqladmin command-line utility to alter the MySQL password, using the following syntax:
- mysqladmin –user=root password “newpassword”
- /opt/lampp/bin/mysqladmin –user=root password “gue55me”
- mysqladmin –user=root –password=oldpassword password “newpassword”
Must Read
How do I find my MySQL root password Linux?
Recover your MySQL password
- Stop the MySQL server process with the command sudo service mysql stop.
- Start the MySQL server with the command sudo mysqld_safe –skip-grant-tables –skip-networking &
- Connect to the MySQL server as the root user with the command mysql -u root.