mysqldump and pg_dump Command Builder
Build safe backup and restore commands for MySQL with mysqldump or PostgreSQL with pg_dump, with compression, retention and a cron schedule.
Free · No sign-up · Your inputs stay in your browser
Input
Build mysqldump and pg_dump commands
Output
Commands
616 characters
--single-transaction gives a consistent snapshot of InnoDB tables without locking them, and --quick streams rows instead of buffering each table in memory. pg_dump's --compress=zstd needs PostgreSQL 16 or later. A backup is only real once a restore of it has been tested.
Runs in this browser. Nothing you paste is sent to a server.
About this tool
Method, assumptions, practical next steps, and limits.
The flags that matter
For InnoDB, --single-transaction takes a consistent snapshot without locking tables and --quick streams rows instead of buffering whole tables in memory; --routines --triggers --events include stored code that is otherwise skipped. For PostgreSQL, the custom format (-Fc) is compressed and lets pg_restore run in parallel and restore single tables. See the pg_dump reference.
Credentials and testing
Passwords on the command line show up in the process list and shell history; use ~/.my.cnf or ~/.pgpass with mode 600. A backup is only proven by a restore: restore into a scratch database on a schedule, and alert if it fails.