I had backing up to localhost working under Backuppc V3.x.x. by setting RsyncClientCmd to:

/usr/bin/sudo $rsyncPath $argList+

and adding a line to visudo:

backuppc ALL=(root) NOPASSWD:/usr/bin/rsync

which resulted in a command like this.

full backup started for directory / (baseline backup #397)
Running: /usr/bin/sudo /usr/bin/rsync --server --sender --numeric-ids --perms 
--owner --group -D --links --hard-links --times --block-size=2048 --recursive 
--ignore-times . /
Xfer PIDs are now 13562
Got remote protocol 31
Negotiated protocol version 28
Sent exclude: /var/lib/backuppc
Sent exclude: /sys/*
Sent exclude: /proc/*
Sent exclude: /dev/*

For v4 I've:
- added a similar line to visudo for /usr/local/bin/rsync_bpc
- set RsyncClientPath to sudo /usr/bin/rsync

Which fails due to root permission being denied (I think).  The last bad XferLog says

XferLOG file /var/lib/backuppc/pc/localhost/XferLOG.404 created 2021-01-03 
17:00:01
Backup prep: type = full, case = 5, inPlace = 1, doDuplicate = 0, newBkupNum = 
404, newBkupIdx = 44, lastBkupNum = , lastBkupIdx =  (FillCycle = 0, noFillCnt 
= 0)
Running: /usr/local/bin/rsync_bpc --bpc-top-dir /var/lib/backuppc 
--bpc-host-name localhost --bpc-share-name / --bpc-bkup-num 404 --bpc-bkup-comp 
0 --bpc-bkup-prevnum -1 --bpc-bkup-prevcomp -1 --bpc-bkup-inode0 5 
--bpc-log-level 1 --bpc-attrib-new -e /usr/bin/ssh\ -l\ root --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 --checksum --timeout=720000 --exclude=/var/lib/backuppc localhost:/ /
full backup started for directory /
Xfer PIDs are now 32326
This is the rsync child about to exec /usr/local/bin/rsync_bpc
root@localhost: Permission denied (publickey,password).

So it doesn't seem to be running usr/local/bin/rsync_bpc as root.  
RsyncClientPath doesn't have the same effect here as RsyncClientCmd did under 
V3.x.x.  Is this the problem and how might I resolve it, thanks?


_______________________________________________
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