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

The RQG reporter CrashRecovery generates invalid SQL from exotic key names.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: N/A
    • Fix Version/s: N/A
    • Component/s: Tests
    • Labels:

      Description

      This is not a server bug!
       
      Work flow:
      1. Start the server
      2. Generate some initial data
      3. One session runs a DDL/DML mix
      4. During 3. is ongoing SIGKILL the server process
      5. Restart attempt with success
      6. Run checks on the data and one of them fails unexpected with syntax error
          around the key name `idx2``idx2` or similar.
      7. RQG aborts with STATUS_RECOVERY_FAILURE because of 6.
       
      SHOW CREATE TABLE t5;
      +-------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
      | Table | Create Table                                                                                                                                                                                                                                                                                                                                                                               |
      +-------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
      | t5    | CREATE TABLE `t5` (
        `col1` int(11) NOT NULL,
        `col2` int(11) DEFAULT NULL,
        `col_int` int(11) DEFAULT NULL,
        `col_string` int(11) DEFAULT NULL,
        `col_varchar` varchar(500) DEFAULT NULL,
        `col_text` text DEFAULT NULL,
        PRIMARY KEY (`col1`),
        KEY `idx2``idx2` (`col_text`(9))     <==== This looks as if it cannot be right.
      ) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=COMPACT `ENCRYPTED`=YES `ENCRYPTION_KEY_ID`=1
       
      origin/10.6 83dbf2c99525f4e9bfc313609194c3e4f23292a4 2021-10-27T13:47:58+03:00
       
      RQG
      ====
      git clone https://github.com/mleich1/rqg --branch experimental RQG
       
      GIT_SHOW: HEAD -> experimental 5d964598d1a7eb7957b1afa9b5950ef927803070 2021-10-29T15:21:01+02:00
      rqg.pl  : Version 4.0.2 (2021-10)
       
      $RQG_HOME/rqg1.pl \
      --duration=30 \
      --queries=10000000 \
      --no_mask \
      --seed=random \
      --rpl_mode=none \
      --gendata=conf/mariadb/table_stress.zz \
      --engine=InnoDB \
      --mysqld=--innodb_page_size=32K \
      --mysqld=--log_bin_trust_function_creators=1 \
      --mysqld=--loose-idle_write_transaction_timeout=0 \
      --mysqld=--innodb_stats_persistent=off \
      --mysqld=--log-output=none \
      --mysqld=--loose_innodb_use_native_aio=0 \
      --mysqld=--loose_innodb_lock_schedule_algorithm=fcfs \
      --mysqld=--slave_net_timeout=60 \
      --mysqld=--innodb_adaptive_hash_index=on \
      --mysqld=--net_write_timeout=60 
      --mysqld=--file-key-management-filename=$RQG_HOME/conf/mariadb/encryption_keys.txt \
      --mysqld=--loose-table_lock_wait_timeout=50 \
      --mysqld=--sync-binlog=1 \
      --mysqld=--innodb-lock-wait-timeout=50 \
      --mysqld=--loose-idle_transaction_timeout=0 \
      --mysqld=--plugin-load-add=file_key_management.so \
      --mysqld=--innodb-buffer-pool-size=24M \ 
      --mysqld=--log-bin \
      --mysqld=--loose-innodb-sync-debug \
      --mysqld=--loose-innodb_fatal_semaphore_wait_threshold=600 \ 
      --mysqld=--loose-idle_readonly_transaction_timeout=0 \
      --mysqld=--net_read_timeout=30 \
      --mysqld=--connect_timeout=60 \
      --mysqld=--wait_timeout=28800 \
      --mysqld=--loose-debug_assert_on_not_freed_memory=0 \
      --mysqld=--loose-max-statement-time=30 \
      --mysqld=--lock-wait-timeout=86400 \
      --mysqld=--interactive_timeout=28800 \
      --reporters=Backtrace,CrashRecovery1,Deadlock1,ErrorLog \
      --validators=None \
      --grammar=Y_mini.yy \
      --threads=1 \
      <certain local settings>
      

        Attachments

          Activity

            People

            Assignee:
            mleich Matthias Leich
            Reporter:
            mleich Matthias Leich
            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.