Mysql 从第一代google云sql迁移到第二代
我无法通过导出/导入将第一代迁移到第二代 尝试导入.sql文件备份时,出现以下错误:Mysql 从第一代google云sql迁移到第二代,mysql,google-cloud-platform,google-cloud-sql,Mysql,Google Cloud Platform,Google Cloud Sql,我无法通过导出/导入将第一代迁移到第二代 尝试导入.sql文件备份时,出现以下错误: ERROR 1227 (42000) at line 28: Access denied; you need (at least one of) the SUPER privilege(s) for this operation ERROR 1419 (HY000) at line 148: You do not have the SUPER privilege and binary logging is e
ERROR 1227 (42000) at line 28: Access denied; you need (at least one of) the SUPER privilege(s) for this operation
ERROR 1419 (HY000) at line 148: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)
我了解到我需要排除mysql
数据库。执行此操作后,我会遇到以下错误:
ERROR 1227 (42000) at line 28: Access denied; you need (at least one of) the SUPER privilege(s) for this operation
ERROR 1419 (HY000) at line 148: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)
值得注意的是,我的数据库确实有触发器。这在第二代谷歌云存储上是不允许的吗?如何将数据还原到此新实例?(1)如果目标第2代CloudSQL数据库已经有数据库,则在导入或重新导入第1代CloudSQL数据库之前,您希望删除这些数据库(如果您重复测试此数据库,则此功能非常有用)。接下来的2条语句创建一个包含所有要删除的数据库的文件,然后删除它们
mysql-u tisadmin-p-h IP_ADDRESS_2nd_Gen_CloudSQL_DB-e“show databases”| grep-v Database | grep-v mysql | grep-v information|schema | grep-v performance|schema | gawk'{print“drop Database”$1;选择sleep(0.1);“}>dbsToBeDropped.sql
mysql-u tisadmin-p-h IP地址第二代云sql数据库如果从.sql文件中删除触发器,则可以导入数据。如果从.sql文件中删除触发器,则可以导入数据。