Optimising a dump : mysqldump « MySQL Utilities « MySQL Tutorial






'--opt' is used override the mysql server's normal method of reading the whole result set into memory giving a faster dump.

c:\mysql\bin\mysqldump -u root -p --opt myDatabase > myDatabase.sql

'-a' or '-all' (either will do) optimises the dump by creating mysql specific CREATE statements that speeds up the restore:

c:\mysql\bin\mysqldump -u root -p --all myDatabase > myDatabase.sql








26.4.mysqldump
26.4.1.mysqldump
26.4.2.Restoring a Dump
26.4.3.Automatically drop any tables that exist before restoring the stored tables with the ' --add-drop-table '
26.4.4.Create the database if it doesn't already exist with '--databases' option to specify the database we wish to back up
26.4.5.Optimising a dump
26.4.6.Using mysqldump to copy databases
26.4.7.To make a copy of live data