Skip to main content

Password recovery

Reset lost root password

/etc/init.d/mysqld stop

mysqld_safe --skip-grant-tables --skip-networking &
sleep 5
mysql -u root

use mysql;
update user set password=PASSWORD("toor") where User='root';
flush privileges;
quit

/etc/init.d/mysqld restart