Mereset Password root MySQL

Untuk mereset password MySQL (di Ubuntu), jalankan perintah-perintah berikut :

sudo service mysqld stop

sudo /usr/bin/mysqld_safe --skip-grant-tables &

mysql

use mysql;

update user set password=password('servererp') where user='root' and host='localhost';

flush privileges;

quit

service mysqld stop

service mysqld start

exit