不能用这个
mysql>grant all PRIVILEGES on *.* to test@'localhost' identified by '123456';
先创建用户
create user 你的账号@'%' identified by '你的密码';
grant all privileges on *.* to chenadmin@'%' with grant option;
flush privileges;
出现错误
Unable to load authentication plugin 'caching_sha2_password'.
解决方法
ALTER USER '你的账号'@'%' IDENTIFIED WITH mysql_native_password BY '你的密码.';