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

Spider: Assertions `status_var.local_memory_used == 0 || !debug_assert_on_not_freed_memory', `thd->status_var.tmp_space_used >= track->previous_file_size' and `!table || !table->in_use || table->in_use == _current_thd()' failed

    XMLWordPrintable

Details

    Description

      As discussed with ycp, opening a ticket for this testcase. Yuchen also saw memory leak warnings.

      SET sql_mode='';
      INSTALL PLUGIN Spider SONAME 'ha_spider.so';
      GRANT ALL ON * TO Spider@localhost;
      CREATE SERVER srv FOREIGN DATA WRAPPER MYSQL OPTIONS (SOCKET '../socket.sock',DATABASE'',USER 'Spider',PASSWORD'');
      CREATE TABLE t (c INT KEY,c1 BLOB,c2 TEXT) ENGINE=InnoDB;
      CREATE TABLE t1 (c1 CHAR CHARACTER SET UCS2 COLLATE UCS2_bin,KEY(c1)) ENGINE=Spider COMMENT='TABLE "st"' PARTITION BY LIST COLUMNS (c1) (PARTITION p DEFAULT COMMENT='srv "d"' ENGINE=Spider COMMENT='WRAPPER "mysql",SRV "srv",TABLE "t"');
      SET spider_quick_page_byte=0,spider_bgs_mode=1;
      SELECT COUNT(*) FROM t1;
      

      Leads to:

      11.2.6 a8517608894f43954e210035d357400b3d637195 (Debug)

      mariadbd: /test/11.2_dbg/sql/sql_class.cc:1812: virtual THD::~THD(): Assertion `status_var.local_memory_used == 0 || !debug_assert_on_not_freed_memory' failed.
      

      11.2.6 a8517608894f43954e210035d357400b3d637195 (Debug)

      Core was generated by `/test/MD130824-mariadb-11.2.6-linux-x86_64-dbg/bin/mariadbd --no-defaults --max'.
      Program terminated with signal SIGABRT, Aborted.
      Download failed: Invalid argument.  Continuing without source file ./nptl/./nptl/pthread_kill.c.
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:44
       
      warning: 44	./nptl/pthread_kill.c: No such file or directory
      [Current thread is 1 (LWP 158643)]
      (gdb) bt
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:44
      #1  __pthread_kill_internal (signo=6, threadid=<optimized out>)at ./nptl/pthread_kill.c:78
      #2  __GI___pthread_kill (threadid=<optimized out>, signo=signo@entry=6)at ./nptl/pthread_kill.c:89
      #3  0x0000151c2e04526e in __GI_raise (sig=sig@entry=6)at ../sysdeps/posix/raise.c:26
      #4  0x0000151c2e0288ff in __GI_abort () at ./stdlib/abort.c:79
      #5  0x0000151c2e02881b in __assert_fail_base (fmt=0x151c2e1d01e8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x5629835686b8 "status_var.local_memory_used == 0 || !debug_assert_on_not_freed_memory", file=file@entry=0x562983566e10 "/test/11.2_dbg/sql/sql_class.cc", line=line@entry=1812, function=function@entry=0x5629837133d7 "virtual THD::~THD()")at ./assert/assert.c:94
      #6  0x0000151c2e03b507 in __assert_fail (assertion=0x5629835686b8 "status_var.local_memory_used == 0 || !debug_assert_on_not_freed_memory", file=0x562983566e10 "/test/11.2_dbg/sql/sql_class.cc", line=1812, function=0x5629837133d7 "virtual THD::~THD()")at ./assert/assert.c:103
      #7  0x00005629827da5a0 in THD::~THD (this=0x151bb4000f98, __in_chrg=<optimized out>) at /test/11.2_dbg/sql/sql_class.cc:1812
      #8  0x00005629827da5d3 in THD::~THD (this=0x151bb4000f98, __in_chrg=<optimized out>) at /test/11.2_dbg/sql/sql_class.cc:1818
      #9  0x0000151c2c1bb874 in spider_bg_conn_action (arg=0x151bcc054198)at /test/11.2_dbg/storage/spider/spd_conn.cc:2496
      #10 0x0000151c2e09ca94 in start_thread (arg=<optimized out>)at ./nptl/pthread_create.c:447
      #11 0x0000151c2e129c3c in clone3 ()at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:78
      

      Bug confirmed present in:
      MariaDB: 10.5.27 (dbg), 10.6.20 (dbg), 10.11.10 (dbg), 11.1.7 (dbg), 11.2.6 (dbg), 11.4.4 (dbg), 11.5.2 (dbg), 11.6.1 (dbg)

      Bug (or feature/syntax) confirmed not present in:
      MariaDB: 10.5.27 (opt), 10.6.20 (opt), 10.11.10 (opt), 11.1.7 (opt), 11.2.6 (opt), 11.4.4 (opt), 11.5.2 (opt), 11.6.1 (opt)

      Attachments

        Activity

          People

            ycp Yuchen Pei
            Roel Roel Van de Paar
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.