Chris Dennis has been working intermittently on brandysnap for over a year, and it's nearing some sort of completion.

It's a Perl script that uses rsync to create backup snapshots.  Which hardly makes it unique — there are plenty of other scripts that do the same sort of thing.

What's different about brandysnap is the way it handles which snapshots to keep and which to delete as they get older.  Other scripts assign importance to snapshots when they are created — for example, Friday afternoon snapshots may be considered more important that Tuesday afternoon ones, and are therefore kept for longer.  But what if, for any reason, the backup on Friday failed?  You'll be left without any long-term backup for that week.

Brandysnap looks at things differently.  It creates a new snapshot every time it is run, and then puts a lot of effort into deciding which existing snapshots can be deleted.  If you've told it that Friday afternoon snapshots are important, then it will look for the snapshot that was taken nearest to Friday afternoon, and avoid deleting it.  If snapshots haven't been created as often as they should have, it will adapt and still keep an appropriate number of them.

The script is, of course, open source, and is available on GitHub.

Please contact Chris Dennis with any comments or questions.

Leave a Reply