简体   繁体   中英

Mysql data recovery using mysqlbinlog

I accidentally dropped a schema without backing it up.

And now I want to use mysqlbinlog utility to perform recovery. (It seems that mysqlbinlog is a good tool). And it needs those binary log files to perform recovery.

Now I have the following confusions:

  1. I can not find those binary log files. So where are they located?
  2. If the operations are not logged or binary logging is not enabled, how to enable it. I have read the mysql documentation, it says they are enabled as default . But I cannot find those files,though...
  3. Is it possible to recover the data and schema through the /var/log/mysqld.log file

If you have the line log = /path/to/mysql.log uncommented in my.cnf , the queries will be in the mysql.log . That is, answering the third question.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM