projects
/
BackupPC.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
74baa82
)
fix backup selection
author
Dobrica Pavlinusic
<dpavlin@rot13.org>
Fri, 28 Jan 2011 22:41:20 +0000
(23:41 +0100)
committer
Dobrica Pavlinusic
<dpavlin@rot13.org>
Fri, 28 Jan 2011 22:41:20 +0000
(23:41 +0100)
lib/BackupPC/CGI/Archive.pm
patch
|
blob
|
history
diff --git
a/lib/BackupPC/CGI/Archive.pm
b/lib/BackupPC/CGI/Archive.pm
index
c6f2d40
..
24ebaac
100644
(file)
--- a/
lib/BackupPC/CGI/Archive.pm
+++ b/
lib/BackupPC/CGI/Archive.pm
@@
-84,6
+84,7
@@
use Data::Dump qw(dump);
my $dbh = DBI->connect($Conf{SearchDSN}, $Conf{SearchUser}, "", { RaiseError => 1, AutoCommit => 0 });
my $sth = $dbh->prepare(qq{
select
my $dbh = DBI->connect($Conf{SearchDSN}, $Conf{SearchUser}, "", { RaiseError => 1, AutoCommit => 0 });
my $sth = $dbh->prepare(qq{
select
+ hosts.name as host, -- FIXME for debug
backups.num as num,
inc_size,
size,
backups.num as num,
inc_size,
size,
@@
-99,12
+100,12
@@
warn "# row ",dump $row;
$all_backup_numbers->{ $row->{num} } =
$row->{inc_deleted} ? 0 :
$row->{size} == 0 ? 0 :
$all_backup_numbers->{ $row->{num} } =
$row->{inc_deleted} ? 0 :
$row->{size} == 0 ? 0 :
- $row->{inc_size}
< 0 ? 1
:
+ $row->{inc_size}
> 0 ? 0
:
$row->{size} > 0 ? 1 :
0;
}
$row->{size} > 0 ? 1 :
0;
}
-warn dump($all_backup_numbers);
+warn
"# host $host all_backup_numbers = ",
dump($all_backup_numbers);
my @backup_nums =
sort
grep { $all_backup_numbers->{$_} }
my @backup_nums =
sort
grep { $all_backup_numbers->{$_} }
@@
-266,7
+267,7
@@
EOF
$compname = $Conf{CatPath};
$compext = '.raw';
}
$compname = $Conf{CatPath};
$compext = '.raw';
}
- my $fullsplitsize = $In{splitsize} . '000000';
+ my $fullsplitsize = $In{splitsize} . '000000';
# mb -> bytes
my %ArchiveReq = (
# parameters for the archive
archiveloc => $In{archive_device},
my %ArchiveReq = (
# parameters for the archive
archiveloc => $In{archive_device},