X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=bin%2FBackupPC_tarIncCreate;h=a76e439fd35ada547a487909d1cee5b2e14cb2db;hp=e7474662de35a5606fa3496bfd64e05af9715b0c;hb=d1bfa4d92bec24954f2e7877f6531644bb84e8f3;hpb=34ffbfef58638c9db42ea49e784751a0fb0e0365 diff --git a/bin/BackupPC_tarIncCreate b/bin/BackupPC_tarIncCreate index e747466..a76e439 100755 --- a/bin/BackupPC_tarIncCreate +++ b/bin/BackupPC_tarIncCreate @@ -61,7 +61,7 @@ use strict; no utf8; -use lib "__INSTALLDIR__/lib"; +use lib "/usr/local/BackupPC/lib"; use File::Path; use Getopt::Std; use DBI; @@ -69,7 +69,7 @@ use BackupPC::Lib; use BackupPC::Attrib qw(:all); use BackupPC::FileZIO; use BackupPC::View; -use BackupPC::SearchLib; +use BackupPC::Search; use Time::HiRes qw/time/; use POSIX qw/strftime/; use File::Which; @@ -80,7 +80,7 @@ die("BackupPC::Lib->new failed\n") if ( !(my $bpc = BackupPC::Lib->new) ); my $TopDir = $bpc->TopDir(); my $BinDir = $bpc->BinDir(); my %Conf = $bpc->Conf(); -%BackupPC::SearchLib::Conf = %Conf; +%BackupPC::Search::Conf = %Conf; my %opts; my $in_backup_increment; @@ -196,12 +196,12 @@ my(%HardLinkExtraFiles, @HardLinks); # Write out all the requested files/directories # -my $max_file_size = $Conf{'MaxArchiveFileSize'} || die "problem with MaxArchiveFileSize parametar"; +my $max_file_size = $Conf{'ArchiveChunkSize'} || die "problem with MaxArchiveFileSize parametar"; -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); -my $tar_file = BackupPC::SearchLib::getGzipName($Host, $ShareName, $Num) || die "can't getGzipName($Host, $ShareName, $Num)"; +my $tar_file = BackupPC::Search::getGzipName($Host, $ShareName, $Num) || die "can't getGzipName($Host, $ShareName, $Num)"; my $tar_path_final = $tar_dir . '/' . $tar_file; my $tar_path = $tar_path_final . '.tmp'; @@ -657,7 +657,7 @@ sub TarWriteFile my $size = $in_backup_increment->{$tarPath}; return unless (defined($size)); - # is this file too large to fit into MaxArchiveFileSize? + # is this file too large to fit into ArchiveChunkSize? if ( ($current_tar_size + tar_overhead($tarPath) + $size) > $max_file_size ) { print STDERR "# tar file $current_tar_size + $tar_header_length + $size > $max_file_size, splitting\n" if ($opts{d});