如果在执行授权命令的时候报错

mysql> grant all privileges on *.* to root@'localhost' identified by "123456";
ERROR 1290 (HY000): The MySQL server is running with the --skip-grant-tables option so it cannot execute this statement

是因为在my.ini或my.cnf配置文件中添加了  skip-grant-tables  参数。

 

解决方法:

方法一、删除配置文件中的  skip-grant-tables  参数。

 

方法二:只需刷新权限就行  

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

然后再执行授权命令。

 

相关文章:

  • 2022-12-23
  • 2022-02-04
  • 2022-01-02
  • 2022-12-23
  • 2022-03-02
  • 2021-12-31
  • 2021-11-06
猜你喜欢
  • 2021-09-22
  • 2022-12-23
  • 2021-09-03
  • 2021-06-07
  • 2022-02-11
相关资源
相似解决方案