[Klug-general] USB & rsync +file exclude?

Laurence Southon laurence at southon.uk.net
Thu Sep 29 20:01:05 UTC 2011


On 29/09/11 18:01, sharon kimble wrote:
> i have the following stanza in my users crontab backup.sh; =
> #shell script for use with rsync in user crontab
> if [ -d /media/disk/ ]; then
>    /usr/bin/rsync -av /home/boztu/ /media/disk/`/bin/date +%Y%m%d`/ \
>    >> /home/boztu/cron/backup.txt
> fi

If you are doing daily backups where a lot of files don't change you
might like to look at the rsnapshot Debian package.

It uses rsync and can use the --link-dest option to rsync that will hard
link files that don't change, so the extra disc space used for each
backup is only the size of the files that have changed. That way you can
keep a lot of versions (I usually keep 30 days worth) and be able to
retrieve any of them.

It is well documented if you Google, and reasonably easy to configure.
There is a good introduction here:

http://www.debian-administration.org/article/Simple_rotated_backups_with_rsnapshot

HTH

LS
-- 
Laurence Southon
Tiger Computing, Bexley
www.tiger-computing.co.uk



More information about the Kent mailing list