Bug #478 Server crash with INSERT DELAYED followed by ENABLE KEYS
Submitted: 22 May 2003 13:30 Modified: 31 May 2003 8:48
Reporter: Alexander Keremidarski Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:4.0.13 OS:Any
Assigned to: CPU Architecture:Any

[22 May 2003 13:30] Alexander Keremidarski
Description:
Synopsis says everything.

Backtrace is:

#0  0x40122df1 in kill () from /lib/libc.so.6
#1  0x40044f4a in pthread_kill () from /lib/libpthread.so.0
#2  0x40045285 in raise () from /lib/libpthread.so.0
#3  0x40122bca in raise () from /lib/libc.so.6
#4  0x40123de5 in abort () from /lib/libc.so.6
#5  0x08345586 in safe_cond_wait (cond=0x0, mp=0x83ec980, file=0x83826eb "sql_table.cc", line=936) at thr_mutex.c:204
#6  0x08198e1c in safe_remove_from_cache (thd=0x89fbea0, table=0x89f5520) at sql_table.cc:936
#7  0x0819ac3f in mysql_alter_table(THD*, char*, char*, st_ha_create_information*, st_table_list*, List<create_field>&, List<Key>&, List<Alter_drop>&, List<Alter_column>&, st_order*, bool, enum_duplicates, enum_enable_or_disable, bool) (thd=0x89fbea0, new_db=0x89f6310 "bugs", new_name=0x8a30fa8 "t", create_info=0x89fc1fc, table_list=0x8a30fc8, fields=@0x89fc144, keys=@0x89fc138, drop_list=@0x89fc0fc, alter_list=@0x89fc108, order=0x0, drop_primary=false, handle_duplicates=DUP_ERROR, keys_onoff=ENABLE, simple_alter=true) at sql_table.cc:1510
#8  0x081210c2 in mysql_execute_command() () at sql_parse.cc:1841
#9  0x08123fc4 in mysql_parse(THD*, char*, unsigned) (thd=0x89fbea0, inBuf=0x89fbfd0 "\001", length=25) at sql_parse.cc:2887
#10 0x0811eb4c in dispatch_command(enum_server_command, THD*, char*, unsigned) (command=COM_QUERY, thd=0x89fbea0, packet=0x8a28f21 "ALTER TABLE t ENABLE KEYS", packet_length=25) at sql_parse.cc:1049
#11 0x0811e4f3 in do_command(THD*) (thd=0x89fbea0) at sql_parse.cc:924
#12 0x0811da81 in handle_one_connection (arg=0x0) at sql_parse.cc:714
#13 0x40042812 in pthread_start_thread_event () from /lib/libpthread.so.0

How to repeat:
CREATE TABLE t (i int(10) PRIMARY KEY);
ALTER TABLE t DISABLE KEYS;
INSERT DELAYED INTO t VALUES(1);
ALTER TABLE t ENABLE KEYS;
[26 May 2003 2:19] Lenz Grimmer
Assigned to Sinisa as requested.
[31 May 2003 8:48] MySQL Verification Team
Thank you for your bug report. This issue has been fixed in the latest
development tree for that product. You can find more information about
accessing our development trees at 
    http://www.mysql.com/doc/en/Installing_source_tree.html