[BackupPC-users] Rsync_bpc Failing Because of Inaccessible Password?

2015-02-25 Thread Akibu Flash
I am using BackupPC 4.0 on a debian distro to backup two
windows computers running Cygwin.  I am
using rsyncd as the vehicle to back them up. 
When I try to start a backup, the backup fails apparently because of an
rsync_bpc issue.  The log file entries
are below:

Contents of file /data/BackupPC/pc/agm-pc/LOG.022015, modified 2015-02-24 
15:50:55 

2015-02-24
15:50:49 full backup started for directory Pictures

2015-02-24
15:50:50 Got fatal error during xfer (No files dumped for share Pictures)

2015-02-24
15:50:55 Backup aborted (No files dumped for share Pictures)

 

Contents of file /data/BackupPC/pc/agm-pc/XferLOG.bad.z, modified 2015-02-24 
15:50:56 

XferLOG
file /data/BackupPC/pc/agm-pc/XferLOG.0.z created 2015-02-24 15:50:49 

Backup
prep: type = full, case = 1, inPlace = 1, doDuplicate = 0, newBkupNum = 0,
newBkupIdx = 0, lastBkupNum = , lastBkupIdx = 
(FillCycle = 0, noFillCnt = )

Running:
/usr/local/bin/rsync_bpc --bpc-top-dir /data/BackupPC --bpc-host-name agm-pc
--bpc-share-name Pictures --bpc-bkup-num 0 --bpc-bkup-comp 3 --bpc-bkup-prevnum
-1 --bpc-bkup-prevcomp -1 --bpc-bkup-inode0 1 --bpc-log-level 1 --super
--recursive --protect-args --numeric-ids --perms --owner --group -D --times
--links --hard-links --delete --partial --log-format=log: %o %i %B %8U,%8G %9l
%f%L --stats --checksum --password-file=/data/BackupPC/pc/agm-pc/.rsyncdpw5658
@agm-pc::Pictures /

full
backup started for directory Pictures

Xfer
PIDs are now 5661

This
is the rsync child about to exec /usr/local/bin/rsync_bpc

ERROR:
failed to read a password from /data/BackupPC/pc/agm-pc/.rsyncdpw5658

Done:
0 errors, 0 filesExist, 0 sizeExist, 0 sizeExistComp, 0 filesTotal, 0
sizeTotal, 0 filesNew, 0 sizeNew, 0 sizeNewComp, 1 inode

rsync
error: syntax or usage error (code 1) at authenticate.c(191) [Receiver=3.0.9.3]

rsync_bpc
exited with fatal status 1 (256) (rsync error: syntax or usage error (code 1)
at authenticate.c(191) [Receiver=3.0.9.3])

Xfer
PIDs are now 

Got
fatal error during xfer (No files dumped for share Pictures)

Backup
aborted (No files dumped for share Pictures)

BackupFailCleanup:
nFilesTotal = 0, type = full, BackupCase = 1, inPlace = 1, lastBkupNum = 

Removing
empty backup #0

BackupPC_backupDelete:
removing #0

BackupPC_backupDelete:
No prior backup for merge

BackupPC_backupDelete:
got 0 errors

Running
BackupPC_refCountUpdate -h agm-pc -f on agm-pc

xferPids
5673

BackupPC_refCountUpdate:
host agm-pc got 0 errors

BackupPC_refCountPrint:
total errors: 0

xferPids

Finished
BackupPC_refCountUpdate (running time: 0 sec)
In
one of the log files, it indicates the following: “Running:
/usr/local/bin/rsync_bpc” and it has the following error message: “ERROR:
failed to read a password from /data/BackupPC/pc/agm-pc/.rsyncdpw5658”.   



Does anyone recognize that error and know what
it means?  It seems as though it needs some sort of password but I don't know 
where to input a password.  The only password I know of is in the secrets file 
on the target Windows machines, but this looks like it is not even connecting 
to even get that far.  
Thanks in advance.--
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/___
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List:https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/


Re: [BackupPC-users] BackupPC-4.0.0alpha3 - Can't create a test hardlink between a file...

2015-02-25 Thread Holger Parplies
Hi,

for the sake of completeness (though Adam has already made the point: it helps
to understand what you are asked to do rather than blindly doing it - people
make mistakes when giving advice, as the OP has proven ;-):

Akibu Flash wrote on 2015-02-19 13:32:14 -0800 [Re: [BackupPC-users] 
BackupPC-4.0.0alpha3 - Can't create a test hardlink between a file...]:
 [...]
 Once I fixed the permissions issue, the command start stop command would
 work and give me an ok.  

Beware!

*When starting daemons*, the invoking process can only detect errors the
daemon encounters *before* forking into the background. Often enough and not
necessarily in the context of BackupPC, I've seen the ok type success
message only to find out that the daemon had terminated immediately after
forking, sometimes due to the inability to open a log file, meaning there's
absolutely no trace of why the daemon was not running. This can be extremely
annoying to debug.

BackupPC does some tests before forking, but there are several fatal errors
that can happen after forking. In particular, the log file is opened after
forking, and this *can* fail (e.g. permission problems), so BackupPC *can*
potentially silently die after you get the ok.

What this means is: I got 'ok', so it's running makes no sense for daemon
processes. It's I can see it in 'ps', so it's running. Ok only means it
didn't fail for the more obvious reasons, or rather, not for those of the more
obvious reasons that could be tested beforehand :-).

 [...]
 backuppc@linux-pc5:/$ ls -ld /data
 drwxrwx---+ 3 root root 4096 Jan 18 23:00 /data

This is actually interesting. ACLs? SElinux? I'm referring to the + at the
end of drwxrwx---+. It might even be important, assuming your backuppc user
is *not* in the root group!?

More explicitly: these permissions seem strange to me, but I suppose someone
set them up this way (your distribution? your distribution's BackupPC
package?). Without the whole picture (ACLs, effective UID, GID and
supplementary groups of the running BackupPC process) I can't say whether
this will work or not, though if it didn't, BackupPC should fail before you
get the ok message, meaning you wouldn't get the ok message.

I'd normally have expected something like

 drwxr-xr-x 3 root root 4096 Jan 18 23:00 /data

Access to sensitive information below /data can be limited by subdirectory.
I don't see the point in hiding the subdirectories altogether.

 backuppc@linux-pc5:/$ ls -ld /data/BackupPC
 drwxrwx---+ 5 backuppc backuppc 4096 Jan 18 23:00 /data/BackupPC

Except for the +, that is what I'd expect here.

 [...]
 backuppc@linux-pc5:/$ tune2fs -l /dev/mapper/dreux-root
 tune2fs 1.42.12 (29-Aug-2014)
 tune2fs: Permission denied while trying to open /dev/mapper/dreux-root
 Couldn't find valid filesystem superblock.
 
 Is the output what was to be expected?

Yes. This is the understanding what you're doing part again. As non-root
user, you don't have permission to access the device file. The error message
is not Couldn't find ..., it's tune2fs: Permission denied ..., and it's
quite clear :-). Couldn't find ... is tune2fs's explanation why it gave up
as a result of not being allowed to read from the device.

If you want meaningful output, you'll need to run the tune2fs command as
root. And *before* you do, you might as well try

backuppc@linux-pc5:/$ df -T /data/BackupPC

and see if the type of the file system is really one of ext2, ext3, ext4;
otherwise 'tune2fs' is simply the wrong tool. All of that said, I'm not sure
why the OP wanted you to run tune2fs. Perhaps he wanted to see whether it
really is an ext[234] file system :-).

On a side note, if you're serious about running BackupPC, you definitely
*don't* want to have the pool on your root file system. For testing,
evaluation, and perhaps even debugging problems, you might be fine, but for
production use, you are asking for problems. You're apparently using LVM,
so creating an independent logical volume is really easy (presuming you
haven't allocated all of the space to your root FS).

 Or should my merely removing the linked target also remove the linked file?

No, that will never happen.

I hope some of that helps rather than confuses ...

Regards,
Holger

--
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
___
BackupPC-users mailing list
BackupPC-users@lists.sourceforge.net
List:https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/