|
|
|
@ -38,7 +38,7 @@ sub action |
|
|
|
|
|
|
|
|
|
# Start loop |
|
|
|
|
foreach my $host ( GetUserHosts(1) ) { |
|
|
|
|
my($fullDur, $incrCnt, $incrAge, $fullSize, $fullRate, $reasonHilite, |
|
|
|
|
my($incrCnt, $incrAge, $reasonHilite, |
|
|
|
|
$lastAge, $lastAgeColor, $tempState, $tempReason, $lastXferErrors, $lastXferErrorsColor); |
|
|
|
|
my($shortErr); |
|
|
|
|
my @Backups = $bpc->BackupInfoRead($host); |
|
|
|
@ -57,8 +57,6 @@ sub action |
|
|
|
|
$fullCnt++; |
|
|
|
|
if ( $fullAge < 0 || $Backups[$i]{startTime} > $fullAge ) { |
|
|
|
|
$fullAge = $Backups[$i]{startTime}; |
|
|
|
|
$fullSize = $Backups[$i]{size} / (1024 * 1024); |
|
|
|
|
$fullDur = $Backups[$i]{endTime} - $Backups[$i]{startTime}; |
|
|
|
|
} |
|
|
|
|
} elsif ( $Backups[$i]{type} eq "incr" ) { |
|
|
|
|
$incrCnt++; |
|
|
|
@ -88,18 +86,14 @@ sub action |
|
|
|
|
} |
|
|
|
|
if ( $fullAge < 0 ) { |
|
|
|
|
$fullAge = ""; |
|
|
|
|
$fullRate = ""; |
|
|
|
|
} else { |
|
|
|
|
$fullAge = sprintf("%.1f", (time - $fullAge) / (24 * 3600)); |
|
|
|
|
$fullRate = sprintf("%.2f", |
|
|
|
|
$fullSize / ($fullDur <= 0 ? 1 : $fullDur)); |
|
|
|
|
} |
|
|
|
|
if ( $incrAge < 0 ) { |
|
|
|
|
$incrAge = ""; |
|
|
|
|
} else { |
|
|
|
|
$incrAge = sprintf("%.1f", (time - $incrAge) / (24 * 3600)); |
|
|
|
|
} |
|
|
|
|
$fullSize = sprintf("%.2f", $fullSize / 1024); |
|
|
|
|
$incrAge = " " if ( $incrAge eq "" ); |
|
|
|
|
# Color for errors |
|
|
|
|
$lastXferErrors = $Backups[@Backups-1]{xferErrs} if ( @Backups ); |
|
|
|
|