BACKUP LOCK
Protect table files during backups. This command blocks DDL operations like ALTER TABLE while allowing read/write activity, ensuring file consistency for backup tools.
Syntax
BACKUP LOCK table_nameBACKUP UNLOCKUsage in a Backup Tool
BACKUP LOCK [database.]table_name;
- Open all files related to a table (for example, t.frm, t.MAI and t.MYD)
BACKUP UNLOCK;
- Copy data
- Close filesPrivileges
Notes
Implementation
See Also
Last updated
Was this helpful?

