mysql의 root나 debian-sys-maint계정 암호 잃어버렸을때.
linux 2007. 2. 23. 09:14 |우분투에서 mysql서버를 구동할때 debian-sys-maint계정으로 제어를 하는데 이 계정에 대한 암호가 잘못 변경이 된경우에 아래와 같이 암호를 변경한다.
/usr/bin/mysqld_safe --skip-grant-tables&
use mysql;
update user set password = password('whatever') where user = 'root' and host='localhost';
update user set password = password('whatever') where user = 'debian-sys-maint' and host='localhost';
flush privileges;