Second crash in hp_movelink with mysql-55-eb
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
percona-projects-qa |
Fix Released
|
High
|
Alexey Kopytov |
Bug Description
If a heap table containing prefix keys is ALTER-ed , the resulting table is corrupt. Either the following backtrace occurs:
#5 0x085fd074 in hp_movelink (pos=0xae911750, next_link=0x0, newlink=0xae911758) at /home/philips/
#6 0x086021d2 in hp_write_key (info=0xae93ca50, keyinfo=0xae9159ec, record=0xae9144d0 "\340\002golugc
recpos=
#7 0x08601b00 in heap_write (info=0xae93ca50, record=0xae9144d0 "\340\002golugc
at /home/philips/
#8 0x085fa774 in ha_heap::write_row (this=0xae911258, buf=0xae9144d0 "\340\002golugc
at /home/philips/
#9 0x08355a69 in handler:
at /home/philips/
#10 0x081ed5ac in write_record (thd=0xa0d8fe0, table=0xae913e00, info=0xb16b703c) at /home/philips/
#11 0x081eb7ee in mysql_insert (thd=0xa0d8fe0, table_list=
ignore=true) at /home/philips/
#12 0x08203178 in mysql_execute_
#13 0x0820a92a in mysql_parse (thd=0xa0d8fe0,
rawbuf=
at /home/philips/
#14 0x081feffa in dispatch_command (command=COM_QUERY, thd=0xa0d8fe0,
packet=
#15 0x081fe4e8 in do_command (thd=0xa0d8fe0) at /home/philips/
#16 0x082cced5 in do_handle_
#17 0x082ccb98 in handle_
#18 0x084d966c in pfs_spawn_thread (arg=0xa1607a0) at /home/philips/
#19 0x00821919 in start_thread () from /lib/libpthread
#20 0x0076acce in clone () from /lib/libc.so.6
or the server reports that the table is corrupt.
Test case:
CREATE TABLE IF NOT EXISTS t1 (
f1 VARCHAR ( 32 ) ,
f2 VARCHAR ( 128 ) ,
f3 VARBINARY ( 128 ) ,
f4 VARBINARY ( 512 ) ,
f5 VARBINARY ( 1024 ) ,
KEY ( f2 ( 1 ) ) ) ENGINE=HEAP ROW_FORMAT=DYNAMIC ;
ALTER TABLE t1 ENGINE = HEAP;
# Crash happens on this INSERT
INSERT IGNORE INTO t1 VALUES
( 2 , NULL , 6 , REPEAT( 'glugcgqk' , 5 ) , 'look' ) ,
( REPEAT( 'kglugcgqkin' , 6 ) , 'if' , 'was' , NULL , NULL ) ,
( 'go' , 'were' , 3 , 7 , 7 ) ,
( NULL , NULL , NULL , NULL , 7 );
# or, table corruption is reported on this DELETE
DELETE FROM t1 WHERE f5 <=> NULL ;
bzr version-info:
revision-id: <email address hidden>
date: 2011-05-26 09:12:10 +0300
build-date: 2011-05-26 14:41:38 +0300
revno: 3479
branch-nick: mysql-55-eb
Changed in percona-projects-qa: | |
milestone: | none → 5.5.13-eb |
importance: | Undecided → High |
assignee: | nobody → Laurynas Biveinis (laurynas-biveinis) |
status: | New → In Progress |
summary: |
- Second crash in hp_movelink with maria-55-eb + Second crash in hp_movelink with mysql-55-eb |
Changed in percona-projects-qa: | |
assignee: | Laurynas Biveinis (laurynas-biveinis) → Alexey Kopytov (akopytov) |
Changed in percona-projects-qa: | |
status: | In Progress → Fix Committed |
Changed in percona-projects-qa: | |
status: | Fix Committed → Fix Released |
Able to reproduce with
CREATE TABLE IF NOT EXISTS t1 (
f1 VARCHAR ( 32 ) ,
f2 VARCHAR ( 128 ) ,
f3 VARBINARY ( 128 ) ,
f4 VARBINARY ( 512 ) ,
f5 VARBINARY ( 1024 ) ,
KEY ( f2 ( 1 ) ) ) ENGINE=HEAP ROW_FORMAT=DYNAMIC ;
INSERT IGNORE INTO t1 VALUES
( 2 , NULL , 6 , REPEAT( 'glugcgqk' , 5 ) , 'look' ) ,
( REPEAT( 'kglugcgqkin' , 6 ) , 'if' , 'was' , NULL , NULL ),
( NULL , NULL , NULL , NULL , 7 );
DELETE FROM t1 WHERE f5 <=> NULL ;