隨筆 - 0, 文章 - 264, 評論 - 170, 引用 - 0
          數據加載中……

          ERROR 1045 (28000): Access denied for user 'openfire'@'localhost' (using password: YES)

          mysql -u root -p

          Then I created a new user bill with host %

          CREATE USER 'bill'@'%' IDENTIFIED BY 'passpass';

          Granted all the privileges to user bill:

          grant all privileges on . to 'bill'@'%' with grant option;

          Then I exit from root user and try to login with bill:

          mysql -u bill -p

          entered the correct password and got this error:

          ERROR 1045 (28000): Access denied for user 'bill'@'localhost' (using password: YES)


          錯誤原因:
          mysql.user表中存在一條user=''的記錄,導致登錄時首先匹配到這條記錄,所以無法登錄。

          解決辦法:
          刪除掉這條用戶記錄,即操作語句:DELETE FROM mysql.user where user='';

          posted on 2014-11-08 14:15 小一敗涂地 閱讀(874) 評論(0)  編輯  收藏 所屬分類: 數據庫(oracle、mysql、sql server等)相關

          主站蜘蛛池模板: 平昌县| 肇州县| 白银市| 荥阳市| 阳新县| 出国| 应城市| 洪湖市| 九龙坡区| 永济市| 三门县| 重庆市| 和政县| 渭源县| 盐池县| 芦山县| 临湘市| 清流县| 和顺县| 呼玛县| 疏勒县| 息烽县| 无为县| 庆阳市| 宝丰县| 深水埗区| 永善县| 漳浦县| 剑河县| 铁力市| 龙门县| 阳原县| 沅陵县| 青龙| 福清市| 贞丰县| 保山市| 葵青区| 繁昌县| 郸城县| 渝中区|