That was one of my other mistakes.  My working config for this is:
$Conf{RsyncClientPath} = "sudo /usr/bin/rsync";
$Conf{RsyncSshArgs} = [];

along with the line in the /etc/sudoers file to grant backuppc permission
for rsync.  It looks like both ways will work.

On Fri, Dec 22, 2023 at 9:16 AM jbk <j...@kjkelra.com> wrote:

> On 12/21/23 11:15, Tom Moore wrote:
>
> I have files on the server that is running BackupPC that I would like to
> back up.  I see from the sourceforge faq that this is possible, and there
> is a good example for using tar:
> https://backuppc.sourceforge.net/faq/localhost.html
>
> The files that I want to backup are under the /raid folder, except that I
> want to exclude the files in /raid/share/tmp:
> $Conf{BackupFilesOnly} = '/raid';
> $Conf{BackupFilesExclude} = '/raid/share/tmp';
> I was able to get the BackupPC tar transfer method working on the
> localhost.  So far so good.
>
> I would like to set this up for the rsync transfer method since there are
> a lot of files to back up and rsync is supposed to be more efficient in a
> number of ways.  I made the following changes to the host config file:
> $Conf{XferMethod} = "rsync";
> $Conf{RsyncClientPath} = "sudo /usr/bin/rsync";
> $Conf{RsyncSshArgs} = ['-e', ''];
>
> I have also added a line to the sudoers file
> backuppc ALL = NOPASSWD: /usr/bin/rsync
>
> When I try to run a backup it fails and I end up with the following error
> message in the log file:
> Running: /usr/bin/rsync_bpc --bpc-top-dir /var/lib/BackupPC/
> --bpc-host-name phoenix --bpc-share-name /raid --bpc-bkup-num 1
> --bpc-bkup-comp 3 --bpc-bkup-prevnum -1 --bpc-bkup-prevcomp -1
> --bpc-bkup-inode0 9040190 --bpc-log-level 1 --bpc-attrib-new -e
>  --rsync-path=sudo\ /usr/bin/rsync --super --recursive --protect-args
> --numeric-ids --perms --owner --group -D --times --links --hard-links
> --delete --delete-excluded --one-file-system --partial --log-format=log:\
> %o\ %i\ %B\ %8U,%8G\ %9l\ %f%L --stats --iconv=utf8,UTF-8 --timeout=72000
> --include=/raid --exclude=/\* --exclude=/raid/share/tmp phoenix:/raid/ /
> incr backup started for directory /raid
> Xfer PIDs are now 24843
> This is the rsync child about to exec /usr/bin/rsync_bpc
> rsync_bpc: Failed to exec phoenix: No such file or directory (2)
>
> Any ideas about what is going wrong here?  The localhost is named phoenix,
> and 'ping phoenix' works, as does 'nslookup phoenix'.
>
> I have this:
> $Conf{RsyncSshArgs} = [
>   '-e',
>   '/usr/bin/sudo -p'
> ];
> For backing up the local host.
>
> --
> Jim KR
>
>
_______________________________________________
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    https://github.com/backuppc/backuppc/wiki
Project: https://backuppc.github.io/backuppc/

Reply via email to