# Version __VERSION__, __RELEASEDATE__
#------------------------------------------------------------------------
+* The CSS definition has been removed from the config.pl file and
+ is now a separate file, BackupPC_stnd.css. A new config variable,
+ $Conf{CgiCSSFile}, gives the name of the CSS file to use.
+ Suggested by Ender Mathias.
+
+* Fixed the filling of the host name select box for admins.
+ The default $Conf{CgiNavBarAdminAllHosts} is now 1.
+ Reported by Doug Lytle.
+
+* Cleaned up warning message for restore using rsync when checksum
+ caching is on, but when file didn't have cached checksums.
+
+#------------------------------------------------------------------------
+# Version 2.1.0beta0, 20 Mar 2004
+#------------------------------------------------------------------------
+
* A failed full dump is now saved as a partial (incomplete) dump,
provided it includes some files. This can be used for browsing,
restoring etc, and will also form the basis of resuming full
if ( $Conf{FullPeriod} == -1 && !$opts{f} && !$opts{i}
|| $Conf{FullPeriod} == -2 ) {
print(STDERR "Exiting because backups are disabled with"
- . "\$Conf{FullPeriod} = $Conf{FullPeriod}\n") if ( $opts{v} );
+ . " \$Conf{FullPeriod} = $Conf{FullPeriod}\n") if ( $opts{v} );
#
# Tell BackupPC to ignore old failed backups on hosts that
# have backups disabled.
#
print("backups disabled\n")
- if ( $StatusHost{reason} ne "Reason_backup_done"
- && time - $StatusHost{startTime} > 2 * 24 * 3600 );
+ if ( defined($StatusHost{errorTime})
+ && $StatusHost{reason} ne "Reason_backup_done"
+ && time - $StatusHost{errorTime} > 4 * 24 * 3600 );
NothingToDo($needLink);
}
--- /dev/null
+/*
+ * BackupPC standard CSS definitions
+ *
+ * Version 2.1.0beta0, released 20 Mar 2004.
+ *
+ * See http://backuppc.sourceforge.net.
+ *
+ * AUTHOR
+ * Craig Barratt <cbarratt@users.sourceforge.net>
+ *
+ * COPYRIGHT
+ * Copyright (C) 2004 Craig Barratt
+ */
+
+body {
+ font-family:arial,sans-serif;
+ font-size:1em;
+ background-color:#ffffff;
+ margin:2px 5px 0px 2px;
+ height:100%
+}
+
+h1 {
+ font-family:arial,sans-serif;
+ font-size:1.5em;
+ color:#000000
+}
+
+h2 {
+ font-family:arial,sans-serif;
+ font-size:1em;
+ color:#000000
+}
+
+p {
+ font-family:arial,sans-serif;
+ font-size:.9em
+}
+
+a {
+ font-family:arial,sans-serif;
+ color:#3333ff
+}
+
+li {
+ font-size:.9em;
+}
+
+a:hover {
+ color:#cc0000;
+ text-decoration:none
+}
+
+a.NavCurrent {
+ font-weight:bold;
+}
+
+a.navbar {
+ padding-left:5px;
+ padding-right:5px;
+}
+
+.h1 {
+ font-family:arial,sans-serif;
+ font-size:1.5em;
+ color:#000000;
+ font-weight:bold;
+ background-color:#99cc33;
+ padding:3px;
+ padding-left:6px;
+ margin-bottom:5px;
+}
+
+.h2 {
+ font-family:arial,sans-serif;
+ font-size:1em;
+ color:#000000;
+ font-weight:bold;
+ background-color:#ddeeee;
+ padding:3px;
+ padding-left:6px;
+ margin-top:3px;
+ margin-bottom:1px;
+}
+
+.tableStnd {
+}
+
+.tableheader {
+ font-size:.8em;
+ font-weight:bold;
+ background-color:#cccccc;
+}
+
+.border {
+ font-size:.9em;
+}
+
+.fviewheader {
+ font-weight:bold;
+ font-size:.8em;
+ color:#ffffff;
+ background-color:#999999;
+}
+
+.fviewborder {
+ border-bottom:1px solid #000000;
+ border-left:1px dotted #666666;
+ background-color:#dddddd;
+ font-size:.9em;
+}
+
+.fviewon {
+ background-color:#cccccc;
+}
+
+.fviewoff {
+ background-color:#ffffff;
+}
+
+.fview {
+ font-size:.8em;
+ font-family:arial,sans-serif;
+ text-decoration:none;
+ line-height:15px;
+}
+
+.fviewbold {
+ font-size:.9em;
+ font-family:arial,sans-serif;
+ text-decoration:none;
+ line-height:15px;
+ font-weight:bold;
+}
+
+.histView {
+ border-bottom:1px solid #000000;
+ border-left:2px solid #ffffff;
+ background-color:#dddddd;
+ font-size:.9em;
+}
+
+.histViewMis {
+ border-bottom:1px solid #000000;
+ background-color:#ffdddd;
+}
+
+div.NavMenu {
+ width:18%;
+ margin:0px;
+ background-color:#ddeeee;
+}
+
+div.NavMenu a {
+ font-size:.8em;
+ display:block;
+ margin-left:8px;
+ padding:2px;
+}
+
+div.NavTitle {
+ padding-left:10px;
+ background-color:#99cc33;
+ font-family:arial,sans-serif;
+ color:#000000;
+ font-weight:bold;
+ margin-bottom:2px;
+}
+
+#Content {
+ float:right;
+ width:80%;
+ left:20%;
+ top:10px;
+ position:absolute;
+}
#
# The default value is every hour except midnight.
#
+# The first entry of $Conf{WakeupSchedule} is when BackupPC_nightly
+# is run. No other backups can run while BackupPC_nightly is
+# running. You might want to re-arrange the entries in
+# $Conf{WakeupSchedule} (they don't have to be ascending) so that
+# the first entry is when you want BackupPC_nightly to run
+# (eg: when you don't expect a lot of regular backups to run).
+#
$Conf{WakeupSchedule} = [1..23];
#
# being backed up (eg: a retired machine), but you wish to keep the
# last backups available for browsing or restoring to other machines.
#
-# Also, you might create a virtual client (by setting $Conf{ClientNameAlias})
-# for restoring to a DVD or permanent media and you would set
-# $Conf{FullPeriod} to -2 so that it is never backed up.
-#
$Conf{FullPeriod} = 6.97;
#
'--times',
'--block-size=2048',
'--recursive',
+
+ #
+ # If you are using a patched client rsync that supports the
+ # --fixed-csumseed option (see http://backuppc.sourceforge.net),
+ # then uncomment this to enabled rsync checksum cachcing
+ #
+ #'--fixed-csumseed',
+
#
# Add additional arguments here
#
#
# Do not edit these!
#
- "--numeric-ids",
- "--perms",
- "--owner",
- "--group",
- "--devices",
- "--links",
- "--times",
- "--block-size=2048",
- "--relative",
- "--ignore-times",
- "--recursive",
+ '--numeric-ids',
+ '--perms',
+ '--owner',
+ '--group',
+ '--devices',
+ '--links',
+ '--times',
+ '--block-size=2048',
+ '--relative',
+ '--ignore-times',
+ '--recursive',
+
+ #
+ # If you are using a patched client rsync that supports the
+ # --fixed-csumseed option (see http://backuppc.sourceforge.net),
+ # then uncomment this to enabled rsync checksum cachcing
+ #
+ #'--fixed-csumseed',
+
#
# Add additional arguments here
#
#
# If set, the complete list of hosts appears in the left navigation
-# bar for administrators. Otherwise, just the hosts for which the
-# user is listed in the host file (as either the user or in moreUsers)
+# bar pull-down for administrators. Otherwise, just the hosts for which
+# the user is listed in the host file (as either the user or in moreUsers)
# are displayed.
#
-$Conf{CgiNavBarAdminAllHosts} = 0;
+$Conf{CgiNavBarAdminAllHosts} = 1;
#
# Hilight colors based on status that are used in the PC summary page.
$Conf{CgiImageDirURL} = '';
#
-# CSS stylesheet for the CGI interface.
-#
-$Conf{CSSstylesheet} = <<'EOF';
-<style type="text/css">
-body {
- font-family:arial,sans-serif;
- font-size:1em;
- background-color:#ffffff;
- margin:2px 5px 0px 2px;
- height:100%
-}
-
-h1 {
- font-family:arial,sans-serif;
- font-size:1.5em;
- color:#000000
-}
-
-h2 {
- font-family:arial,sans-serif;
- font-size:1em;
- color:#000000
-}
-
-p {
- font-family:arial,sans-serif;
- font-size:.9em
-}
-
-a {
- font-family:arial,sans-serif;
- color:#3333ff
-}
-
-li {
- font-size:.9em;
-}
-
-a:hover {
- color:#cc0000;
- text-decoration:none
-}
-
-a.NavCurrent {
- font-weight:bold;
-}
-
-a.navbar {
- padding-left:5px;
- padding-right:5px;
-}
-
-.h1 {
- font-family:arial,sans-serif;
- font-size:1.5em;
- color:#000000;
- font-weight:bold;
- background-color:#99cc33;
- padding:3px;
- padding-left:6px;
- margin-bottom:5px;
-}
-
-.h2 {
- font-family:arial,sans-serif;
- font-size:1em;
- color:#000000;
- font-weight:bold;
- background-color:#ddeeee;
- padding:3px;
- padding-left:6px;
- margin-top:3px;
- margin-bottom:1px;
-}
-
-.tableStnd {
-}
-
-.tableheader {
- font-size:.8em;
- font-weight:bold;
- background-color:#cccccc;
-}
-
-.border {
- font-size:.9em;
-}
-
-.fviewheader {
- font-weight:bold;
- font-size:.8em;
- color:#ffffff;
- background-color:#999999;
-}
-
-.fviewborder {
- border-bottom:1px solid #000000;
- border-left:1px dotted #666666;
- background-color:#dddddd;
- font-size:.9em;
-}
-
-.fviewon {
- background-color:#cccccc;
-}
-
-.fviewoff {
- background-color:#ffffff;
-}
-
-.fview {
- font-size:.8em;
- font-family:arial,sans-serif;
- text-decoration:none;
- line-height:15px;
-}
-
-.fviewbold {
- font-size:.9em;
- font-family:arial,sans-serif;
- text-decoration:none;
- line-height:15px;
- font-weight:bold;
-}
-
-.histView {
- border-bottom:1px solid #000000;
- border-left:2px solid #ffffff;
- background-color:#dddddd;
- font-size:.9em;
-}
-
-.histViewMis {
- border-bottom:1px solid #000000;
- background-color:#ffdddd;
-}
-
-div.NavMenu {
- width:18%;
- margin:0px;
- background-color:#ddeeee;
-}
-
-div.NavMenu a {
- font-size:.8em;
- display:block;
- margin-left:8px;
- padding:2px;
-}
-
-div.NavTitle {
- padding-left:10px;
- background-color:#99cc33;
- font-family:arial,sans-serif;
- color:#000000;
- font-weight:bold;
- margin-bottom:2px;
-}
-
-#Content {
- float:right;
- width:80%;
- left:20%;
- top:10px;
- position:absolute;
-}
-</style>
-EOF
+# CSS stylesheet for the CGI interface. It is stored in the
+# $Conf{CgiImageDir} directory and accessed via the
+# $Conf{CgiImageDirURL} URL.
+#
+$Conf{CgiCSSFile} = 'BackupPC_stnd.css';
(my $destImg = $img) =~ s{^images/}{};
InstallFile($img, "$Conf{CgiImageDir}/$destImg", 0444, 1);
}
+
+ #
+ # Install new CSS file, making a backup copy if necessary
+ #
+ my $cssBackup = "$Conf{CgiImageDir}/BackupPC_stnd.css.pre-__VERSION__";
+ if ( -f "$Conf{CgiImageDir}/BackupPC_stnd.css" && !-f $cssBackup ) {
+ rename("$Conf{CgiImageDir}/BackupPC_stnd.css", $cssBackup);
+ }
+ InstallFile("conf/BackupPC_stnd.css",
+ "$Conf{CgiImageDir}/BackupPC_stnd.css", 0444, 0);
}
printf("Making init.d scripts\n");
delete($Conf{SmbClientArgs});
}
+#
+# CSS is now stored in a file rather than a big config variable.
+#
+delete($Conf{CSSstylesheet});
+
#
# The blackout timing settings are now stored in a list of hashes, rather
# than three scalar parameters.
#
# $Conf{RsyncLogLevel} has been replaced by $Conf{XferLogLevel}
#
-$Conf{XferLogLevel} = $Conf{RsyncLogLevel};
+if ( defined($Conf{RsyncLogLevel}) ) {
+ $Conf{XferLogLevel} = $Conf{RsyncLogLevel};
+ delete($Conf{RsyncLogLevel});
+}
+
+#
+# In 2.1.0 the default for $Conf{CgiNavBarAdminAllHosts} is now 1
+#
+$Conf{CgiNavBarAdminAllHosts} = 1;
#
# IncrFill should now be off
=item Full Backup
-A full backup is a complete backup of a share. BackupPC can be configured to
-do a full backup at a regular interval (often weekly). BackupPC can also
-be configured to keep a certain number of full backups, and to keep
-a smaller number of very old full backups.
+A full backup is a complete backup of a share. BackupPC can be
+configured to do a full backup at a regular interval (typically
+weekly). BackupPC can be configured to keep a certain number
+of full backups. Exponential expiry is also supported, allowing
+full backups with various vintages to be kept (for example, a
+settable number of most recent weekly fulls, plus a settable
+number of older fulls that are 2, 4, 8, or 16 weeks apart).
=item Incremental Backup
last full backup, giving every backup a "full" appearance. This makes
browsing and restoring backups easier.
+=item Partial Backup
+
+When a full backup fails or is canceled, and some files have already
+been backed up, BackupPC keeps a partial backup containing just the
+files that were backed up successfully. The partial backup is removed
+when the next successful backup completes, or if another full backup
+fails resulting in a newer partial backup. A failed full backup
+that has not backed up any files, or any failed incremental backup,
+is removed; no partial backup is saved in these cases.
+
+The partial backup may be browsed or used to restore files just like
+a successful full or incremental backup.
+
+With the rsync transfer method the partial backup is used to resume
+the next full backup, avoiding the need to retransfer the file data
+already in the partial backup.
+
=item Identical Files
BackupPC pools identical files using hardlinks. By "identical
sub action
{
my $archHost = $In{host};
+ my $Privileged = CheckPermission();
+ if ( !$Privileged ) {
+ ErrorExit($Lang->{Only_privileged_users_can_archive} );
+ }
if ( $In{type} == 0 ) {
my($fullTot, $fullSizeTot, $incrTot, $incrSizeTot, $str,
$strNone, $strGood, $hostCntGood, $hostCntNone, $checkBoxCnt,
$hostCntGood = $hostCntNone = $checkBoxCnt = $fullSizeTot = 0;
GetStatusInfo("hosts");
- my $Privileged = CheckPermission();
- if ( !$Privileged ) {
- ErrorExit($Lang->{Only_privileged_users_can_archive} );
- }
foreach my $host ( sort(keys(%Status)) ) {
my($fullDur, $incrCnt, $fullSize, $fullRate);
my @Backups = $bpc->BackupInfoRead($host);
} else {
my(@HostList, @BackupList, $HostListStr, $hiddenStr, $pathHdr,
$badFileCnt, $reply, $str);
- my $Privileged = CheckPermission();
my $args = {
SplitPath => $bpc->{Conf}{SplitPath},
ParPath => $bpc->{Conf}{ParPath},
topDir => $bpc->{TopDir},
};
- if ( !$Privileged ) {
- ErrorExit($Lang->{Only_privileged_users_can_archive} );
- }
ServerConnect();
for ( my $i = 0 ; $i < $In{fcbMax} ; $i++ ) {
$Privileged ||= $Conf{CgiAdminUsers} eq "*";
}
$PrivAdmin = $Privileged;
+ return $Privileged if ( !defined($host) );
+
$Privileged ||= $User eq $Hosts->{$host}{user};
$Privileged ||= defined($Hosts->{$host}{moreUsers}{$User});
-
return $Privileged;
}
#
sub GetUserHosts
{
- my($host, $getAll) = @_;
+ my($getAll) = @_;
my @hosts;
if ( $getAll && CheckPermission() ) {
<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head>
<title>$title</title>
-$Conf{CSSstylesheet}
+<link rel=stylesheet type="text/css" href="$Conf{CgiImageDirURL}/$Conf{CgiCSSFile}" title="CSSFile">
$Conf{CgiHeaders}
</head><body onLoad="document.getElementById('NavMenu').style.height=document.body.scrollHeight">
<img src="$Conf{CgiImageDirURL}/logo.gif" hspace="5" vspace="7"><br>
<div class="NavMenu" id="NavMenu" style="height:100%">
EOF
my $hostSelectbox = "<option value=\"#\">$Lang->{Select_a_host}</option>";
- my @hosts = GetUserHosts($In{host}, $Conf{CgiNavBarAdminAllHosts});
+ my @hosts = GetUserHosts($Conf{CgiNavBarAdminAllHosts});
if ( defined($Hosts) && %$Hosts > 0 && @hosts ) {
NavSectionTitle($Lang->{Hosts});
foreach my $host ( @hosts ) {
#
my $hostDestSel;
my @hosts;
- foreach my $h ( GetUserHosts() ) {
+ foreach my $h ( GetUserHosts(1) ) {
my $sel = " selected" if ( $h eq $In{host} );
$hostDestSel .= "<option value=\"$h\"$sel>${EscHTML($h)}</option>";
push(@hosts, $h);
my $targetFile = $f;
(my $strippedShare = $share) =~ s/^\///;
(my $strippedShareDest = $In{shareDest}) =~ s/^\///;
- substr($targetFile, 0, length($pathHdr)) = $In{pathHdr};
+ substr($targetFile, 0, length($pathHdr)) = "/$In{pathHdr}/";
+ $targetFile =~ s{//+}{/}g;
$fileListStr .= <<EOF;
<tr><td>$host:/$strippedShare$f</td><td>$In{hostDest}:/$strippedShareDest$targetFile</td></tr>
EOF
$reqFileName = "restoreReq.$$.$i";
last if ( !-f "$TopDir/pc/$hostDest/$reqFileName" );
}
+ my $inPathHdr = $In{pathHdr};
+ $inPathHdr = "/$inPathHdr" if ( $inPathHdr !~ m{^/} );
+ $inPathHdr = "$inPathHdr/" if ( $inPathHdr !~ m{/$} );
my %restoreReq = (
# source of restore is hostSrc, #num, path shareSrc/pathHdrSrc
num => $In{num},
# destination of restore is hostDest:shareDest/pathHdrDest
hostDest => $hostDest,
shareDest => $In{shareDest},
- pathHdrDest => $In{pathHdr},
+ pathHdrDest => $inPathHdr,
# list of files to restore
fileList => \@fileList,
(my $strippedShareDest = $RestoreReq{shareDest}) =~ s/^\///;
substr($targetFile, 0, length($RestoreReq{pathHdrSrc}))
= $RestoreReq{pathHdrDest};
+ $targetFile =~ s{//+}{/}g;
$fileListStr .= <<EOF;
<tr><td>$RestoreReq{hostSrc}:/$strippedShareSrc$f</td><td>$RestoreReq{hostDest}:/$strippedShareDest$targetFile</td></tr>
EOF
}
- my $content = eval("qq{$Lang->{Restore___num_details_for__host2 }}");
+ my $content = eval("qq{$Lang->{Restore___num_details_for__host2}}");
Header(eval("qq{$Lang->{Restore___num_details_for__host}}"),$content);
Trailer();
}
GetStatusInfo("hosts");
my $Privileged = CheckPermission();
- foreach my $host ( GetUserHosts(undef, 1) ) {
+ foreach my $host ( GetUserHosts(1) ) {
my($fullDur, $incrCnt, $incrAge, $fullSize, $fullRate, $reasonHilite);
my($shortErr);
my @Backups = $bpc->BackupInfoRead($host);
my $fullCnt = $incrCnt = 0;
my $fullAge = $incrAge = -1;
- if ( defined(my $error = $bpc->ConfigRead($host)) ) {
- print("dump failed: Can't read PC's config file: $error\n");
- exit(1);
- }
+ $bpc->ConfigRead($host);
%Conf = $bpc->Conf();
- if ($Conf{XferMethod} eq "archive" ) {
+ if ( $Conf{XferMethod} eq "archive" ) {
next;
}
# ------------------------------
$Lang{Restore___num_details_for__host} = "BackupServer: Restore #\$num Details für Computer \$host";
-$Lang{Restore___num_details_for__host2 } = <<EOF;
+$Lang{Restore___num_details_for__host2} = <<EOF;
\${h1("Restore #\$num Details für Computer \$host")}
<p>
-<table class="tableStnd" border cellspacing="1" cellpadding="3" width="50%">
+<table class="tableStnd" border cellspacing="1" cellpadding="3" width="90%">
<tr><td class="tableheader"> Nummer </td><td class="border"> \$Restores[\$i]{num} </td></tr>
<tr><td class="tableheader"> beauftragt von </td><td class="border"> \$RestoreReq{user} </td></tr>
<tr><td class="tableheader"> Auftrag Zeitpunkt </td><td class="border"> \$reqTime </td></tr>
#$Lang{Host_or_User_name} = "<small>Computer oder User Name:</small>";
$Lang{Go} = "gehe zu";
$Lang{Hosts} = "Computer";
-$Lang{Select_a_host} = "ENGLISH Select a host...";
+$Lang{Select_a_host} = "Computer auswählen...";
$Lang{There_have_been_no_archives} = "<h2> Es existieren keine Archive </h2>\n";
$Lang{This_PC_has_never_been_backed_up} = "<h2> Dieser Computer wurde nie gesichert!! </h2>\n";
# ------------------------------
$Lang{Restore___num_details_for__host} = "BackupPC: Restore #\$num details for \$host";
-$Lang{Restore___num_details_for__host2 } = <<EOF;
+$Lang{Restore___num_details_for__host2} = <<EOF;
\${h1("Restore #\$num Details for \$host")}
<p>
-<table class="tableStnd" border cellspacing="1" cellpadding="3" width="50%">
+<table class="tableStnd" border cellspacing="1" cellpadding="3" width="90%">
<tr><td class="tableheader"> Number </td><td class="border"> \$Restores[\$i]{num} </td></tr>
<tr><td class="tableheader"> Requested by </td><td class="border"> \$RestoreReq{user} </td></tr>
<tr><td class="tableheader"> Request time </td><td class="border"> \$reqTime </td></tr>
# ------------------------------
$Lang{Restore___num_details_for__host} = "BackupPC: Detalles de la restauración Nº\$num de \$host";
-$Lang{Restore___num_details_for__host2 } = <<EOF;
+$Lang{Restore___num_details_for__host2} = <<EOF;
\${h1("Detalles de la restauración Nº\$num de \$host")}
<p>
-<table class="tableStnd" border cellspacing="1" cellpadding="3" width="50%">
+<table class="tableStnd" border cellspacing="1" cellpadding="3" width="90%">
<tr><td class="tableheader"> Número </td><td class="border"> \$Restores[\$i]{num} </td></tr>
<tr><td class="tableheader"> Solicitado por </td><td class="border"> \$RestoreReq{user} </td></tr>
<tr><td class="tableheader"> Hora Petición </td><td class="border"> \$reqTime </td></tr>
# ------------------------------
$Lang{Restore___num_details_for__host} = "BackupPC: Détails de la restauration n° \$num pour \$host";
-$Lang{Restore___num_details_for__host2 } = <<EOF;
+$Lang{Restore___num_details_for__host2} = <<EOF;
\${h1("Détails de la restauration n° \$num pour \$host")}
<p>
-<table class="tableStnd" border cellspacing="1" cellpadding="3" width="50%">
+<table class="tableStnd" border cellspacing="1" cellpadding="3" width="90%">
<tr><td class="tableheader"> Numéro </td><td class="border"> \$Restores[\$i]{num} </td></tr>
<tr><td class="tableheader"> Demandée par </td><td class="border"> \$RestoreReq{user} </td></tr>
<tr><td class="tableheader"> Demandée à </td><td class="border"> \$reqTime </td></tr>
#!/bin/perl
#
-# $Id: it.pm,v 1.4 2004/03/21 01:46:46 cbarratt Exp $
+# $Id: it.pm,v 1.5 2004/03/29 19:05:24 cbarratt Exp $
#
# Italian i18n file
#
# ------------------------------
$Lang{Restore___num_details_for__host} = "BackupPC: dettagli ripristino numero \$num per \$host";
-$Lang{Restore___num_details_for__host2 } = <<EOF;
+$Lang{Restore___num_details_for__host2} = <<EOF;
\${h1("Dettagli ripristino numero \$num per \$host")}
<p>
-<table class="tableStnd" border cellspacing="1" cellpadding="3" width="50%">
+<table class="tableStnd" border cellspacing="1" cellpadding="3" width="90%">
<tr><td class="tableheader"> Numero </td><td class="border"> \$Restores[\$i]{num} </td></tr>
<tr><td class="tableheader"> Richiesto da </td><td class="border"> \$RestoreReq{user} </td></tr>
<tr><td class="tableheader"> Data richiesta </td><td class="border"> \$reqTime </td></tr>
return $self;
}
-my $BufSize = 1048576; # 1MB or 2^20
-my $MaxFiles = 20;
+my $BufSize = 1048576; # 1MB or 2^20
+my $MaxFiles = 20; # max number of compare files open at one time
sub write
{
#
if ( !defined($dataRef) && !defined($a->{digest})
&& $a->{fileSize} != length($a->{data}) ) {
+ #my $newSize = length($a->{data});
+ #print("Fixing file size from $a->{fileSize} to $newSize\n");
$a->{fileSize} = length($a->{data});
}
push(@{$a->{errors}}, "Can't rename $a->{fileName} -> $fileName"
. " or open during size fixup\n");
}
+ #print("Using temporary name $fileName\n");
} elsif ( defined($a->{files}) && defined($a->{files}[0]) ) {
#
# We haven't written anything yet, so just use the
#
$fh = $a->{files}[0]->{fh};
$fh->rewind;
+ #print("Using compare file $a->{files}[0]->{name}\n");
}
if ( defined($fh) ) {
my $poolWrite = BackupPC::PoolWrite->new($a->{bpc}, $a->{fileName},
{
my($fio, $f, $needMD4, $defBlkSize) = @_;
+ $defBlkSize ||= $fio->{blockSize};
my $attr = $fio->attribGet($f);
$fio->{file} = $f;
$fio->csumEnd if ( defined($fio->{csum}) );
umask(0022);
-my $Version = "2.1.0beta0";
-my $ReleaseDate = "20 Mar 2004";
+my $Version = "2.1.0beta0_CVS";
+my $ReleaseDate = "29 Mar 2004";
my $DistDir = "dist/BackupPC-$Version";
my @PerlSrc = qw(
qw(
conf/config.pl
conf/hosts
+ conf/BackupPC_stnd.css
init.d/README
init.d/src/debian-backuppc
init.d/src/gentoo-backuppc
binmode(FILE);
binmode(OUT);
while ( <FILE> ) {
- s/^# *Version \d+\.\d+[\.\w]*, released \d+ \w+ \d{4}\.?/# Version __VERSION__, released __RELEASEDATE__./;
+ s/^([#*\s]+)Version \d+\.\d+[\.\w]*, released \d+ \w+ \d{4}\.?/$1Version __VERSION__, released __RELEASEDATE__./;
s/__VERSION__/$Version/g;
s/__RELEASEDATE__/$ReleaseDate/g;
if ( $file =~ /BackupPC\.html$/ ) {