Historically, the MySQL binary log has gone through a few revisions resulting in different versions of how the log is formatted. The following shows the version of the binary log and the MySQL version in which it appears. As you can see, version 4 is the current version of the binary log found in the current releases of MySQL.
- Version 1: Used in MySQL 3.23
- Version 2: not released
- Version 3: Used in MySQL 4.0.2 though 4.1
- Version 4: Used in MySQL 5.0 and newer
Version 1 and version 3 were deprecated some time ago, but the versions were supported for compatibility. However, support for binary log versions 1 and 3 were removed in MySQL-8.0.2. By removing the compatibility for the older binary logs, the code was made simpler, easier to read, and performs better. If you would like more details about the versions including the changes, please read MySQL Internals Manual at https://dev.mysql.com/doc/internals/en/.
Replication supported MySQL versions
Since the adoption of version 4 in MySQL-5.0, replication of MySQL-8.0.2 and later versions can replicate data from MySQL-5.0 or later versions. However, since versions 1 and 3 are no longer supported in MySQL-8.0.2, if you want to setup replication from a MySQL-4.23 master to MySQL-8.0.2 slave, the slave will stop with an error that “Master reported unrecognized MySQL version”.
The mysqlbinlog client tool is affected in the same manner. You cannot use mysqlbinlog from the MySQL-8.0.2 release to work with versions 1 or 3 of the binary logs (from servers prior to MySQL-5.0.0).
Unsupported binary log event types
In fact, changes to the binary log support were implemented as early as MySQL-8.0.1. The following briefly summarizes the major changes.
Some binary log events for LOAD DATA statement were removed from MySQL-8.0.1. The events were deprecated earlier than MySQL-5.0 GA.
There were a group of binary log events which were introduced in non-GA versions of MySQL-5.1 and deprecated before MySQL-5.1 GA. They were removed in MySQL-8.0.1.
Modernizing MySQL replication
Another area of concentration for modifying the binary log support in MySQL-8.0 – aside from new features – focused on modernizing MySQL replication. In fact, Oracle is continuously improving and modernizing MySQL replication (include the binary log feature) to add new features, improve performance, and in the case of the binary log, cleaning up and removing the code for supporting older versions.
4,284 total views, 4 views today