ERROR 1819 (HY000): Your password does not satisfy the current policy requirements

 

这是与validate_password_policy的值有关。

validate_password_policy有以下取值:

Policy Tests Performed
 or  Length
 or  Length; numeric, lowercase/uppercase, and special characters
 or  Length; numeric, lowercase/uppercase, and special characters; dictionary file

默认是1,即MEDIUM,所以刚开始设置的密码必须符合长度,且必须含有数字,小写或大写字母,特殊字符。所以密码必须匹配以上规则才可继续使用。

有时候,只是为了自己测试,不想密码设置得那么复杂,譬如说,我只想设置root的密码为123456。

必须修改两个全局参数:

首先,修改validate_password_policy参数的值

这样,判断密码的标准就基于密码的长度了。这个由validate_password_length参数来决定。

validate_password_length参数默认为8,它有最小值的限制,最小值为:

其中,validate_password_number_count指定了密码中数据的长度,validate_password_special_char_count指定了密码中特殊字符的长度,validate_password_mixed_case_count指定了密码中大小字母的长度。

这些参数,默认值均为1,所以validate_password_length最小值为4,如果你显性指定validate_password_length的值小于4,尽管不会报错,但validate_password_length的值将设为4。如下所示:

如果修改了validate_password_number_count,validate_password_special_char_count,validate_password_mixed_case_count中任何一个值,则validate_password_length将进行动态修改。

 

 

2017-3-27 11:09:11

版权声明:
作者:龙魂
链接:https://blog.wlzs.cn/error-1819-hy000-password-satisfy-current-policy-requirements/
来源:学海无涯
文章版权归作者所有,未经允许请勿转载。

THE END
分享
二维码
海报
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
  Shell mysql> ALTER USER 'root'@'localhost' IDENTIFIED BY '123456'; ERROR 1819 (HY000): Your password does not sati……
<<上一篇
下一篇>>