Add --single-transaction
and --quick
to your mysqldump
command.
--single-transaction
sets the isolation mode to REPEATABLE READ and starts a transaction before dumping data. useful for InnoDB tables, dumps the consistent state without blocking any applications.
--quick