Bug #75535 Dynamic innodb_buffer_pool_size resizing is easy to crash in debug
Submitted: 17 Jan 2015 2:49 Modified: 22 Jan 2015 2:15
Reporter: Roel Van de Paar Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Options Severity:S6 (Debug Builds)
Version:5.7-m15 OS:Any
Assigned to: CPU Architecture:Any
Tags: debug

[17 Jan 2015 2:49] Roel Van de Paar
Description:
InnoDB: Failing assertion: latches->empty() || latch->m_level == SYNC_LEVEL_VARYING || latch->m_level == SYNC_NO_ORDER_CHECK || latches->back()->m_level == SYNC_NO_ORDER_CHECK || latches->back()->m_level == SYNC_LEVEL_VARYING || latches->back()->m_level >= latch->m_level

+bt
#0  0x00007fc15cada771 in pthread_kill () from /lib64/libpthread.so.0
#1  0x0000000000e15d58 in my_write_core (sig=6) at /bzr/mysql-5.7-percona-patches_dbg/mysys/stacktrace.c:247
#2  0x0000000000822044 in handle_fatal_signal (sig=6) at /bzr/mysql-5.7-percona-patches_dbg/sql/signal_handler.cc:219
#3  <signal handler called>
#4  0x00007fc15b6de5c9 in raise () from /lib64/libc.so.6
#5  0x00007fc15b6dfcd8 in abort () from /lib64/libc.so.6
#6  0x00000000010d4ccf in ut_dbg_assertion_failed (expr=0x14dd428 "latches->empty() || latch->m_level == SYNC_LEVEL_VARYING || latch->m_level == SYNC_NO_ORDER_CHECK || latches->back()->m_level == SYNC_NO_ORDER_CHECK || latches->back()->m_level == SYNC_LEVEL_VARYING || latches->back()->m_level >= latch->m_level", file=0x14dd3c8 "/bzr/mysql-5.7-percona-patches_dbg/storage/innobase/sync/sync0debug.cc", line=299) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/ut/ut0dbg.cc:68
#7  0x0000000001092133 in SyncDebug::lock (this=0x1e472c0 <syncDebug>, latch=0x7fc13efe7870) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/sync/sync0debug.cc:294
#8  0x0000000001091cc8 in sync_check_lock (latch=0x7fc13efe7870) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/sync/sync0debug.cc:1382
#9  0x0000000000f50649 in DebugPolicy<TTASEventMutex<DebugPolicy> >::enter (this=0x7fc13efe7828, mutex=..., name=0x14fe2f0 "/bzr/mysql-5.7-percona-patches_dbg/storage/innobase/buf/buf0buf.cc", line=2418) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/include/sync0policy.ic:91
#10 0x0000000000f26495 in PolicyMutex<TTASEventMutex<DebugPolicy> >::enter (this=0x7fc13efe7810, n_spins=30, n_delay=6, name=0x14fe2f0 "/bzr/mysql-5.7-percona-patches_dbg/storage/innobase/buf/buf0buf.cc", line=2418) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/include/ib0mutex.h:1040
#11 0x0000000001130750 in buf_pool_resize () at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/buf/buf0buf.cc:2418
#12 0x0000000001131940 in buf_resize_thread (arg=0x0) at /bzr/mysql-5.7-percona-patches_dbg/storage/innobase/buf/buf0buf.cc:2707
#13 0x00007fc15cad5df3 in start_thread () from /lib64/libpthread.so.0
#14 0x00007fc15b79f1ad in clone () from /lib64/libc.so.6

How to repeat:
SET @@GLOBAL.innodb_buffer_pool_size=2342177280;
SELECT 1;
[17 Jan 2015 4:48] MySQL Verification Team
I cannot repeat this on our 5.7.5 or latest trunk builds.
Did you use a modified server by any chance ?
---
Version: '5.7.5-m15-debug'  socket: ''  port: 3306  MySQL Community Server - Debug (GPL)
2015-01-17T04:45:01.537499Z 0 [Note] InnoDB: Resizing buffer pool from 134217728 to 2415919104. (unit=134217728)
2015-01-17T04:45:01.538499Z 0 [Note] InnoDB: disabled adaptive hash index.
2015-01-17T04:45:07.540761Z 0 [Note] InnoDB: buffer pool 0 : 17 chunks (139264 blocks) were added.
2015-01-17T04:45:07.543261Z 0 [Note] InnoDB: buffer pool 0 : hash tables were resized.
2015-01-17T04:45:07.567764Z 0 [Note] InnoDB: Resized hash tables at lock_sys, adaptive hash index, dictionary.
2015-01-17T04:45:07.568264Z 0 [Note] InnoDB: Completed to resize buffer pool from 134217728 to 2415919104.
2015-01-17T04:45:07.569265Z 0 [Note] InnoDB: Re-enabled adaptive hash index.
---
[22 Jan 2015 2:15] Roel Van de Paar
Ran the whole download/setup again and indeed could not reproduce. Looks like I moved a directory incorrectly in the first test. Closing. Thanks Shane!