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

Redundant table alter fails when fixed column stored externally

    XMLWordPrintable

Details

    Description

      Looks similar to MDEV-27858 however this bug remains post-patch. It is however not caused by the patch, as the bug can be found in builds from late January 2022.

      SET GLOBAL innodb_default_row_format=0;
      SET sql_mode='',unique_checks=0,foreign_key_checks=0;
      CREATE TABLE t (pk INT,c CHAR(255),c2 CHAR(255),c3 CHAR(255),c4 CHAR(255),c5 CHAR(255),c6 CHAR(255),c7 CHAR(255),c8 CHAR(255),PRIMARY KEY(pk)) ENGINE=InnoDB CHARACTER SET utf32;
      INSERT INTO t(c) VALUES (10);
      

      Leads to:

      11.1.0 2b61ff8f2221745f0a96855a0feb0825c426f993 (Debug)

      mariadbd: /test/11.1_dbg/storage/innobase/btr/btr0bulk.cc:1226: dberr_t BtrBulk::finish(dberr_t): Assertion `err != DB_SUCCESS || btr_validate_index(m_index, __null) == DB_SUCCESS' failed.
      

      11.1.0 2b61ff8f2221745f0a96855a0feb0825c426f993 (Debug)

      Core was generated by `/test/MD070423-mariadb-11.1.0-linux-x86_64-dbg/bin/mariadbd --no-defaults --cor'.
      Program terminated with signal SIGABRT, Aborted.
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23363482273344)
          at ./nptl/pthread_kill.c:44
      [Current thread is 1 (Thread 0x153fbc0fc640 (LWP 409785))]
      (gdb) bt
      #0  __pthread_kill_implementation (no_tid=0, signo=6, threadid=23363482273344) at ./nptl/pthread_kill.c:44
      #1  __pthread_kill_internal (signo=6, threadid=23363482273344) at ./nptl/pthread_kill.c:78
      #2  __GI___pthread_kill (threadid=23363482273344, signo=signo@entry=6) at ./nptl/pthread_kill.c:89
      #3  0x0000153fd9e69476 in __GI_raise (sig=sig@entry=6) at ../sysdeps/posix/raise.c:26
      #4  0x0000153fd9e4f7f3 in __GI_abort () at ./stdlib/abort.c:79
      #5  0x0000153fd9e4f71b in __assert_fail_base (fmt=0x153fda004150 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=0x563cf977ac18 "err != DB_SUCCESS || btr_validate_index(m_index, __null) == DB_SUCCESS", file=0x563cf977ad48 "/test/11.1_dbg/storage/innobase/btr/btr0bulk.cc", line=1226, function=<optimized out>) at ./assert/assert.c:92
      #6  0x0000153fd9e60e96 in __GI___assert_fail (assertion=0x563cf977ac18 "err != DB_SUCCESS || btr_validate_index(m_index, __null) == DB_SUCCESS", file=0x563cf977ad48 "/test/11.1_dbg/storage/innobase/btr/btr0bulk.cc", line=1226, function=0x563cf977abf0 "dberr_t BtrBulk::finish(dberr_t)") at ./assert/assert.c:101
      #7  0x0000563cf91ce13d in BtrBulk::finish (this=this@entry=0x153fbc0fa220, err=DB_SUCCESS) at /test/11.1_dbg/storage/innobase/btr/btr0bulk.cc:1226
      #8  0x0000563cf90f98f5 in row_merge_bulk_t::write_to_index (this=this@entry=0x153f70079d40, index_no=index_no@entry=0, trx=trx@entry=0x153fd9122b80) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:5337
      #9  0x0000563cf90f99e6 in row_merge_bulk_t::write_to_table (this=0x153f70079d40, table=<optimized out>, trx=trx@entry=0x153fd9122b80) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:5350
      #10 0x0000563cf90f9a2c in trx_mod_table_time_t::write_bulk (this=this@entry=0x153f7002a208, table=<optimized out>, trx=trx@entry=0x153fd9122b80) at /test/11.1_dbg/storage/innobase/row/row0merge.cc:5363
      #11 0x0000563cf8fa896d in innodb_prepare_commit_versioned (thd=<optimized out>, trx_id=<optimized out>) at /test/11.1_dbg/storage/innobase/handler/ha_innodb.cc:3661
      #12 0x0000563cf8cec096 in ha_commit_trans (thd=thd@entry=0x153f70000d58, all=all@entry=false) at /test/11.1_dbg/sql/handler.cc:1813
      #13 0x0000563cf8b7ad85 in trans_commit_stmt (thd=thd@entry=0x153f70000d58) at /test/11.1_dbg/sql/transaction.cc:472
      #14 0x0000563cf8a0fdb8 in mysql_execute_command (thd=thd@entry=0x153f70000d58, is_called_from_prepared_stmt=is_called_from_prepared_stmt@entry=false) at /test/11.1_dbg/sql/sql_parse.cc:5820
      #15 0x0000563cf8a10f05 in mysql_parse (thd=thd@entry=0x153f70000d58, rawbuf=<optimized out>, length=<optimized out>, parser_state=parser_state@entry=0x153fbc0fb230) at /test/11.1_dbg/sql/sql_parse.cc:7760
      #16 0x0000563cf8a13099 in dispatch_command (command=command@entry=COM_QUERY, thd=thd@entry=0x153f70000d58, packet=packet@entry=0x153f7000ae49 "INSERT INTO t(c) VALUES (10)", packet_length=packet_length@entry=28, blocking=blocking@entry=true) at /test/11.1_dbg/sql/sql_class.h:242
      #17 0x0000563cf8a14ef5 in do_command (thd=0x153f70000d58, blocking=blocking@entry=true) at /test/11.1_dbg/sql/sql_parse.cc:1405
      #18 0x0000563cf8b66cfc in do_handle_one_connection (connect=<optimized out>, connect@entry=0x563cfac5cfd8, put_in_cache=put_in_cache@entry=true) at /test/11.1_dbg/sql/sql_connect.cc:1416
      #19 0x0000563cf8b66f5b in handle_one_connection (arg=0x563cfac5cfd8) at /test/11.1_dbg/sql/sql_connect.cc:1318
      #20 0x0000153fd9ebbb43 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
      #21 0x0000153fd9f4da00 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
      

      Bug confirmed present in:
      MariaDB: 10.7.8 (dbg), 10.8.8 (dbg), 10.9.6 (dbg), 10.10.4 (dbg), 10.11.3 (dbg), 11.0.2 (dbg), 11.1.0 (dbg)

      Bug (or feature/syntax) confirmed not present in:
      MariaDB: 10.4.29 (dbg), 10.4.29 (opt), 10.5.20 (dbg), 10.5.20 (opt), 10.6.13 (dbg), 10.6.13 (opt), 10.7.8 (opt), 10.8.8 (opt), 10.9.6 (opt), 10.10.4 (opt), 10.11.3 (opt), 11.0.2 (opt), 11.1.0 (opt)
      MySQL: 5.5.62 (dbg), 5.5.62 (opt), 5.6.51 (dbg), 5.6.51 (opt), 5.7.40 (dbg), 5.7.40 (opt), 8.0.31 (dbg), 8.0.31 (opt)

      Attachments

        Issue Links

          Activity

            People

              thiru Thirunarayanan Balathandayuthapani
              Roel Roel Van de Paar
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

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