zoukankan      html  css  js  c++  java
  • mysql-1862、1820、java.sql.SQLException: Your password has expired. To log in you must change it using a client that supports expired passwords.

    之前一直运行的好好的,突然mysql就无法工作了。请求命令后报错误:ERROR 1820 (HY000): You must SET PASSWORD before executing this statement ,使用phpMyAdmin管理工具也无法登录,显示错误:#1862 无法登录 MySQL 服务器

    错误解决

    进入mysql的服务器中使用mysql指令进行登录及操作。

    1.登录mysql:mysql -uroot -proot

    (root是我的帐号及密码)

    2.尝试是否报1820错误,执行语句:mysql> select 1;

    (将会得到一个错误:ERROR 1820 (HY000): You must SET PASSWORD before executing this statement)

    3.设置新密码:mysql> set password=password(‘root');

    (由于我不需要更改密码,所以再次重置一下密码为root)

    4.再次尝试是否报1820错误,执行语句:mysql> select 1;

    (将得到如下返回数据,说明问题已经解决了!)

    1
    2
    3
    4
    5
    6
    7
    mysql> select 1;
    +—+
    | 1 |
    +—+
    | 1 |
    +—+
    1 row in set (0.00 sec)

    转自:http://www.jb51.net/article/99079.htm

  • 相关阅读:
    2017icpc青岛
    训练赛
    CF1598F
    CF1581
    CF1594
    CF1581D
    codeforces round 746 div2 C-E
    How I Think About Learning
    Linux Sysadmin Basics 4.1 -- Filtering Output and Finding Things (&&, cut, sort, uniq, wc, grep)
    Linux Sysadmin Basics 04 -- Shell Features -- Pipes and Redirection
  • 原文地址:https://www.cnblogs.com/weiwang/p/6252475.html
Copyright © 2011-2022 走看看