执行下面sql语句
grant usage on *.* to 'root'@'%' identified by 'password' with grant option;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'mypassword' WITH GRANT OPTION;
//刷新
flush privileges;
这里的'mypassword'是自己的mysql密码
执行下面sql语句
grant usage on *.* to 'root'@'%' identified by 'password' with grant option;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY 'mypassword' WITH GRANT OPTION;
//刷新
flush privileges;
这里的'mypassword'是自己的mysql密码