MySQL – Binary Log vs Transaction Log

MySQLtransaction-log

In mysql with innodb, there are two types of logs: binary log and transaction log. I know transaction log is specific to innodb. But when comes to replication, backup and crash recover, what roles each of them play and what is the different?

Thank you!

Best Answer

The binlog is a history of the writes to the database. It is vital for replication. It can also be used in certain "incremental" backup techniques.

The transaction log (usually in files iblog1 and iblog2) is vital to InnoDB for multiple reasons: ROLLBACK, crash recovery, and possibly more.

Manual page about binlog non-InnoDB logs

Redo log

There are lots of web pages discussing these files from various viewpoints.

There are many ways to do "backup".