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

Live upgrade from 5.5 does not work: InnoDB stat tables are used before creation

    XMLWordPrintable

Details

    Description

      In 10.4, upgrade scripts are concatenated in a different order, comparing to previous versions:

         SET(CAT_COMMAND COMMAND 
           ${CMAKE_COMMAND} -E chdir  ${CMAKE_CURRENT_SOURCE_DIR}
      -    ${CAT_EXECUTABLE} mysql_system_tables.sql mysql_system_tables_fix.sql mysql_performance_tables.sql >
      +    ${CAT_EXECUTABLE} mysql_system_tables_fix.sql mysql_system_tables.sql mysql_performance_tables.sql >
           ${CMAKE_CURRENT_BINARY_DIR}/mysql_fix_privilege_tables.sql
      

      As a result, the logic in mysql_system_tables_fix.sql attempts to use innodb_index_stats and innodb_table_stats before they are created by mysql_system_tables.sql. It's not a problem normally, when upgrade happens from a version which already had the tables, but 5.5 doesn't, so mysql_upgrade fails with

      ERROR 1243 (HY000) at line 436: Unknown prepared statement handler (stmt) given to EXECUTE
      ERROR 1243 (HY000) at line 439: Unknown prepared statement handler (stmt) given to EXECUTE
      

      Attachments

        Activity

          People

            serg Sergei Golubchik
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.