[MDEV-18573] avoid backup inconsistency in 10.2 Created: 2019-02-14  Updated: 2021-05-21  Resolved: 2021-05-21

Status: Closed
Project: MariaDB Server
Component/s: Backup
Fix Version/s: N/A

Type: Task Priority: Major
Reporter: Vladislav Lesin Assignee: Vladislav Vaintroub
Resolution: Won't Fix Votes: 0
Labels: None


 Description   
  • lock-ddl-per-table is not needed anymore as it's InnoDB ddl tracking takes care of this
  • no-locks is dangerous as it gives you silent corruption of aria and myisam tables
  • Aria tables doesn't work with BACKUP STAGES without having full redo handling in prepare, fix is to use FLUSH TABLES WITH READ LOCK and copy aria_log_control first under FTWRL and
    aria_log.# files last


 Comments   
Comment by Sergei Golubchik [ 2019-02-14 ]

If the complaint is only about "silent corruption", let's fix it in 10.2 by making it not silent — namely, issuing a warning at the end that the corruption might have happened if --no-locks was used and MYI/MYD/frm/Aria mtimes was anywhere after the backup start time. It'll keep --no-locks useful in 10.2 for most use cases (InnoDB only, privilege tables are rarely modified).

And --no-locks can be removed eventually, when a better solution is implemented.

Comment by Vladislav Vaintroub [ 2021-05-21 ]

--no-locks is not recommended, so people who use it, will know it. They (people who know it) would not use any MyISAM or Aria either. That much is also stated in the documentation for both upstream xtrabackup, and our product.

Removing something because it is dangerous, without offering an alternative, does not really work.

Now, lock-ddl-per-table is mostly harmless, it is not default, and offers some advantages compared to DDL tracking - namely that there is no need to copy changed files into backup again.
I'd say, we'll keep it, and with that, I think we can close this bug.

Generated at Thu Feb 08 08:45:08 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.