出现:
ERROR 1819 (HY000): Your password does not satisfy the current policy requirements
我这边是mysql5.6升级成5.7版本造成的
1.首先进入mysql
2.执行
show variables like '%56%';
得到:
3.然后执行
SHOW VARIABLES LIKE 'validate_password%';
得到
4.执行
set global validate_password_policy=0;
5.执行
set global validate_password_length=1;
6.再次执行
SHOW VARIABLES LIKE 'validate_password%';
会得到
7.赋予root权限
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' ;
这次就不会报错了
8.刷新权限
flush privileges;
远程出现问题:
Access denied for user 'root'@‘xxx.xxx.xxx.xxx’ (using password: YES)
解决方法:
进入mysql 添加添加这个即可
grant all privileges on *.* to root@'%' identified by 'root';