Uploaded image for project: 'Percona Server'
  1. Percona Server
  2. PS-4896

[PS8QA] handle_fatal_signal (sig=11) in THD::thread_id likely due to enabling innodb_print_lock_wait_timeout_info

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Blocker
    • Resolution: Unresolved
    • Affects Version/s: 8.0
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      CREATE DATABASE test;
      USE test;
      CREATE TABLE t1(c1 CHAR (1));
      XA START 'test1';
      DELETE FROM mysql.innodb_table_stats WHERE table_name='test_ps_fetch_nonexistent';
      INSERT INTO t1 VALUES(1);
      INSERT INTO t1 VALUES(@inserted_value);
      SET GLOBAL innodb_print_lock_wait_timeout_info=true;
      SELECT SLEEP(1);

      Leads to:

      2018-09-26T07:52:46.163709Z 0 [System] [MY-010931] [Server] /sda/PS190918-percona-server-8.0.12-1-linux-x86_64-debug/bin/mysqld: ready for connections. Version: '8.0.12-1-debug'  socket: '/sda/PS190918-percona-server-8.0.12-1-linux-x86_64-debug/socket.sock'  port: 17105  MySQL Community Server (GPL).
      07:54:40 UTC - mysqld got signal 11 ;
      
      Core was generated by `/sda/PS190918-percona-server-8.0.12-1-linux-x86_64-debug/bin/mysqld --no-defaul'.
      Program terminated with signal SIGSEGV, Segmentation fault.
      #0  __pthread_kill (threadid=<optimized out>, signo=11) at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
      [Current thread is 1 (Thread 0x7f4a88ffc700 (LWP 27336))]
      (gdb) bt
      #0  __pthread_kill (threadid=<optimized out>, signo=11) at ../sysdeps/unix/sysv/linux/pthread_kill.c:57
      #1  0x0000561b5ad42431 in my_write_core (sig=11) at /git/PS-8.0.12_dbg/mysys/stacktrace.cc:278
      #2  0x0000561b59a89933 in handle_fatal_signal (sig=11) at /git/PS-8.0.12_dbg/sql/signal_handler.cc:254
      #3  <signal handler called>
      #4  0x0000561b597737f2 in THD::thread_id (this=0x0) at /git/PS-8.0.12_dbg/sql/sql_class.h:2343
      #5  0x0000561b599b22c8 in thd_get_thread_id (thd=0x0) at /git/PS-8.0.12_dbg/sql/sql_thd_api.cc:526
      #6  0x0000561b5b01c24d in print_lock_wait_timeout (trx=..., blocking=0x7f4a88ffada0, blocking_count=0)
          at /git/PS-8.0.12_dbg/storage/innobase/lock/lock0wait.cc:199
      #7  0x0000561b5b01cf8b in lock_wait_suspend_thread (thr=0x7f4a850acbd8) at /git/PS-8.0.12_dbg/storage/innobase/lock/lock0wait.cc:429
      #8  0x0000561b5b0b3e56 in que_run_threads (thr=0x7f4a850acbd8) at /git/PS-8.0.12_dbg/storage/innobase/que/que0que.cc:1029
      #9  0x0000561b5b0b40ba in que_eval_sql (info=0x7f4a8508c3b8, 
          sql=0x561b5c4cf558 "PROCEDURE TABLE_STATS_SAVE () IS\nBEGIN\nDELETE FROM \"mysql/innodb_table_stats\"\nWHERE\ndatabase_name = :database_name AND\ntable_name = :table_name;\nINSERT INTO \"mysql/innodb_table_stats\"\nVALUES\n(\n:databa"..., reserve_dict_mutex=0, 
          trx=0x7f4abbc00fe0) at /git/PS-8.0.12_dbg/storage/innobase/que/que0que.cc:1087
      #10 0x0000561b5b338aae in dict_stats_exec_sql (pinfo=0x7f4a8508c3b8, 
          sql=0x561b5c4cf558 "PROCEDURE TABLE_STATS_SAVE () IS\nBEGIN\nDELETE FROM \"mysql/innodb_table_stats\"\nWHERE\ndatabase_name = :database_name AND\ntable_name = :table_name;\nINSERT INTO \"mysql/innodb_table_stats\"\nVALUES\n(\n:databa"..., trx=0x7f4abbc00fe0)
          at /git/PS-8.0.12_dbg/storage/innobase/dict/dict0stats.cc:198
      #11 0x0000561b5b33cc4c in dict_stats_save (table_orig=0x7f4aa0e084b8, only_for_index=0x0)
          at /git/PS-8.0.12_dbg/storage/innobase/dict/dict0stats.cc:2085
      #12 0x0000561b5b33e6ec in dict_stats_update (table=0x7f4aa0e084b8, stats_upd_option=DICT_STATS_RECALC_PERSISTENT)
          at /git/PS-8.0.12_dbg/storage/innobase/dict/dict0stats.cc:2734
      #13 0x0000561b5b343b05 in dict_stats_process_entry_from_recalc_pool (thd=0x7f4a85011000)
          at /git/PS-8.0.12_dbg/storage/innobase/dict/dict0stats_bg.cc:325
      #14 0x0000561b5b343d10 in dict_stats_thread () at /git/PS-8.0.12_dbg/storage/innobase/dict/dict0stats_bg.cc:396
      #15 0x0000561b5b191076 in std::__invoke_impl<void, void (*&)()> (__f=@0x7f4a88ffbc60: 0x561b5b343c33 <dict_stats_thread()>)
          at /usr/include/c++/7/bits/invoke.h:60
      #16 0x0000561b5b190f45 in std::__invoke<void (*&)()> (__fn=@0x7f4a88ffbc60: 0x561b5b343c33 <dict_stats_thread()>)
          at /usr/include/c++/7/bits/invoke.h:95
      #17 0x0000561b5b190e08 in std::_Bind<void (*())()>::__call<void>(std::tuple<>&&, std::_Index_tuple<>) (this=0x7f4a88ffbc60, 
          __args=...) at /usr/include/c++/7/functional:467
      #18 0x0000561b5b190c65 in std::_Bind<void (*())()>::operator()<, void>() (this=0x7f4a88ffbc60) at /usr/include/c++/7/functional:551
      #19 0x0000561b5b190857 in Runnable::operator()<void (*)()> (this=0x7f4ab0d8a870, 
          f=@0x7f4ab0d8a868: 0x561b5b343c33 <dict_stats_thread()>) at /git/PS-8.0.12_dbg/storage/innobase/include/os0thread-create.h:92
      #20 0x0000561b5b18f66b in std::__invoke_impl<void, Runnable, void (*)()> (__f=..., 
          __args#0=@0x7f4ab0d8a868: 0x561b5b343c33 <dict_stats_thread()>) at /usr/include/c++/7/bits/invoke.h:60
      #21 0x0000561b5b18d665 in std::__invoke<Runnable, void (*)()> (__fn=..., 
          __args#0=@0x7f4ab0d8a868: 0x561b5b343c33 <dict_stats_thread()>) at /usr/include/c++/7/bits/invoke.h:95
      #22 0x0000561b5b191329 in std::thread::_Invoker<std::tuple<Runnable, void (*)()> >::_M_invoke<0ul, 1ul> (this=0x7f4ab0d8a868)
          at /usr/include/c++/7/thread:234
      #23 0x0000561b5b191260 in std::thread::_Invoker<std::tuple<Runnable, void (*)()> >::operator() (this=0x7f4ab0d8a868)
          at /usr/include/c++/7/thread:243
      #24 0x0000561b5b1911e8 in std::thread::_State_impl<std::thread::_Invoker<std::tuple<Runnable, void (*)()> > >::_M_run (
          this=0x7f4ab0d8a860) at /usr/include/c++/7/thread:186
      #25 0x00007f4ad3866733 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
      #26 0x00007f4ad4a4a6db in start_thread (arg=0x7f4a88ffc700) at pthread_create.c:463
      #27 0x00007f4ad2f2288f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95
      

      On MS debug, issue does not reproduce;

      8.0.12>SET GLOBAL innodb_print_lock_wait_timeout_info=true;
      ERROR 1193 (HY000): Unknown system variable 'innodb_print_lock_wait_timeout_info'
      8.0.12>SELECT SLEEP(1);
      +----------+
      | SLEEP(1) |
      +----------+
      |        0 |
      +----------+
      1 row in set (1.00 sec)  

        Attachments

          Activity

            People

            • Assignee:
              laurynas.biveinis Laurynas Biveinis
              Reporter:
              roel.vandepaar Roel Van de Paar
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - Not Specified
                Not Specified
                Logged:
                Time Spent - 2 minutes
                2m