Header Ads

MySQL update password for root user

MySQL update password for root user


MySQL update password for root user

Go to mysql


sudo mysql -u root -p

Update password for root user


USE mysql;

UPDATE user SET authentication_string=PASSWORD("jundat95") WHERE User='root';

UPDATE user SET plugin="mysql_native_password" WHERE User='root';

quit;  


Kill mysqld


sudo pkill mysqld


Restart MySQL Service


sudo mysql restart

Go to MySQL with password


sudo mysql -u root -p

Enter password

Thanks



No comments