1

I'm trying to create a backup of a LVM volume and I have a simple img file which contains all data. Is there any way to have this have incrementally backed up using rsync? Like a full backup every week, then each consecutive day an incremental backup until the full backup is again.

I'd like let's say restore to the backup made on Wednesday (similar as rdiff-backup can do, but rdiff-backup only support multiple files).

So: is it possible with rsync to have full and incremental backups and destroy the oldest (using a weekly 'rotation'?

Devator
  • 1,463
  • 4
  • 17
  • 35

2 Answers2

1

Do you mean to incrementally backup the whole .img file? In that case: No, it's not possible with rsync.

To do that, you could use a file system that supports efficient snapshots, like Btrfs or ZFS, or try to use rdiff-backup.

Sven
  • 97,248
  • 13
  • 177
  • 225
  • Yes that's what I mean. I'm currently mounting the volume but then there could be multiple partitions, see: http://serverfault.com/questions/369147/backing-up-lvm-volume-with-multiple-partitions/369178. However shame it doesn't work then. :-( Do you have any other idea how it could work? Using ext3 and ntfs partitions? – Devator Mar 13 '12 at 12:57
  • I have a fundamental problem with your image file approach and would rather backup separate files. – Sven Mar 13 '12 at 12:58
  • What would you do then? I do not own the LVM volumes on the disk (as they are used for virtual machines) so I cannot install anything on the virtual machine, therefore I need an "external" approach. – Devator Mar 13 '12 at 13:05
  • I would back it up like any physical machine. In most cases, this means separate backup of the boot sector, details about the partition table and of course, the backups of the file on the machine. – Sven Mar 13 '12 at 13:16
0

I'm not aware of any open source tool which can do efficient incremental backups of large files. BUP might be worth keeping an eye on, but beware the warnings. I believe there are several commercial backup applications that are designed for external backup of VM images (implying that, if they are worth anything, that they support efficient incremental backups of images), but I have no personal experience of any of those.

janneb
  • 3,761
  • 18
  • 22