xtrabackup实现增量备份使用backup用户备份时报错,使用root用户备份时不存在此问题。报错信息及backup用户的权限如下
innobackupex --defaults-file=/etc/my.cnf --socket=/tmp/mysql.sock --port=3306 --user=backup --password=back123 --no-timestamp --incremental --incremental-basedir=/backup/back/005/ /backup/back/006
xtrabackup: Generating a list of tablespaces
Error: failed to execute query FLUSH NO_WRITE_TO_BINLOG CHANGED_PAGE_BITMAPS: Access denied; you need (at least one of) the SUPER privilege(s) for this operation
mysql> show grants;
+-----------------------------------------------------------------------------------------------------+
+-----------------------------------------------------------------------------------------------------+
| GRANT RELOAD, LOCK TABLES, REPLICATION CLIENT ON *.* TO 'backup'@'localhost' IDENTIFIED BY PASSWORD |
+-----------------------------------------------------------------------------------------------------+