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

mariabackup is starting with not existing mysql user

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.2.12, 10.1.32, 10.2.14, 10.3.5
    • 10.2.20, 10.3.12
    • Backup
    • None
    • CentOS Linux 7.4
    • 10.2.14

    Description

      mariabackup is starting with not existing mysql user

      expected :
      mariabackup does not start if mysql user does not exist
      target-dir does not left over

      how to repeat :
      start mariabackup with unexisting mysql username – operations is accepted and
      copyng started ;
      at some stage it's received Error but target-dir left over

      [root@t4w6 ~]#  mariabackup -u dd --backup  --target-dir /var/backuup
      180117 18:09:16 Connecting to MySQL server host: localhost, user: dd, password: not set, port: not set, socket: not set
      Using server version 10.2.12-MariaDB
      mariabackup based on MariaDB server 10.2.12-MariaDB Linux (x86_64)
      mariabackup: uses posix_fadvise().
      mariabackup: cd to /var/lib/mysql/
      mariabackup: open files limit requested 0, set to 1024
      mariabackup: using the following InnoDB configuration:
      mariabackup:   innodb_data_home_dir = .
      mariabackup:   innodb_data_file_path = ibdata1:12M:autoextend
      mariabackup:   innodb_log_group_home_dir = ./
      2018-01-17 18:09:16 140109404092544 [Note] InnoDB: Number of pools: 1
      180117 18:09:16 >> log scanned up to (1628412)
      mariabackup: Generating a list of tablespaces
      2018-01-17 18:09:16 140109404092544 [Warning] InnoDB: Allocated tablespace ID 1 for mysql/innodb_table_stats, old maximum was 0
      180117 18:09:16 [01] Copying ./ibdata1 to /var/backuup/ibdata1
      180117 18:09:16 [01]        ...done
      180117 18:09:16 [01] Copying ./mysql/innodb_table_stats.ibd to /var/backuup/mysql/innodb_table_stats.ibd
      180117 18:09:16 [01]        ...done
      180117 18:09:16 [01] Copying ./mysql/innodb_index_stats.ibd to /var/backuup/mysql/innodb_index_stats.ibd
      180117 18:09:16 [01]        ...done
      180117 18:09:16 [01] Copying ./mysql/gtid_slave_pos.ibd to /var/backuup/mysql/gtid_slave_pos.ibd
      180117 18:09:16 [01]        ...done
      180117 18:09:17 [01] Copying ./ff/ff.ibd to /var/backuup/ff/ff.ibd
      180117 18:09:17 [01]        ...done
      180117 18:09:17 [01] Copying ./ff1/ff1.ibd to /var/backuup/ff1/ff1.ibd
      180117 18:09:17 [01]        ...done
      180117 18:09:17 >> log scanned up to (1628412)
      180117 18:09:17 Executing FLUSH NO_WRITE_TO_BINLOG TABLES...
      Error: failed to execute query FLUSH NO_WRITE_TO_BINLOG TABLES: Access denied; you need (at least one of) the RELOAD privilege(s) for this operation
      

      MariaDB [(none)]> select user from mysql.user;
      +------+
      | user |
      +------+
      | ff   |
      | root |
      | root |
      |      |
      | ff   |
      | root |
      |      |
      | ff   |
      | root |
      +------+
      9 rows in set (0.01 sec)
      

      [root@t4w6 ~]# ls /var/backuup
      ff  ff1  ibdata1  ib_logfile0  mysql
      

      Attachments

        Activity

          winstone Zdravelina Sokolovska (Inactive) created issue -
          elenst Elena Stepanova made changes -
          Field Original Value New Value
          Description mariabackup is starting with not existing mysql user

          expected :
           mariabackup does not start if mysql user does not exist
           target-dir does not left over


          how to repeat :
          start mariabackup with unexisting mysql username -- operations is accepted and
          copyng started ;
          at some stage it's received Error but target-dir left over


          [root@t4w6 ~]# mariabackup -u dd --backup --target-dir /var/backuup
          180117 18:09:16 Connecting to MySQL server host: localhost, user: dd, password: not set, port: not set, socket: not set
          Using server version 10.2.12-MariaDB
          mariabackup based on MariaDB server 10.2.12-MariaDB Linux (x86_64)
          mariabackup: uses posix_fadvise().
          mariabackup: cd to /var/lib/mysql/
          mariabackup: open files limit requested 0, set to 1024
          mariabackup: using the following InnoDB configuration:
          mariabackup: innodb_data_home_dir = .
          mariabackup: innodb_data_file_path = ibdata1:12M:autoextend
          mariabackup: innodb_log_group_home_dir = ./
          2018-01-17 18:09:16 140109404092544 [Note] InnoDB: Number of pools: 1
          180117 18:09:16 >> log scanned up to (1628412)
          mariabackup: Generating a list of tablespaces
          2018-01-17 18:09:16 140109404092544 [Warning] InnoDB: Allocated tablespace ID 1 for mysql/innodb_table_stats, old maximum was 0
          180117 18:09:16 [01] Copying ./ibdata1 to /var/backuup/ibdata1
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/innodb_table_stats.ibd to /var/backuup/mysql/innodb_table_stats.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/innodb_index_stats.ibd to /var/backuup/mysql/innodb_index_stats.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/gtid_slave_pos.ibd to /var/backuup/mysql/gtid_slave_pos.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:17 [01] Copying ./ff/ff.ibd to /var/backuup/ff/ff.ibd
          180117 18:09:17 [01] ...done
          180117 18:09:17 [01] Copying ./ff1/ff1.ibd to /var/backuup/ff1/ff1.ibd
          180117 18:09:17 [01] ...done
          180117 18:09:17 >> log scanned up to (1628412)
          180117 18:09:17 Executing FLUSH NO_WRITE_TO_BINLOG TABLES...
          Error: failed to execute query FLUSH NO_WRITE_TO_BINLOG TABLES: Access denied; you need (at least one of) the RELOAD privilege(s) for this operation




          MariaDB [(none)]> select user from mysql.user;
          +------+
          | user |
          +------+
          | ff |
          | root |
          | root |
          | |
          | ff |
          | root |
          | |
          | ff |
          | root |
          +------+
          9 rows in set (0.01 sec)




          [root@t4w6 ~]# ls /var/backuup
          ff ff1 ibdata1 ib_logfile0 mysql


          mariabackup is starting with not existing mysql user

          expected :
           mariabackup does not start if mysql user does not exist
           target-dir does not left over


          how to repeat :
          start mariabackup with unexisting mysql username -- operations is accepted and
          copyng started ;
          at some stage it's received Error but target-dir left over

          {noformat}
          [root@t4w6 ~]# mariabackup -u dd --backup --target-dir /var/backuup
          180117 18:09:16 Connecting to MySQL server host: localhost, user: dd, password: not set, port: not set, socket: not set
          Using server version 10.2.12-MariaDB
          mariabackup based on MariaDB server 10.2.12-MariaDB Linux (x86_64)
          mariabackup: uses posix_fadvise().
          mariabackup: cd to /var/lib/mysql/
          mariabackup: open files limit requested 0, set to 1024
          mariabackup: using the following InnoDB configuration:
          mariabackup: innodb_data_home_dir = .
          mariabackup: innodb_data_file_path = ibdata1:12M:autoextend
          mariabackup: innodb_log_group_home_dir = ./
          2018-01-17 18:09:16 140109404092544 [Note] InnoDB: Number of pools: 1
          180117 18:09:16 >> log scanned up to (1628412)
          mariabackup: Generating a list of tablespaces
          2018-01-17 18:09:16 140109404092544 [Warning] InnoDB: Allocated tablespace ID 1 for mysql/innodb_table_stats, old maximum was 0
          180117 18:09:16 [01] Copying ./ibdata1 to /var/backuup/ibdata1
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/innodb_table_stats.ibd to /var/backuup/mysql/innodb_table_stats.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/innodb_index_stats.ibd to /var/backuup/mysql/innodb_index_stats.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:16 [01] Copying ./mysql/gtid_slave_pos.ibd to /var/backuup/mysql/gtid_slave_pos.ibd
          180117 18:09:16 [01] ...done
          180117 18:09:17 [01] Copying ./ff/ff.ibd to /var/backuup/ff/ff.ibd
          180117 18:09:17 [01] ...done
          180117 18:09:17 [01] Copying ./ff1/ff1.ibd to /var/backuup/ff1/ff1.ibd
          180117 18:09:17 [01] ...done
          180117 18:09:17 >> log scanned up to (1628412)
          180117 18:09:17 Executing FLUSH NO_WRITE_TO_BINLOG TABLES...
          Error: failed to execute query FLUSH NO_WRITE_TO_BINLOG TABLES: Access denied; you need (at least one of) the RELOAD privilege(s) for this operation
          {noformat}

          {code:sql}
          MariaDB [(none)]> select user from mysql.user;
          +------+
          | user |
          +------+
          | ff |
          | root |
          | root |
          | |
          | ff |
          | root |
          | |
          | ff |
          | root |
          +------+
          9 rows in set (0.01 sec)
          {code}

          {noformat}
          [root@t4w6 ~]# ls /var/backuup
          ff ff1 ibdata1 ib_logfile0 mysql
          {noformat}
          elenst Elena Stepanova made changes -
          Fix Version/s 10.2 [ 14601 ]
          Assignee Vladislav Vaintroub [ wlad ]
          wlad Vladislav Vaintroub made changes -
          Sprint 10.2.14 [ 229 ]
          winstone Zdravelina Sokolovska (Inactive) made changes -
          Affects Version/s 10.3.5 [ 22905 ]
          winstone Zdravelina Sokolovska (Inactive) made changes -
          Affects Version/s 10.2.14 [ 22911 ]
          winstone Zdravelina Sokolovska (Inactive) made changes -
          Affects Version/s 10.1.32 [ 22908 ]
          wlad Vladislav Vaintroub made changes -
          issue.field.resolutiondate 2018-12-17 11:43:24.0 2018-12-17 11:43:24.178
          wlad Vladislav Vaintroub made changes -
          Fix Version/s 10.2.20 [ 23212 ]
          Fix Version/s 10.3.12 [ 23214 ]
          Fix Version/s 10.2 [ 14601 ]
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Closed [ 6 ]
          serg Sergei Golubchik made changes -
          Workflow MariaDB v3 [ 84925 ] MariaDB v4 [ 153584 ]

          People

            wlad Vladislav Vaintroub
            winstone Zdravelina Sokolovska (Inactive)
            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.