/[BackupPC]/trunk/bin/BackupPC_updatedb
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/bin/BackupPC_updatedb

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 43 by dpavlin, Fri Aug 19 15:38:56 2005 UTC revision 44 by dpavlin, Sat Aug 20 11:24:55 2005 UTC
# Line 40  my $dbh = DBI->connect($dsn, "", "", { R Line 40  my $dbh = DBI->connect($dsn, "", "", { R
40    
41  my %opt;  my %opt;
42    
43  if ( !getopts("cdm:v", \%opt ) ) {  if ( !getopts("cdm:v:", \%opt ) ) {
44          print STDERR <<EOF;          print STDERR <<EOF;
45  usage: $0 [-c|-d] [-m num]  usage: $0 [-c|-d] [-m num] [-v|-v level]
46    
47  Options:  Options:
48          -c      create database on first use          -c      create database on first use
49          -d      delete database before import          -d      delete database before import
50          -m num  import just num increments for one host          -m num  import just num increments for one host
51            -v num  set verbosity (debug) level (default $debug)
52  EOF  EOF
53          exit 1;          exit 1;
54  }  }
# Line 210  foreach my $host_key (keys %{$hosts}) { Line 211  foreach my $host_key (keys %{$hosts}) {
211                  my @backupShares = ();                  my @backupShares = ();
212    
213                  print $hosts->{$host_key}->{'host'},                  print $hosts->{$host_key}->{'host'},
214                          "\t#$backupNum\t",                          "\t#$backupNum\t", $backup->{type} || '?', " ",
215                          $backup->{nFilesNew} || '?', "/", $backup->{nFiles} || '?',                          $backup->{nFilesNew} || '?', "/", $backup->{nFiles} || '?',
216                          " files\n";                          " files\n";
217    
# Line 305  sub recurseDir($$$$$$$$) { Line 306  sub recurseDir($$$$$$$$) {
306    
307          my ($bpc, $hostname, $files, $backupNum, $share, $dir, $shareID) = @_;          my ($bpc, $hostname, $files, $backupNum, $share, $dir, $shareID) = @_;
308    
309          print STDERR "recurse($hostname,$backupNum,$share,$dir,$shareID)\n" if ($debug >= 1);          print STDERR "\nrecurse($hostname,$backupNum,$share,$dir,$shareID)\n" if ($debug >= 1);
310    
311          my ($nr_files, $new_files, $nr_dirs, $new_dirs) = (0,0,0,0);          my ($nr_files, $new_files, $nr_dirs, $new_dirs) = (0,0,0,0);
312    

Legend:
Removed from v.43  
changed lines
  Added in v.44

  ViewVC Help
Powered by ViewVC 1.1.26