views:

193

answers:

3

I'm doing a webapp and need a backup plan. Here's what I've got so far:

  • nightly encrypted backup of the SQL database to Amazon S3 and my external drive (incremental if possible, not overly familiar with PostgreSQL yet, but that's another thread)
  • nightly backup of my Mercurial repo (which includes Apache configs, deploy scripts, etc) to S3 (w/ local backups via Time Machine)

Should I add anything else, or will this cover it? For a gauge of how critical the data is/would be, it's a project management app along the lines of Basecamp.

+2  A: 

Weekly full backup of your database as well as nightly incremental ones as well perhaps?

It means that if one of your old incremental backups gets corrupted then you have lost less than a week of data.

Also, ensure you have a backup test plan to ensure your backups work. There are a lot of horror stories going around about this, from companies that have been doing backups for years, never testing them and then finding out none of them are any good once they need them. (I've also been at a company like this. Thankfully I spotted the backups weren't working before they were required and fixed the problems).

workmad3
+1  A: 

One of the best strategies that worked for me in the past was to have the "backup" process just be the same as the install process, i.e. we fully scripted in linux the server configuration, application creation, database setup, etc etc so a install would look like:

./install.sh [server] [application name] and the backup/recovery ./install [server] [application name] -database [database backup file]

In terms of backup the database was backed up fully (MySQL database), by a cronjob

This pretty much ensured that the recovery was tested every time a new instance was deployed, and the scripts ended up being used also to move instances when hardware needed replacement, or when a given server was a getting too much load from a customer.

This was the setup for a Saas enterprise application that I worked a few years back, so we had full control of the servers.

webclimber
A: 

I would if you can change from a incremental back up to a differential. If you have a incremental then you would have to apply the weekly full backup and then every incremental following that. If one of your incrementals fails early in the week, then all your subsequent backups will fail too.

However if you use a differential then each differential contains all the changes since the last back up. so even if one of the back ups failed earlier in the week you would still be able to recover fully if you have a sucessful recent backup.

I hope i am explaining this well!

:)

Almond