Backport commit to count common rsync xfer errors

GLPI #34026
f5904a1f40
This commit is contained in:
Daniel Berteaud 2018-11-05 15:45:33 +01:00
parent d8fc65d00b
commit 7e16d61871
1 changed files with 16 additions and 0 deletions

View File

@ -0,0 +1,16 @@
diff -Nur -x '*.orig' -x '*.rej' BackupPC-4.2.1/lib/BackupPC/Xfer/Rsync.pm mezzanine_patched_BackupPC-4.2.1/lib/BackupPC/Xfer/Rsync.pm
--- BackupPC-4.2.1/lib/BackupPC/Xfer/Rsync.pm 2018-05-07 19:14:29.000000000 +0200
+++ mezzanine_patched_BackupPC-4.2.1/lib/BackupPC/Xfer/Rsync.pm 2018-11-05 15:43:26.616901808 +0100
@@ -546,6 +546,12 @@
}
$t->{stats}{xferErrs}++;
}
+ if ( /^rsync error: / || /^rsync warning: / ) {
+ $t->{stats}{xferErrs}++;
+ }
+ if ( /^rsync: send_files failed to open / || /^file has vanished: / ) {
+ $t->{stats}{xferErrs}++;
+ }
if ( /^IOrename:\s(\d+)\s(.*)/ ) {
my $oldName = substr($2, 0, $1);
my $newName = substr($2, $1);