X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=bin%2FBackupPC_incPartsUpdate;h=442c027221e86c56efdd79e5bbed94f1ec69297d;hp=2a5913aa71efd383e0105872bf9115030d7036a8;hb=6fa75ef8b610d0781b9a967d6a3557378f3a4003;hpb=058b71c16080bbc994a50245729e5e1cc14587e3 diff --git a/bin/BackupPC_incPartsUpdate b/bin/BackupPC_incPartsUpdate index 2a5913a..442c027 100755 --- a/bin/BackupPC_incPartsUpdate +++ b/bin/BackupPC_incPartsUpdate @@ -72,8 +72,8 @@ $pidfile->write; my $bpc = BackupPC::Lib->new || die "can't create BackupPC::Lib"; my %Conf = $bpc->Conf(); -use BackupPC::SearchLib; -%BackupPC::SearchLib::Conf = %Conf; +use BackupPC::Search; +%BackupPC::Search::Conf = %Conf; my $path = abs_path($0); $path =~ s#/[^/]+$#/#; @@ -97,7 +97,7 @@ my $user = $Conf{SearchUser} || ''; my $dbh = DBI->connect($dsn, $user, "", { RaiseError => 1, AutoCommit => 0 }); -my $tar_dir = $Conf{InstallDir}.'/'.$Conf{GzipTempDir}; +my $tar_dir = $Conf{GzipTempDir}; die "problem with $tar_dir, check GzipTempDir in configuration\n" unless (-d $tar_dir && -w $tar_dir); @@ -413,10 +413,10 @@ while (my $row = $sth->fetchrow_hashref) { $curr_backup++; - my $tar_file = BackupPC::SearchLib::getGzipName($row->{'host'}, $row->{'share'}, $row->{'num'}); + my $tar_file = BackupPC::Search::getGzipName($row->{'host'}, $row->{'share'}, $row->{'num'}); # this will return -1 if file doesn't exist - my $size = BackupPC::SearchLib::get_tgz_size_by_name($tar_file); + my $size = BackupPC::Search::get_tgz_size_by_name($tar_file); print "# host: ".$row->{host}.", share: ".$row->{'share'}.", backup_num:".$row->{num}." size: $size backup.size: ", $row->{inc_size},"\n" if ($opt{d});