仍然需要(至少之一)具有 log_bin_trust_function_creators=1 的 SUPER 特权

Still need (at least one of) the SUPER privilege with log_bin_trust_function_creators=1

我正在尝试将 RackSpace 中的 MySQL databases 备份到 AWS

我遵循了这个 blog 的建议并在我的 AWS RDS 控制面板中设置了 log_bin_trust_function_creators=1 并重新启动了我的数据库实例。

然而,经过一段时间并移动了一些位后,我收到以下错误:

Warning: Using a password on the command line interface can be insecure.
  16GiB 0:36:39 [7.43MiB/s] [7.43MiB/s]
ERROR 1227 (42000) at line 21566: Access denied; you need (at least one of) the SUPER privilege(s) for this operation

我知道我的数据库中有一些触发器,也许还有其他一些好东西,尽管我在 aws 上的 grants 似乎都足够了:

mysql> SHOW GRANTS;
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Grants for root@%                                                                                                                                                                                                                                                                                                                                              |
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, PROCESS, REFERENCES, INDEX, ALTER, SHOW DATABASES, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, REPLICATION SLAVE, REPLICATION CLIENT, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER ON *.* TO 'root'@'%' IDENTIFIED BY PASSWORD <secret> WITH GRANT OPTION |
+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+

可能是什么问题?我该如何解决?

编辑

我没有转储到 ssh,而是转储到 sed -n '21565,21567p',所以我假设输出(行号)应该是正确的:

/*!50001 SET collation_connection      = utf8_general_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`root`@`127.0.0.1` SQL SECURITY DEFINER */

这里的问题是您数据库中的定义行。时刻牢记:

只有当您拥有 SUPER 权限时,您才可以指定除您自己的帐户以外的 DEFINER 值。(阅读下文)

http://dev.mysql.com/doc/refman/5.6/en/stored-programs-security.html

请记住,使用 RDS 时您不会获得超级特权。