On Wed, 2008-09-03 at 17:59 +0200, The Peach wrote:
>  I've finally hit rsync limit. As someone already addressed the
> problem in this list the problem regards the impossibility for rsync
> to rename directories.
> The situation is as follow:
> every night I backup my samba dir with this command:
> 
> rsync -ab --suffix=-`date +%F-%H%M` --filter="protect 
> *-[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]-[0-9][0-9][0-9][0-9]" --delete 
> --numeric-ids --stats -h /home/samba/ /mnt/usbdisk
> 
> as you can see, I simply rename the files deleted with the date
> they've been found deleted, hence providing a protect filter for the
> files with a date at the end (as you might imagine the machine serves
> windows clients).
> Obviously (!) when a directory is deleted on the source dir, all the
> files in the destination will be renamed, but the dir will not, and
> rsync tries to delete it ending with a "cannot delete a non-empty
> dir".
> 
> I'm asking here because I need even a dirty solution to this problem.

It's not clear to me what the problem is, since the "cannot delete a
non-empty dir" message is pretty harmless.  Do you want the directories
to be renamed?  If so, should the individual files inside be renamed
too?  A naive implementation of either behavior that works in the
absence of nonperishable protect filters would be quite easy.  Note that
the current behavior has the advantage or disadvantage (depending on
your point of view) that all versions of the file at a given path are
kept together even if an ancestor directory is deleted and recreated.

Matt

Attachment: signature.asc
Description: This is a digitally signed message part

-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html

Reply via email to