Backport commit to count common rsync xfer errors

GLPI #34026
f5904a1f40
tags/BackupPC4-4.2.1-2
Daniel Berteaud 6 years ago
parent d8fc65d00b
commit 7e16d61871
  1. 16
      BackupPC4-4.2.1-count_rsync_xfer_errors.patch

@ -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);
Loading…
Cancel
Save