Skip to content

lukayy2/database-backup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

mysql backup / restore scripts

Simple backup and restore scripts for mysql.

database-backup.sh

  • Backup of a single Database
  • exports all Tables of Database seperatly (and compressed)
  • exports a full dump of all Tables (without Data) (for easy restore)
  • exports all Views (prefixed with "zz_view_" for sorting) (for easy restore)
  • removes definer statement from views/triggers (for easy restore)

database-restore.sh

  • Restore a previously made backup of a Database
  • checks, if the target Database has content (Tables, views, ...)
  • if database is not empty and --force is NOT set, script exists
  • if --force 1 is set, database will be cleared!
  • then the Script reads all files in the --source dir and unzips and restors every file

About

simple mysql backup/restore scripts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages