这三个步骤都要执行,GRANT 低版本会默认创建用户,现在必须用CREATE USER
mysql> CREATE USER ‘root’@‘%’ IDENTIFIED BY ‘PASSWORD’;
mysql> GRANT ALL PRIVILEGES ON . TO ‘root’@‘%’ WITH GRANT OPTION;
mysql> FLUSH PRIVILEGES;
这三个步骤都要执行,GRANT 低版本会默认创建用户,现在必须用CREATE USER
mysql> CREATE USER ‘root’@‘%’ IDENTIFIED BY ‘PASSWORD’;
mysql> GRANT ALL PRIVILEGES ON . TO ‘root’@‘%’ WITH GRANT OPTION;
mysql> FLUSH PRIVILEGES;