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

mysql_upgrade failed with "('mariadb.sys'@'localhost') does not exist" and mariadb 10.4/10.5 on docker

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 10.4.17, 10.5.8
    • Fix Version/s: N/A
    • Component/s: Upgrades
    • Labels:
      None

      Description

      With fresh installation of MariaDB 10.4.17 on docker, when we run mysql_upgrade, its getting failed with below error.

      mysql.user
      Error    : The user specified as a definer ('mariadb.sys'@'localhost') does not exist
      error    : Corrupt
      Phase 4/7: Running 'mysql_fix_privilege_tables'
      ERROR 1449 (HY000) at line 7: The user specified as a definer ('mariadb.sys'@'localhost') does not exist
      ERROR 1449 (HY000) at line 16: The user specified as a definer ('mariadb.sys'@'localhost') does not exist
      ERROR 1449 (HY000) at line 59: The user specified as a definer ('mariadb.sys'@'localhost') does not exist
      ..
      

      You can reproduce it on docker with simple steps.

      Step 1: docker run -d --name marianil -eMARIADB_ROOT_PASSWORD=nil2020 -P mariadb/server:10.4
      Step 2: docker start marianil
      marianil
      Step 3: echo "show databases" | docker exec -i marianil mysql --user=root --password=nil2020 – confirm is instance is running or not.
      Database
      information_schema
      mysql
      performance_schema
      [root@localhost mysql]# echo "select version()" | docker exec -i marianil mysql --user=root --password=nil2020
      version()
      10.4.17-MariaDB-1:10.4.17+maria~bionic
      [root@localhost mysql]#

      Step 4: docker exec -i marianil mysql_upgrade --user=root --password=nil2020

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              niljoshi Nilnandan Joshi
              Reporter:
              niljoshi Nilnandan Joshi
              Votes:
              2 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: