1、You must reset your password using ALTER USER statement before executing this statement.
在執行此語句之前,必須使用ALTER USER語句重置密碼。
(1)、 修改用戶密碼
mysql> alter user 'root'@'localhost' identified by 'youpassword';
或者
mysql> set password=password("youpassword");
(2)、刷新權限
mysql> flush privileges;
Your password does not satisfy the current policy requirements
您的密碼不符合當前的策略要求
注意:如果只想設置簡單密碼需要修改兩個全局參數:
mysql> set global validate_password_policy=0;
mysql> set global validate_password_length=1;
mysql> SET PASSWORD = PASSWORD('123456'); //123456 是重置的新密碼