Hi, I'm extremely confused about anchoring of patterns for per-directory merge files, as what I see seems to not be the behaviour the documentation suggests. On the receiver side I have rsync version 3.0.3 protocol version 30. On the sender I have rsync version 2.6.9 protocol version 29. I'm calling: rsync --filter='dir-merge /.rsync-filter' -avz --delete \ --numeric-ids --relative --delete-excluded --sparse --hard-links \ --rsh='/usr/bin/ssh -4 -i /root/.ssh/rsync -q' \ root at corona:/data \ /data/backup/.sync/corona/ On the sender, I have in the file "/data/home/andy/.rsync-filter": - /tmp/ The documentation leads me to believe that this should exclude a directory called "tmp/" located only in the same directory as the merge file. What happens is, nothing gets excluded. If I use the following content instead: - tmp/ then every path containing a directory called "tmp/" is excluded. I found I can also make it more precise by using: - data/home/andy/tmp/ to exclude just the path I wanted. It's workable but I would fear that somehow a path like this might be matched by chance in a big directory tree. So why doesn't "- /tmp/" work? The documentation also says that if I am confused over what to exclude, I should just use the path as printed by --dry-run -v and put a "/" on the start. I tried that: - /data/home/andy/tmp/ but this also does not match. What am I doing wrong? Cheers, Andy
Is there a way to translate file ownership during transfer. For example, can it be done such that all files owned by user1 end up being owned by user2, and all files owned by user3 end up being owned by user4. The actual problem we're trying to solve is that some, but not all, users don't exist on the target system so we'd like the ownership for users which do exist to remain but to have a default owner (or, even better, set of owners) for the rest. -- Dave Mielke | 2213 Fox Crescent | The Bible is the very Word of God. Phone: 1-613-726-0014 | Ottawa, Ontario | 2011 May 21 is the Day of Judgement. EMail: dave at mielke.cc | Canada K2A 1H7 | 2011 Oct 21 is the End of the World. http://FamilyRadio.com/ | http://Mielke.cc/bible/
On Wed 11 Nov 2009, Andy Smith wrote:> > On the sender, I have in the file "/data/home/andy/.rsync-filter": > > - /tmp/ > > The documentation leads me to believe that this should exclude a > directory called "tmp/" located only in the same directory as the > merge file. What happens is, nothing gets excluded.No.
On Wed, 2009-11-11 at 17:14 +0000, Andy Smith wrote:> I'm extremely confused about anchoring of patterns for per-directory > merge files, as what I see seems to not be the behaviour the > documentation suggests. > > On the receiver side I have rsync version 3.0.3 protocol version > 30. On the sender I have rsync version 2.6.9 protocol version 29. > I'm calling: > > rsync --filter='dir-merge /.rsync-filter' -avz --delete \ > --numeric-ids --relative --delete-excluded --sparse --hard-links \ > --rsh='/usr/bin/ssh -4 -i /root/.ssh/rsync -q' \ > root at corona:/data \ > /data/backup/.sync/corona/ > > On the sender, I have in the file "/data/home/andy/.rsync-filter": > > - /tmp/ > > The documentation leads me to believe that this should exclude a > directory called "tmp/" located only in the same directory as the > merge file. What happens is, nothing gets excluded.This case works just fine for me with rsync 3.0.6 on both sides. Please upgrade. -- Matt