service mysql stop
bin/mysqld_safe –skip-grant-tables &
bin/mysqld_safe –skip-grant-tables –skip-networking &
bin/mysql -uroot
update mysql.user set authentication_string=password(‘123456’) where user=’root’ and Host = ‘localhost’;
flush privileges;
service mysql start
bin/mysql -uroot -p123456
set password for ‘root’@’localhost’=password(‘123456’);
flush privileges;