possibly new rsync trick: rotating snapshots
Mike Rubel
mrubel at galcit.caltech.edu
Tue Apr 9 13:24:01 EST 2002
> In addition to the comments regarding NFS etc. You will
> find that with cp -l permissions and ownership will not be
> accurately preserved in older snapshots if someone chmod or
> chowns files on the original.
Oh--Thank you, you're quite right, I missed that. If you use rsync -a,
then rsync *will* change the ownership/permissions on the target file, but
will *not* first unlink it (I had been working on the assumption that
rsync always behaves as if it had a --remove-destination flag set, but it
looks like that only holds for data, not metadata).
* To summarize: if a file's permissions/ownerships are changed in place,
* then on the next snapshot the new permissions/ownerships will affect all
* previous snapshots, not just the most recent one. This is a serious
* problem in my mind, and I apologize for missing it.
I'm looking into a workaround now; in the meantime, I posted an update at
the top of the page.
> I have a complete system for automated rotating backups that
> i was planning on announcing shortly (GPL). I have been
> using it for about a month so far and am quite pleased.
> It is a little more complex than your approach and provides
> more flexible rotation schedules with automatic image
> (snapshot) expiration.
>
> If anyone wishes to look at it or be an alpha test site
> a periodically updated snapshot of the development area can
> be found at http://www.pegasys.ws/dirvish.
Looks interesting! I'd like to give it a try.
Mike
More information about the rsync
mailing list