mysql ERROR 1820 (HY000): You must reset your password using ALTER USER statement before executin

It’s still good to log in to MySQL (server version: 5.7.11) yesterday. The following error will be reported when executing any command after logging in today

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

Or

MySQL > set password = password (“youpassword”);
2. Refresh permissions
MySQL > flush privileges;

MySQL > help contents
you asked for help about help category: “contents”
for more information, type ‘help < item >’, where < item> is one of the following
categories:
Account Management
Administration
Compound Statements
Data Definition
Data Manipulation
Data Types
Functions
Functions and Modifiers for Use with GROUP BY
Geographic Features
Help Metadata
Language Structure
Plugins
Procedures
Storage Engines
Table Maintenance
Transactions
User-Defined Functions
Utility
mysql>

Done!

Read More: