Lost MySQL root password?
From Kolmisoft Wiki
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
/etc/init.d/mysql stop
mysqld_safe --skip-grant-tables & [1] 2429 morgui:~# Starting mysqld daemon with databases from /var/lib/mysql mysqld_safe[2466]: started
Window hangs, we go to other console
mysql -u root
use mysql;
update user set password=PASSWORD("") where user='root';
Type your password there inside of those quotes, for example PASSWORD("my_new_password")
flush privileges;
quit;
Back to previous console:
quit;
/etc/init.d/mysql restart