Add Comment

You are not currently logged in. If you do not have a user account then please consider creating one and logging in before you post your comment. This will allow you to track replies to your comment, and take part in the site much more freely.

To add your comment, fill in all the boxes below and then preview it to make sure you're happy with the way that it looks.

This is the comment you were replying to, attached to the article Simple rotated backups with rsnapshot:


Re: Simple rotated backups with rsnapshot
Posted by rihad (217.64.xx.xx) on Mon 17 Oct 2005 at 12:01
rsnapshot looks useful, although I haven't tried it. You can also try the dm-snapshot feature of LVM2 fame. For example: after you've migrated your /home partition to LVM2 (which, although straightforward, is a bit beyond the scope of this example), you could add the following line to root's personal crontab ("crontab -uroot -e"),

@reboot /sbin/lvremove --force vg0/home.orig; /sbin/lvcreate --snapshot --size 4m --name home.orig vg0/home

assuming your Logical Volume (LV == "partition") upong which /home gets mounted is named "home" and it lives on the Volume Group (VG == "hard disk") named "vg0", the command above gets the /home partitions's snapshot called "home.orig" to be recreated on every boot. You might need to tweak the --size argument, 4 megs might not be enough, YMMV. If the snapshot fills up it will get corrupted and you won't be able to use it any longer AFAIK (file -sL /dev/vg0/home.orig will barf ERROR: cannot read `/dev/vg0/home.orig' (Input/output error and in the output of lvdisplay vg0/home.orig it will be marked as INACTIVE) and you're gonna have to recreate it from scratch, other than that it works cool. One can always extend the size of a working snapshot before it fills up:

lvextend --size +16m

to add another 16 megs, etc.

Username:Anonymous
Title:
Your Comment:

Posting Format:

 

Inappropriate comments will be removed.

Some help on entry formatting is available

User Login

Username:

Password:

[ Advanced Login ]

Register Account

Quick Site Search