Compact Subversion Backups

If you have a large Subversion repository and want to back it up using as few space as possible, use this command (replace /repo with your actual repository path):

Step by step:

  1. The important part is --deltas, which uses a more CPU intense but more storage efficient delta method.
  2. bzip2 is slower than gzip but compresses better.
  3. Now to another fun part: tee redirects the compressed data stream into the file dump.bz2, but also writes the stream to stdout which in turn is redirected into the MD5 calculation tool.

To restore the repository, test checksum, create empty repository, restore backup:

Enjoy your compact and MD5 summed backup, and store dump.md5 and dump.bz2 somewhere really safe.

2 Comments on "Compact Subversion Backups"

Notify of

[…] 1 votes […]


[…] Compact Subversion Backups < Programming Kung Fu (tags: svn backup) […]