Posted by Anonymous on November 17, 2011 at 7:28am
I've been doing a lot of work on my site and I would like to keep all the work that I've done. How do I go about making a back up? The site is just on my computer using XAMPP. I've been looking at using the Back up and Migrate Module http://drupal.org/project/backup_migrate has anyone used this before? Any ideas? Thank you!
Comments
Backup and Migrate is a good solution
Backup and Migrate is a good basic solution. It has the slight detriment that it's another module to add to your site, so adds a slight bit of overhead, but is very straight forward to implement.
Basically, you need to do something that backs up your code and you database. If you're not modifying core, you probably only need to backup the sites/ directory within Drupal (cause you can always recreate core pretty easily).
And many tools exist for dumping MySQL databases to a file (which should then be backed up). msyqldump is the command line command and "drush @sites sql-dump --result-file" is a great drush command for backing up all of the sites within a multisite installation. Also phpMyAdmin and other tools usually have an "export as SQL" option which is basically the same thing as what mysqldump provides.
The next step I would suggest is to also look at starting to use a version control system (like git or svn) which will change what/how you backup, but then gives you great point in time recovery of files. It can be used as a fairly simple tool that sometimes is tough to get used to doing everytime, but I have found that it's really worth it in the long run. This is especially true if you start having other people working on your files as well.
Code and Database
When backing up your site, you need to remember that you need a copy of all of the important site files (your entire web root directory is required to run the site, but the irreplaceable goods are typically in sites/ since you can always download a new copy of Drupal core) and a copy of the database. I would say the database is the most important part.
I use Backup and Migrate on almost all of the sites I build for its ability to complete regularly scheduled backups of the database. Any performance hit by the additional module is overshadowed by the fact that backups of the database are simple to implement and automatic. Sure, you can do it manually via drush, myslq command line, phpMyAdmin, etc, but the Backup and Migrate module keeps you honest.
The weakest link in any backup routine is typically the human. :-)
Scott Rouse
http://about.me/scott.rouse
Great Tips!
Thank you guys! I appreciate all the info on back ups!