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

Restore dump break mysql system tables

    XMLWordPrintable

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.4.20
    • 10.6
    • None

    Description

      Restoring dump let system tables fully broken

      The dump was taken using --hex-blob --single-transaction --verbose --all-databases --add-drop-database --system=all

      the dump in my case was failing restoring at
      ERROR 1146 (42S02) at line 580: Table 'mysql.plugin' doesn't exist

      USE `world`;                                                                                                                                             
      INSTALL PLUGIN DISKS  SONAME 'disks.so';                                                                                                                 
      INSTALL PLUGIN Mroonga  SONAME 'ha_mroonga.so';
      INSTALL PLUGIN Mroonga_stats  SONAME 'ha_mroonga.so';
      INSTALL PLUGIN SQL_ERROR_LOG  SONAME 'sql_errlog.so';
      CREATE USER `mariadb.sys`@`localhost` ACCOUNT LOCK PASSWORD EXPIRE;
      

      The cause is easy some tables are recreated but the ones that contains system table objects that may be recreated as SQL COMMAND are not but the dump do drop the entire mysql schema

       
      /*!40000 DROP DATABASE IF EXISTS `mysql`*/;
       
      CREATE DATABASE /*!32312 IF NOT EXISTS*/ `mysql` /*!40100 DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci */;
       
      USE `mysql`;
      

      Attachments

        Activity

          People

            danblack Daniel Black
            stephane@skysql.com VAROQUI Stephane
            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.