ERROR 1045 (28000): Access denied for user 'root'@'::1' (using password: YES)

C:\Windows\system32>mysql -uroot  -p'ZFB^2j899Wn'
mysql: [Warning] Using a password on the command line interface can be insecure.
ERROR 1045 (28000): Access denied for user 'root'@'::1' (using password: YES)

ERROR 1045 (28000): Access denied for user 'root'@'::1' (using password: YES)

windows 下吊事多,不管3721,先重置一下口令

net  stop  mysql

mysqld  --defaults-file=D:\app\local\mysql-5.7.34-winx64\my.ini  --skip-grant-tables

alter user 'root'@'%' identified  WITH mysql_native_password BY    'epmgy_Wh0711' ;

再试试,密码用单引号还是不行,需要双引号口令才行,叼毛win跟linux不一样(有特殊字符需要双引号引起来!!!!)。

C:\Windows\system32>mysql -uroot  -p"epmgy_Wh0711 "

 

posted @ 2022-05-04 15:48  beawh  阅读(319)  评论(0编辑  收藏  举报