MySQL开发中的问题

1. 用root账号可以开启mysql服务,用普通账号却不能开启。报错信息:

ERROR 1698 (28000): Access denied for user 'root'@'localhost'
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

猜你喜欢

转载自blog.csdn.net/singularinty/article/details/80826939
今日推荐