rsync --delete problem
Smemoe, Richard L.
smemoe at missouri.edu
Thu Jun 1 14:31:49 GMT 2006
I need to create a local backup every night of a filesystem that has
about 3.5 million files. I've been using rsync and everything has been
fine until I started to use the -delete option to delete files on the
backup that don't exist in the production data. When I added the
-delete option, my backup started taking about two days to finish. So I
changed my backup script to rsync individual top-level directories
instead of the whole filesystem at once. This finished must faster,
except now rsync seems to be only copying files that have changed on the
production data filesystem, and deleting files on my backup that haven't
Here are the three different scripts that I've tried and they all do the
rsync -au --delete /path/to/files/a* .
rsync -au --delete /path/to/files/b* .
rsync -au --delete /path/to/files/c* .
rsync -au --delete --include /path/to/files/a* --exclude /path/to/files/
rsync -au --delete --include /path/to/files/b* --exclude /path/to/files/
rsync -au --delete --include /path/to/files/c* --exclude /path/to/files/
for file in /path/to/files/*; do rsync -au --delete $file .; done
Does anyone know what I'm doing wrong here?
-------------- next part --------------
HTML attachment scrubbed and removed
More information about the rsync