很奇怪,有mysql默认的这个数据库文件,但是在show databases 却看不到mysql这个库
方法一:1.关闭mysql # service mysqld stop2.屏蔽权限 # mysqld_safe --skip-grant-table 屏幕出现: Starting demo from .....3.新开起一个终端输入 # mysql -u root mysql mysql> UPDATE user SET Password=PASSWORD('newpassword') where USER='root'; mysql> FLUSH PRIVILEGES;//记得要这句话,否则如果关闭先前的终端,又会出现原来的错误 mysql> \q方法二:1.关闭mysql # service mysqld stop2.屏蔽权限 # mysqld_safe --skip-grant-table 屏幕出现: Starting demo from .....3.新开起一个终端输入 # mysql -u root mysql mysql> delete from user where USER=''; mysql> FLUSH PRIVILEGES;//记得要这句话,否则如果关闭先前的终端,又会出现原来的错误 mysql> \q