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

mysql_upgrade can delete all user

    XMLWordPrintable

    Details

      Description

      In mysql_upgrade the new table global_priv will be created like this:

      CREATE TABLE IF NOT EXISTS global_priv  [...]
      select  Host, User, JSON_COMPACT from mysql.user.
       
       DROP TABLE user; 
      

      If this select fails, all user will be deleted in the migration process.

      So DROP TABLE user; should only be executed,
      if the select get no error or return at least 1 row.

        Attachments

          Activity

            People

            Assignee:
            sanja Oleksandr Byelkin
            Reporter:
            Richard Richard Stracke
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: