Bug #104413 | Downgrading MySQL 5.7 from 5.7.32 to 5.7.21 in-place causes ALTERs to rebuild | ||
---|---|---|---|
Submitted: | 25 Jul 2021 19:20 | Modified: | 26 Jul 2021 14:22 |
Reporter: | Akshay Suryawanshi (OCA) | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server: Documentation | Severity: | S3 (Non-critical) |
Version: | 5.7 | OS: | Linux |
Assigned to: | Daniel Price | CPU Architecture: | x86 |
Tags: | 5.7, alter, downgrade, rebuild, upgrade |
[25 Jul 2021 19:20]
Akshay Suryawanshi
[26 Jul 2021 12:57]
MySQL Verification Team
Hi Mr. Suryawanshi, Thank you for your bug report. However, what you are reporting is a well known change in 5.7 , when it comes to InnoDB compression algorithms ..... My colleague was good enough to provide me with a link to our documentation, as well as with the relevant part with the text: --------------------------------------------------------- https://dev.mysql.com/doc/refman/5.7/en/downgrading-to-previous-series.html#downgrade-inno... "A new compression version used by the InnoDB page compression feature was added in MySQL 5.7.32. The new compression version is not compatible with earlier MySQL releases. Creating a page compressed table in MySQL 5.7.32 or higher and accessing the table after downgrading to a release earlier than MySQL 5.7.32 causes a failure. As a workaround, uncompress such tables before downgrading. To uncompress a table, run ALTER TABLE tbl_name COMPRESSION='None' and OPTIMIZE TABLE. For information about the InnoDB page compression feature, see Section 14.9.2, “InnoDB Page Compression”. " --------------------------------------------------------- We do hope that this explanation will suffice ....... Not a bug.
[26 Jul 2021 13:43]
Akshay Suryawanshi
Hi Thank you for the response. Are InnoDB tables by default compressed tables? I don't think we use compressed tables in our environment and the test tables used for reproducing the bug were also not compressed tables. Are we sure this is not a bug? Also "OPTIMIZE TABLE" for large tables will take hours to complete, which is also what we observed happen in our case due to online rebuilds.
[26 Jul 2021 14:15]
MySQL Verification Team
Hi, There are a number of metadata changes between 5.7.21 and 5.7.32 that will force rebuild of InnoDB tablespaces. Full list of those you will find in our Release Notes on dev.mysql.com.
[26 Jul 2021 14:22]
Akshay Suryawanshi
Hi, Yes you are right about the breaking changes being introduced, however, in this specific changelog https://dev.mysql.com/doc/relnotes/mysql/5.7/en/news-5-7-27.html, the documentation fails to inform that downgrading will cause a table rebuild to happen. The specific entry I am referring to is, For InnoDB tables that contained an index on a VARCHAR column and were created prior to MySQL 5.7.23, some simple ALTER TABLE statements that should have been done in place were performed with a table rebuild after an upgrade to MySQL 5.7.23 or higher. (Bug #29375764, Bug #94383) I wonder if this lack of documentation explaining that downgrading below this version will require rebuild of innodb tablespaces which were changed in version 5.7.27 is worthy of the bug report.
[27 Jul 2021 11:51]
MySQL Verification Team
In principle, we do not update Release Notes for the old releases. However, it is on the relevant team to make a decision.