如何撤销root的所有权限

时间:2016-08-23 11:09:13

标签: mysql sql

不幸的是,我将所有权限锁定为root用户。我不知道如何撤销。请任何人帮我撤销root用户的所有权限。

我尝试了以下查询,但所有内容都表示拒绝访问。



mysql> FLUSH PRIVILEGES;
ERROR 1227 (42000): Access denied; you need (at least one of) the RELOAD privilege(s) for this operation
mysql> SELECT user();
+----------------+
| user()         |
+----------------+
| root@localhost |
+----------------+
1 row in set (0.00 sec)

mysql> SELECT current_user();
+----------------+
| current_user() |
+----------------+
| root@localhost |
+----------------+
1 row in set (0.00 sec)

mysql> SHOW GRANTS FOR 'root'@'localhost';
+--------------------------------------------------------------------------+
| Grants for root@localhost                                                |
+--------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO 'root'@'localhost' IDENTIFIED BY PASSWORD <secret> |
| GRANT PROXY ON ''@'' TO 'root'@'localhost' WITH GRANT OPTION             |
+--------------------------------------------------------------------------+
2 rows in set (0.00 sec)
&#13;
&#13;
&#13;

请有人帮帮我..

提前致谢

0 个答案:

没有答案