????1?????????mysql
????mysql –u root
??????#mysql –uroot –p
????2?????????????
????????mysql>use mysql
????mysql> use mysql
????Reading table information for completion of table and column names
????You can turn off this feature to get a quicker startup with -A
????Database changed
????3?????????
???????????password()???????м??????????
????????mysql> update user set password=password('root') where user='root';
????mysql> update user set password=password('root') where user='root';
????Query OK?? 3 rows affected (0.00 sec)
????Rows matched: 3  Changed: 3  Warnings: 0
????4?????????
????????mysql> flush privileges;
????mysql> flush privileges;
????Query OK?? 0 rows affected (0.00 sec)
????5?????mysql????mysql??????????????
????service mysqld restart