Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-33873

Assertion `!_current_thd()' failed in void destroy_background_thd(THD*)

    XMLWordPrintable

Details

    Description

      Replay using CLI

      CREATE TABLE t (b INT) ENGINE=INNODB ;
      INSTALL PLUGIN test_sql_service SONAME 'test_sql_service';
      XA START 0x7465737462;
      SET GLOBAL default_storage_engine=MEMORY;
      INSERT INTO t VALUES (1);
      SHUTDOWN;
      

      test_sql_service plugin installation command fails on 10.11 and 11.[0-4] builds

      10.11.8-dbg>install plugin test_sql_service soname 'test_sql_service';
      ERROR 1126 (HY000): Can't open shared library 'test_sql_service.so' (errno: 1, Loading of experimental plugin TEST_SQL_SERVICE is prohibited by --plugin-maturity=gamma)
      10.11.8-dbg>
      

      11.5.0 8f0c9340537b84fcd7012d4a31e6f858e7eb919c (Debug)

      mariadbd: /test/server_dbg/sql/sql_class.cc:5225: void destroy_background_thd(THD*): Assertion `!_current_thd()' failed.
      

      11.5.0 8f0c9340537b84fcd7012d4a31e6f858e7eb919c (Debug)

      Core was generated by `/test/MD200324-mariadb-11.5.0-linux-x86_64-dbg/bin/mariadbd --no-defaults --max'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      [Current thread is 1 (Thread 0x14dd7138c9c0 (LWP 1199307))]
      (gdb) bt
      #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
      #1  0x000014dd71565859 in __GI_abort () at abort.c:79
      #2  0x000014dd71565729 in __assert_fail_base (fmt=0x14dd716fb588 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x55a30a71388d "!_current_thd()", file=0x55a30a711840 "/test/server_dbg/sql/sql_class.cc", line=5225, function=<optimized out>) at assert.c:92
      #3  0x000014dd71576fd6 in __GI___assert_fail (assertion=assertion@entry=0x55a30a71388d "!_current_thd()", file=file@entry=0x55a30a711840 "/test/server_dbg/sql/sql_class.cc", line=line@entry=5225, function=function@entry=0x55a30a7128b0 "void destroy_background_thd(THD*)") at assert.c:101
      #4  0x000055a3099c29d5 in destroy_background_thd (thd=0x14dd30001398) at /test/server_dbg/sql/sql_class.cc:5225
      #5  0x000055a30a423007 in dict_stats_recalc_pool_deinit () at /test/server_dbg/storage/innobase/dict/dict0stats_bg.cc:93
      #6  dict_stats_deinit () at /test/server_dbg/storage/innobase/dict/dict0stats_bg.cc:274
      #7  0x000055a30a2e64b3 in innodb_shutdown () at /test/server_dbg/storage/innobase/srv/srv0start.cc:2055
      #8  0x000055a30a0e53b2 in innobase_end () at /test/server_dbg/storage/innobase/handler/ha_innodb.cc:4247
      #9  0x000055a309d703cc in ha_finalize_handlerton (plugin=0x55a30d8b0d00) at /test/server_dbg/sql/handler.cc:597
      #10 0x000055a309a4f8ed in plugin_deinitialize (plugin=0x55a30d8b0d00, ref_check=ref_check@entry=true) at /test/server_dbg/sql/sql_plugin.cc:1269
      #11 0x000055a309a51e04 in reap_plugins () at /test/server_dbg/sql/sql_plugin.cc:1343
      #12 0x000055a309a55042 in plugin_thdvar_cleanup (thd=thd@entry=0x14dd20039228) at /test/server_dbg/sql/sql_plugin.cc:3395
      #13 0x000055a3099c0f29 in THD::free_connection (this=this@entry=0x14dd20039228) at /test/server_dbg/sql/sql_class.cc:1678
      #14 0x000055a3099c9c20 in THD::~THD (this=0x14dd20039228, __in_chrg=<optimized out>) at /test/server_dbg/sql/sql_class.cc:1770
      #15 0x000055a3099ca405 in THD::~THD (this=0x14dd20039228, __in_chrg=<optimized out>) at /test/server_dbg/sql/sql_class.cc:1740
      #16 0x000055a309a5b2ff in loc_on_close_free (mysql=0x14dd20038ae8) at /test/server_dbg/sql/sql_prepare.cc:6220
      #17 0x000055a309d299da in mysql_close_free (mysql=mysql@entry=0x14dd20038ae8) at /test/server_dbg/sql-common/client.c:3355
      #18 0x000055a309d2d8ca in server_mysql_close (mysql=0x14dd20038ae8) at /test/server_dbg/sql-common/client.c:3472
      #19 0x000014dd7000d56f in test_sql_service_plugin_deinit (p=<optimized out>) at /test/server_dbg/plugin/test_sql_service/test_sql_service.c:239
      #20 0x000055a309bbd4b4 in finalize_audit_plugin (plugin=0x55a30d8b24b0) at /test/server_dbg/sql/sql_audit.cc:355
      #21 0x000055a309a4f8ed in plugin_deinitialize (plugin=0x55a30d8b24b0, ref_check=ref_check@entry=true) at /test/server_dbg/sql/sql_plugin.cc:1269
      #22 0x000055a309a51e04 in reap_plugins () at /test/server_dbg/sql/sql_plugin.cc:1343
      #23 0x000055a309a5369b in plugin_shutdown () at /test/server_dbg/sql/sql_plugin.cc:2085
      #24 0x000055a3098e7a1e in clean_up (print_message=print_message@entry=true) at /test/server_dbg/sql/mysqld.cc:2010
      #25 0x000055a3098f550c in mysqld_main (argc=<optimized out>, argv=<optimized out>) at /test/server_dbg/sql/mysqld.cc:6070
      #26 0x000055a3098e5bf6 in main (argc=<optimized out>, argv=<optimized out>) at /test/server_dbg/sql/main.cc:34
      

      Attachments

        Activity

          People

            serg Sergei Golubchik
            ramesh Ramesh Sivaraman
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.