zoukankan      html  css  js  c++  java
  • MySQL root账户密码设为“root”后执行命令提示ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.

    修改root账户密码为“root”后,提示ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.

    MySQL5.7 加强了安全保障,以上意思是密码不符合安全策略要求,我们输入一个8位或以上长度,复杂一点的密码

    mysql> show databases;
    ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executing this statement.

    可以通过命令如下命令修改密码:

    alter user 'root'@'localhost' identified by 'xiaxiaoxu';
    mysql> alter user 'root'@'localhost' identified by 'xiaxiaoxu';
    Query OK, 0 rows affected (0.00 sec)

    之后再运行就不会有问题了

    mysql> show databases;
    +--------------------+
    | Database |
    +--------------------+
    | information_schema |
    | mysql |
    | performance_schema |
    | sys |
    +--------------------+
    4 rows in set (0.00 sec)

  • 相关阅读:
    CF 1083 A. The Fair Nut and the Best Path
    2434: [Noi2011]阿狸的打字机
    HDU 6086 Rikka with String
    HDU 2825 Wireless Password
    异常处理与补充模块
    面向对象
    初始socket
    面向对象的进阶(组合和继承)
    初始面向对象
    python之其他模块的用法
  • 原文地址:https://www.cnblogs.com/xiaxiaoxu/p/8977553.html
Copyright © 2011-2022 走看看