本文主要强调修改密码的sql语句变化。如果是root密码忘记了,请参考Mysql忘记root密码怎么解决
update mysql.user set password=password('123456') where user='newuser' and host='localhost';
flush privileges;
update mysql.user set authentication_string=password('123456') where user='newuser' and host='localhost';
flush privileges;
原文:https://www.cnblogs.com/zaid/p/12112103.html