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

Table truncate fails for InnoDB table with FULLTEXT KEY when innodb_ft_user_stopword_table is set

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Minor
    • Resolution: Unresolved
    • 10.6.14, 10.11.5, 10.11.6
    • 10.6, 10.11
    • None
    • MS Windows 10 Enterprise 10.0.19045

      Server: Docker Desktop 4.25.2 (129061)
       Engine:
        Version: 24.0.6

      The issue also occurs on Ubuntu 20.04.6 LTS / MariaDB 10.6.14.

    Description

      We have build a docker image based on mariadb:10.11.5-jammy / mariadb:10.11.6-jammy. This image has been slightly modified so that a FULLTEXT KEY uses non-default stopword data that is available in the table oms_stopword_db.oms_ft_default_stopword. A TRUNCATE TABLE command on a table that has a FULLTEXT KEY, crashes the database.

      The following steps can be used to reproduce the error (the necessary files have been attached):

      1) Build the MariaDB image (from the folder that contains the Dockerfile / other necessary files):
      docker build -t liber/mariadb:10116-jammy .

      2) Start the MariaDB image (please ignore the MARIADB_USER/MARIADB_PASSWORD; this user is not used):
      docker run --detach --name acm-database -p 3306:3306 --env MARIADB_USER=dezegebruiker --env MARIADB_PASSWORD=ditwachtwoord --env MARIADB_ROOT_PASSWORD=root liber/mariadb:10116-jammy

      3) Connect to the acm-database image:
      docker exec -it acm-database bash

      4) Conect to the MariaDB with the mysql client:
      mysql -proot

      5) Check that the stopword table setting:
      SHOW VARIABLES like 'innodb_ft_user_stopword_table';

      6) Create the database:
      CREATE DATABASE test_db DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;

      7) Switch to the test_db:
      USE test_db;

      8) Create the test_table:
      CREATE TABLE test_table (
      id char(36) NOT NULL,
      object_type_id char(36) NOT NULL,
      functional_id varchar(255) NOT NULL,
      search_content mediumtext NOT NULL,
      PRIMARY KEY (id),
      FULLTEXT KEY search_content (search_content)
      ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

      9) Truncate the table:
      TRUNCATE TABLE test_db.test_table;

      10) Server crash.

      Attachments

        1. StepsToReproduce.txt
          1 kB
        2. SQLStatements.sql
          0.5 kB
        3. MariaDBCrashReport.log
          6 kB
        4. DockerCreate.zip
          3 kB

        Activity

          People

            thiru Thirunarayanan Balathandayuthapani
            mkropivsek Marco Kropivsek
            Votes:
            0 Vote for this issue
            Watchers:
            1 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.