MYSQL在ubuntu的登錄問題

 

一.登錄MYSQL問題:
檢查MYSQL服務有沒有開啓/etc/init.d/mysql start
(1)mysql -u root -p
輸入密碼之後,錯誤提示如下:ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES),意思是root的密碼不正確。
解決辦法如下:
a.sudo mysqld_safe --user=root --skip-grant-tables --skip-networking &
輸入命令之後,如果提示信息爲:
mysqld_safe A mysqld process already exists
 
表示mysqld_safe進程存在,可以通過
ps -A|grep mysql 查看mysqld_safe進程ID
kill -9 -xxxx            終結ID爲xxxx的進程
 
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章