Terrific module ... thanks!
A nomination for a new feature:
In the Drupal site settings file, you can specify supplemental databases to use in addition to the default Drupal database. It would be useful to be able to include these supplemental databases in backups.
I worked up a quick patch to do this, by adding a new function to iterate through $db_url (which becomes an array of info about databases) and back up the supplemental databases. I'm not good enough to generate the backup file the same way this module does, so I simply used a mysqldump command (thanks to dmuth for this; I borrowed a few statements from his Backup module). Note this patch is based on version 5.x.1-1.
I'm sure this can be more properly integrated with backup_migrate, but I wanted to at least post a start. I don't have the need to select tables to include when backing up supplemental databases, so this simply backs up the entire database. Also, I haven't added a way to restore supplemental databases; there's probably a "right" way to work this into the existing code that I don't yet see.
If you use this patch directly, please do so carefully; it seems to work for me, but who knows what situations I've overlooked.
Again, this has been a very useful module ... thanks!
| Comment | File | Size | Author |
|---|---|---|---|
| backup_migrate.module.patch | 2.43 KB | jshuster@drupal.org |
Comments
Comment #1
ronan commentedThanks for the patch. The ability to backup additional databases is supported in the 2.x version of the module which is not yet stable, but is getting there slowly. You cannot export from multiple databases at the same time, but you can create multiple schedules so this may not be a big deal.
Other nice new features include importing to additional databases, backup up from one db directly to another, emailing backups and some other small updates.
I'm calling version 1.x feature frozen and only fixing bugs on that branch, but be sure to check out v2 and let me know if it does what you are looking for or if there are ways I can improve that functionality
Thanks again.
R
Comment #2
ronan commentedComment #4
vacilando commentedI have been searching how to add another database to back up and it seems that the way to do it is in adding a "destination" at /admin/content/backup_migrate/destination/add
This is not intuitive. "Destinations" to me were places where the backup would be saved to.
I'd recommend adding a tab with "Origins", or solve it in another way.