Language:

Search

Change Mysql root Password Command Line

  • Share this:
post-title

First Login Mysql Server old password

1. mysql -u root -p

Then Enter mysql old Password

Select database mysql

2. use mysql;

Update new Password

3. update user set password=PASSWORD('your_new_password') where User='root';

Reload the priviliges

4. flush privileges;

5. quit

Yusuf Khalil

Yusuf Khalil