This module allows you to create a daily MySQL backup of your entire drupal database. If you have more than one drupal installation (or any other applications) on your database, you can tell the module to only backup tables with a particular prefix (eg. "site2_"). To install, simply unpack to /sites/all/modules/daily_mysql_backup, then visit Administer->modules, and enable it. To configure it, go to Administer->Site Configuration->Daily Mysql Backup.
Automatically download your backups to your computer every night with my new program, psBackup.
- Backups are compatible with mysqldump (can be restored by any mysql client, including phpMyAdmin, sqlYog, Navicat, etc).
- Keep backups for up to 30 days. Automatically deletes old ones after that.
- You configure when to make a backup.
- Backup files can be gzipped to make them as small as possible.
- Random characters can be added to the backup filename to make it harder for hackers to guess your filenames.
- Automatically excludes cache tables from backups.
- You specify any additional tables to exclude.
Here's how it works
- You set your cron to run at least once every hour.
- In the configuration, tell the module when you want the backup to be made (eg. 4AM).
- The first time your cron is run during the 4AM hour, the backup will be made. It will only be made once during that hour.
- Files are kept on the webserver, under sites/default/files/daily_mysql_backups
Please note: this module sends back installation notifications to richardpeacock.com. No personal data is collected, just installation details and version number. It is strictly for my own curiosity, to see how many sites have installed my module. You can disable this easily by visiting admin/settings/daily_mysql_backup.
Software License Fine Print
This code is licensed as-is, with no warranty or guarantee, under a Creative Commons Attribution 3.0 Unported License.
You may use this code however you want, even in commercial products, but only if you include attribution to me, Richard Peacock, as the original author of this small portion of code, but not in a way that implies I endorse your project.
For example, on a Help/Credits screen: Portions of this project were based on work freely obtained from these developers: Richard Peacock (http://richardpeacock.com), NAME HERE, etc. These outside developers neither endorse nor support this software.
If you use this code, feel free to email me to let me know! I'll include a link to your project here.