Bug #53947 InnoDB: Assertion failure in thread 4224 in file .\sync\sync0sync.c line 324

Submitted: 24 May 2010 18:11 Modified: 30 Jun 2010 19:14
Reporter: Vasil Dimov Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S1 (Critical)
Version:5.5, 5.1/plugin OS:Windows
Assigned to: John Russell CPU Architecture:Any

[24 May 2010 18:11] Vasil Dimov
Description:
The following tests are failing in PB2 on windows debug builds (both 32 and 64 bit) in embedded mode:

sys_vars.tx_isolation_func
main.lock_tables_lost_commit
innodb.innodb
main.innodb_bug30919
sys_vars.identity_func
sys_vars.last_insert_id_func
sys_vars.storage_engine_basic
main.innodb_autoinc_lock_mode_zero
sys_vars.innodb_autoinc_lock_mode_func
main.bug46760

sys_vars.tx_isolation_func               [ fail ]
        Test ended at 2010-05-23 00:28:34

CURRENT_TEST: sys_vars.tx_isolation_func
InnoDB: The InnoDB memory heap is disabled
InnoDB: Mutexes and rw_locks use InnoDB's own implementation
InnoDB: Compressed tables use zlib 1.2.3
InnoDB: The first specified data file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ibdata1 did not exist:
InnoDB: a new database to be created!
100523  0:27:58  InnoDB: Setting file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ibdata1 size to 10 MB
InnoDB: Database physically writes the file full: wait...
100523  0:27:58  InnoDB: Log file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ib_logfile0 did not exist: new to be created
InnoDB: Setting log file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ib_logfile0 size to 5 MB
InnoDB: Database physically writes the file full: wait...
100523  0:27:58  InnoDB: Log file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ib_logfile1 did not exist: new to be created
InnoDB: Setting log file H:\pb2\test\sb_2-1841352-1274561498.06\mysql-5.5.5-m3-win-x86-test\mysql-test\var-emebbed\mysqld.1\data\ib_logfile1 size to 5 MB
InnoDB: Database physically writes the file full: wait...
InnoDB: Doublewrite buffer not found: creating new
InnoDB: Doublewrite buffer created
InnoDB: 127 rollback segment(s) active.
InnoDB: Creating foreign key constraint system tables
InnoDB: Foreign key constraint system tables created
100523  0:28:33  InnoDB: Assertion failure in thread 4224 in file .\sync\sync0sync.c line 324
InnoDB: Failing assertion: mutex_get_lock_word(mutex) == 0
InnoDB: We intentionally generate a memory trap.
InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
InnoDB: If you get repeated assertion failures or crashes, even
InnoDB: immediately after the mysqld startup, there may be
InnoDB: corruption in the InnoDB tablespace. Please refer to
InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html
InnoDB: about forcing recovery.
mysqltest got exception 0xc0000005
read_command_buf at 01A617A8=
conn->name at DDDDDDDD=is an invalid string pointer
conn->cur_query at DDDDDDDD=is an invalid string pointer
Attempting backtrace...
0126AC8E    mysqltest_embedded.exe!mutex_free_func()[sync0sync.c:324]
0126AB56    mysqltest_embedded.exe!pfs_mutex_free_func()[sync0sync.ic:365]
0126B201    mysqltest_embedded.exe!sync_close()[sync0sync.c:1465]
0123F99D    mysqltest_embedded.exe!innobase_shutdown_for_mysql()[srv0start.c:2084]
011A0D44    mysqltest_embedded.exe!innobase_end()[ha_innodb.cc:2488]
00EA2C96    mysqltest_embedded.exe!ha_finalize_handlerton()[handler.cc:420]
00E9992B    mysqltest_embedded.exe!plugin_deinitialize()[sql_plugin.cc:866]
00E9984A    mysqltest_embedded.exe!reap_plugins()[sql_plugin.cc:954]
00E9C97B    mysqltest_embedded.exe!plugin_shutdown()[sql_plugin.cc:1642]
00E68F05    mysqltest_embedded.exe!clean_up()[mysqld.cc:1506]
00E6DCC2    mysqltest_embedded.exe!end_embedded_server()[lib_sql.cc:595]
00E2B675    mysqltest_embedded.exe!mysql_server_end()[libmysql.c:204]
00E123D1    mysqltest_embedded.exe!free_used_memory()[mysqltest.cc:1184]
00E12880    mysqltest_embedded.exe!cleanup_and_exit()[mysqltest.cc:1190]
00E20FE6    mysqltest_embedded.exe!main()[mysqltest.cc:8409]
01331FC7    mysqltest_embedded.exe!__tmainCRTStartup()[crt0.c:266]
01331E9F    mysqltest_embedded.exe!mainCRTStartup()[crt0.c:182]
75FFD0E9    kernel32.dll!BaseThreadInitThunk()
776019BB    ntdll.dll!RtlInitializeExceptionChain()
7760198E    ntdll.dll!RtlInitializeExceptionChain()
Writing a core file...

How to repeat:
Build a debug version on windows and run one of the mentioned tests in embedded mode.
[24 May 2010 18:12] Vasil Dimov
Might be related to Bug#53239 innodb plugin 1.0.7 crashes on shutdown on windows
[31 May 2010 15:30] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/109631

3127 Vasil Dimov	2010-05-31
      Fix Bug #53947 InnoDB: Assertion failure in thread 4224 in file .\sync\sync0sync.c line 324
      
      Destroy the rw-lock object before freeing the memory it is occupying.
      If we do not do this, then the mutex that is contained in the rw-lock
      object btr_search_latch_temp->mutex gets "freed" and subsequently
      mutex_free() from sync_close() hits a mutex whose memory has been
      freed and crashes.
      
      Approved by:	Heikki (via IRC)
      Discussed with:	Calvin
[31 May 2010 15:31] Calvin Sun
bug#53239 is marked as a dup.
[15 Jun 2010 8:11] Bugs System
Pushed into 5.5.5-m3 (revid:alik@sun.com-20100615080459-smuswd9ooeywcxuc) (version source revid:marko.makela@oracle.com-20100601103738-upm8awahesmeh9dr) (merge vers: 5.1.48) (pib:16)
[15 Jun 2010 8:27] Bugs System
Pushed into mysql-next-mr (revid:alik@sun.com-20100615080558-cw01bzdqr1bdmmec) (version source revid:marko.makela@oracle.com-20100601103738-upm8awahesmeh9dr) (pib:16)
[30 Jun 2010 19:14] John Russell
Text for the change log:

The server could crash with a message InnoDB: Assertion failure in thread nnnn,
typically during shutdown on a Windows system.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.064 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.