rsync backup - order by size

Ty Miller tyronmiller at gmail.com
Thu Mar 29 02:23:12 GMT 2007


Thanks Matt. That's great. I'll give it a go!

Cheers,
Ty


-----Original Message-----
From: hashproduct at gmail.com [mailto:hashproduct at gmail.com] On Behalf Of Matt
McCutchen
Sent: Thursday, 29 March 2007 12:18 PM
To: Ty Miller
Cc: rsync at lists.samba.org
Subject: Re: rsync backup - order by size

On 3/28/07, Ty Miller <tyronmiller at gmail.com> wrote:
> If I changed this to include the --min-size and --max-size so that there
are
> the following two rsync passes;
>
> - Empty the daily incremental backup dir
> - Backup small files to the "Current" dir, moving modified or deleted
files
> to the daily incremental dir
> - Backup large files to the "Current" dir, moving modified or deleted
files
> to the daily incremental dir
>
> How will this affect the reality of what happens? For example;
>
> - Will the first pass cause the Current dir to only contain small files,
> causing it to move the large files to the daily incremental dir? [...]

It's good that you bring this up, but I don't think it will be a
problem.  The --min-size and --max-size options tell rsync to skip
transferring regular files whose sizes are out of range, but those
files are still present in the file list.  Thus, the receiver will
know not to delete any of the files from the "Current" dir that exist
on the sender, even files that belong to the other pass.  The two
passes should give you the same result as the one pass currently does.

Matt



More information about the rsync mailing list