Microsoft Windows [版本 6.1.7601]
版权所有 (c)2009 Microsoft Corporation。保留所有权利。
C:\Users\Administrator>mysql -u root -p
Enter password: ****
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 10
Server version: 8.0.33 MySQL Community Server - GPL
Copyright (c)2000, 2023, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h'for help. Type '\c' to clear the current input statement.
mysql>
修改加密规则并重置密码
ALTER USER'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';