First page Back Continue Last page Overview Graphics
Backup Agents and Tools
Dump: Tips Using mysqldump
For backup automation, create a dedicated mysql backup/restore user (or use root) at the OS level and put their mysql based username/password in their ~/.my.cnf file
Grant your backup/restore user (in mysql.user) permissions to at least SELECT, RELOAD, FILE (for backups), and INSERT, CREATE, DROP, INDEX (for restores).
Enable binary logging (in /etc/my.cnf add bin-log under [mysqld]) to retain at least two full backups worth of binary logs and perform daily flushes (or flush daily via backup).
--opt is on by default in =>4.1 and includes --add-drop-table
--add-locks --all --extended-insert --quick --lock-tables
For getting inter-DB referential integrity when backing up all data bases, use --all-databases along with --opt