rsync files with certain mtime

Paul Slootman paul at debian.org
Fri Feb 17 15:12:58 GMT 2006


On Fri 17 Feb 2006, Mario Ohnewald wrote:
> 
> How would i rsync all files which are older than X-Days? I am missing
> some kind of -mtime option. Since this is quite common for backups i am
> wondering how you are doing this kind of stuff.

The purpose of rsync is to synchronize two directories, irrespective of
what timestamps the files on the source side may have. If you move a
file with a very old mtime into the source directory, that file will be
copied to the other side. Same goes if the file is very new.

Note that for backups it's common to search for files *younger* than X
days, instead of older :-)


Paul Slootman


More information about the rsync mailing list