1. 用root账号可以开启mysql服务,用普通账号却不能开启。报错信息:
ERROR 1698 (28000): Access denied for user 'root'@'localhost'
- 解决办法:http://www.cnblogs.com/leolztang/p/5094930.html
- 中间又碰到一个问题,报错:
mysqld_safe Directory '/var/run/mysqld' for UNIX socket file don't exists
2. unstall mysql and install mysql
删除mysql
1.sudo apt-get autoremove --purge mysql-server-5.5
2.sudo apt-get remove mysql-common
清理残留数据
dpkg -l |grep ^rc|awk '{print $2}' |sudo xargs dpkg -P
重新安装mysql
1.sudo apt-get install mysql-server
2.sudo apt-get install mysql-client