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

main.mdev-504 unveils assertion failure in TABLE_SHARE::visit_subgraph

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 10.0.9
    • Fix Version/s: 10.0.10
    • Component/s: None
    • Labels:
      None

      Description

      main.mdev-504 fails sporadically. A simplified mtr test:

      CREATE TABLE t1(a INT);
      SELECT * FROM t1;
      SET debug_sync='tc_acquire_table SIGNAL ready WAIT_FOR go';
      --send SELECT * FROM t1
       
      connect(con1, localhost, root,, test);
      SET debug_sync='now WAIT_FOR ready';
      FLUSH TABLE t1;
      SET debug_sync='now SIGNAL go';
       
      connection default;
      reap;
      disconnect con1;
      DROP TABLE t1;

      Needs debug sync point:

      === modified file 'sql/table_cache.cc'
      --- sql/table_cache.cc	2014-03-20 07:11:13 +0000
      +++ sql/table_cache.cc	2014-03-27 15:02:31 +0000
      @@ -334,6 +334,8 @@ static TABLE *tc_acquire_table(THD *thd,
         table= share->tdc.free_tables.pop_front();
         mysql_mutex_unlock(&share->tdc.LOCK_table_share);
       
      +  DEBUG_SYNC(thd, "tc_acquire_table");
      +
         if (table)
         {
           DBUG_ASSERT(!table->in_use);

      The simplest way to fix it is to move "table->in_use= thd;" under protection of LOCK_table_share.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                svoj Sergey Vojtovich
                Reporter:
                svoj Sergey Vojtovich
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: