Paul writes:
> I tried just changing 'RsyncClientCmd' to "$rsyncPath $argList+" but it
> seems BackupPC is expecting the SSH and is now improperly escaping
> 'RsyncArgs'. The hitch is with a space in one.
>
> $Conf{RsyncClientCmd} = '$rsyncPath $argList+';
> $Conf{RsyncArgs} = [
> '--numeric-ids',
> '--perms',
> '--owner',
> '--group',
> '-D',
> '--links',
> '--hard-links',
> '--times',
> '--block-size=2048',
> '--recursive',
> '--filter',
> 'dir-merge /.backuppc-filter'
> ];
>
> The last two are an addition I use to allow users to exclude files from
> the backup with properly crafted .backuppc-filter files in their
> directories.
>
> I end up with an extra slash after the dir-merge.
>
> /usr/bin/rsync --server --sender --numeric-ids --perms --owner --group
> -D --links --hard-links --times --block-size=2048 --recursive --filter
> dir-merge\ /.backuppc-filter --ignore-times . /etc/
The "\" is to escape the following " " since it is a single argument.
Actually, BackupPC doesn't execute the command as printed. Rather,
it keeps the arguments as an array and passes them directly to exec().
So rsync should see a single argument
dir-merge /.backuppc-filter
right after '--filter'.
For logging purposes, the command is turned into a single string and
escaped as though it was going to be executed by a shell (although it
isn't). That's when the "\" gets added.
Craig
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
BackupPC-users mailing list
BackupPC-users AT lists.sourceforge DOT net
List: https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki: http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/
|