Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
5.2.14, 5.3.12, 5.5.37, 10.0.11
-
None
-
None
-
Windows, Linux
Description
Creating a certain table and populating it with some dummy data, then compressing that table with myisampack, and then issuing a CHECK TABLE command results in corrupting the table (tested in MariaDB 5.5.37).
The same table and data does not get corrupted by CHECK TABLE in MySQL 5.5.37.
Here is a reproducible test case (I pared it down as far as I could for now):
create table `t1` (`id` varchar(15) DEFAULT NULL) ENGINE=MyISAM ROW_FORMAT=FIXED; |
insert into t1 values ('aaa'),('bbb'),('ccc'),('ddd'),('eee'); |
insert into t1 (select * from t1); |
insert into t1 (select * from t1); |
insert into t1 (select * from t1); |
insert into t1 (select * from t1); |
..\..\bin\myisampack t1
|
..\..\bin\myisamchk -rq t1
|
..\..\bin\mysqladmin -uroot -pmysql -P3314 flush-tables
|
check table t1; |
# <-- corrupt! |
mysql> check table t1; |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
| Table | Op | Msg_type | Msg_text | |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
| packed.t1 | check | warning | Record checksum is not the same as checksum stored in the index file | |
| packed.t1 | check | error | Corrupt | |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
 |
mysql> check table t1; |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
| Table | Op | Msg_type | Msg_text | |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
| packed.t1 | check | warning | Table is marked as crashed | |
| packed.t1 | check | warning | Record checksum is not the same as checksum stored in the index file | |
| packed.t1 | check | error | Corrupt | |
+-----------+-------+----------+-----------------------------------------------------------------------+ |
I suspect the varchar and the row_format=fixed are involved somehow.