X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=bin%2FBackupPC_nightly;h=560115b1a5c62bb5b7fccbde32b2134da235b27a;hp=03d5e2df0ba591d7fa4c4f202b348d0eeada991a;hb=d13d57e035dac9362ca393991b978530402969b7;hpb=79e0593c501fd58046feeca20c315cc4ac283435 diff --git a/bin/BackupPC_nightly b/bin/BackupPC_nightly index 03d5e2d..560115b 100755 --- a/bin/BackupPC_nightly +++ b/bin/BackupPC_nightly @@ -52,7 +52,7 @@ # #======================================================================== # -# Version 2.1.0beta2, released 23 May 2004. +# Version 2.1.0, released 20 Jun 2004. # # See http://backuppc.sourceforge.net. # @@ -127,6 +127,7 @@ my $fileCntRep; # total number of file names containing "_", ie: files my $fileRepMax; # worse case number of files that have repeated checksums # (ie: max(nnn+1) for all names xxxxxxxxxxxxxxxx_nnn) my $fileLinkMax; # maximum number of hardlinks on a pool file +my $fileLinkTotal; # total number of hardlinks on entire pool my $fileCntRename; # number of renamed files (to keep file numbering # contiguous) my %FixList; # list of paths that need to be renamed to avoid @@ -148,7 +149,8 @@ for my $pool ( qw(pool cpool) ) { $fileLinkMax = 0; $fileCntRename = 0; %FixList = (); - find({wanted => \&GetPoolStats}, "$TopDir/$pool/$dir"); + find({wanted => \&GetPoolStats}, "$TopDir/$pool/$dir") + if ( -d "$TopDir/$pool/$dir" ); my $kb = $blkCnt / 2; my $kbRm = $blkCntRm / 2; my $kb2 = $blkCnt2 / 2; @@ -193,7 +195,7 @@ for my $pool ( qw(pool cpool) ) { } print("BackupPC_stats $i = $pool,$fileCnt,$dirCnt,$kb,$kb2,$kbRm," . "$fileCntRm,$fileCntRep,$fileRepMax," - . "$fileCntRename,$fileLinkMax\n"); + . "$fileCntRename,$fileLinkMax,$fileLinkTotal\n"); } } @@ -282,5 +284,6 @@ sub GetPoolStats $blkCnt += $nblocks; $blkCnt2 += $nblocks if ( $nlinks == 2 ); $fileLinkMax = $nlinks if ( $fileLinkMax < $nlinks ); + $fileLinkTotal += $nlinks - 1; } }