mysqldump恢復備份出現的問題

今天使用MySQL workbench導入數據的時候出現了以下報錯:

查找資料後解決:
參考鏈接:http://blog.csdn.net/cug_jiang126com/article/details/49945643 http://blog.csdn.net/topasstem8/article/details/8216740/

  • 問題1:
16:09:51 Restoring D:\Files\Documents\dumps\測試.sql
Running: mysql.exe --defaults-file="c:\users\xwjr\appdata\local\temp\tmp1acjjn.cnf"  --protocol=tcp --host=127.0.0.1 --user=root --port=3306 --default-character-set=utf8 --comments --database=xwjr_server  < "D:\\Files\\Documents\\dumps\\測試.sql"
ERROR 1840 (HY000) at line 26: @@GLOBAL.GTID_PURGED can only be set when @@GLOBAL.GTID_EXECUTED is empty.

Operation failed with exitcode 1
16:09:52 Import of D:\Files\Documents\dumps\測試xwjr_server.sql has finished with 1 errors
  • 解決辦法:

    reset master
  • 問題2:
16:09:23 Restoring D:\Files\Documents\dumps\測試.sql
Running: mysql.exe --defaults-file="c:\users\xwjr\appdata\local\temp\tmpenrr12.cnf"  --protocol=tcp --host=127.0.0.1 --user=root --port=3306 --default-character-set=utf8 --comments --database=xwjr_server  < "D:\\Files\\Documents\\dumps\\測試.sql"
ERROR 1418 (HY000) at line 2395: This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable)

Operation failed with exitcode 1
16:09:40 Import of D:\Files\Documents\dumps\測試.sql has finished with 1 errors
  • 解決辦法:
mysql> set global log_bin_trust_function_creators=TRUE;
Query OK, 0 rows affected (0.00 sec)
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章