Skip to content

Commit 0e6be99

Browse files
author
cbarratt
committed
* documentation updates
* added init.d/src/freebsd-backuppc2
1 parent 1015740 commit 0e6be99

File tree

2 files changed

+93
-50
lines changed

2 files changed

+93
-50
lines changed

doc-src/BackupPC.pod

Lines changed: 67 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -43,15 +43,16 @@ and restore files from backups.
4343

4444
The http/cgi user interface has internationalization (i18n) support,
4545
currently providing English, French, German, Spanish, Italian,
46-
Dutch and Portuguese-Brazilian.
46+
Dutch, Polish, Portuguese-Brazilian and Chinese
4747

4848
=item *
4949

50-
No client-side software is needed. On WinXX the standard smb protocol is
51-
used to extract backup data. On linux, unix or MacOSX clients, rsync or
52-
tar (over ssh/rsh/nfs) is used to extract backup data. Alternatively,
53-
rsync can also be used on WinXX (using cygwin), and Samba could be
54-
installed on the linux or unix client to provide smb shares).
50+
No client-side software is needed. On WinXX the standard smb
51+
protocol is used to extract backup data. On linux, unix or MacOSX
52+
clients, rsync, tar (over ssh/rsh/nfs) or ftp is used to extract
53+
backup data. Alternatively, rsync can also be used on WinXX (using
54+
cygwin), and Samba could be installed on the linux or unix client
55+
to provide smb shares).
5556

5657
=item *
5758

@@ -278,9 +279,8 @@ pooling) and a convenient user interface to rsync.
278279
Two popular open source packages that do tape backup are
279280
Amanda (L<http://www.amanda.org>)
280281
and Bacula (L<http://www.bacula.org>).
281-
Amanda can also backup WinXX machines to tape using samba.
282-
These packages can be used as back ends to BackupPC to backup the
283-
BackupPC server data to tape.
282+
These packages can be used as complete solutions, or also as back
283+
ends to BackupPC to backup the BackupPC server data to tape.
284284

285285
Various programs and scripts use rsync to provide hardlinked backups.
286286
See, for example, Mike Rubel's site (L<http://www.mikerubel.org/computers/rsync_snapshots>),
@@ -304,7 +304,7 @@ consideration.
304304
=head2 Road map
305305

306306
The new features planned for future releases of BackupPC
307-
are at L<http://backuppc.sourceforge.net/faq/roadMap.html>.
307+
are on the Wiki at L<http://backuppc.wiki.sourceforge.net>.
308308

309309
Comments and suggestions are welcome.
310310

@@ -350,7 +350,7 @@ moderately configured server.
350350
Several users have reported significantly better performance using
351351
reiserfs compared to ext3 for the BackupPC data file system. It is
352352
also recommended you consider either an LVM or RAID setup (either
353-
in HW or SW; eg: 3Ware RAID5) so that you can expand the
353+
in HW or SW; eg: 3Ware RAID10 or RAID5) so that you can expand the
354354
file system as necessary.
355355

356356
When BackupPC starts with an empty pool, all the backup data will be
@@ -397,11 +397,10 @@ distributions for most platforms.
397397

398398
=item *
399399

400-
If you are using tar to backup linux/unix machines you should have version
401-
1.13.7 at a minimum, with version 1.13.20 or higher recommended. Use
400+
If you are using tar to backup linux/unix machines, those machines should have
401+
version 1.13.7 at a minimum, with version 1.13.20 or higher recommended. Use
402402
"tar --version" to check your version. Various GNU mirrors have the newest
403-
versions of tar, see for example L<http://www.funet.fi/pub/gnu/alpha/gnu/tar>.
404-
As of July 2006 the latest version is 1.15.1.
403+
versions of tar; see L<http://www.gnu.org/software/tar/>.
405404

406405
=item *
407406

@@ -552,15 +551,22 @@ module is installed.
552551
To use rsync and rsyncd with BackupPC you will need to install File::RsyncP.
553552
You can run "perldoc File::RsyncP" to see if this module is installed.
554553
File::RsyncP is available from L<http://perlrsync.sourceforge.net>.
555-
Version 0.52 or later is required.
554+
Version 0.68 or later is required.
555+
556+
=item File::RsyncP
557+
558+
To use ftp with BackupPC you will need to install three libraries:
559+
Net::FTP, Net::FTP::RetrHandle and Net::FTP::AutoReconnect. You can
560+
run "perldoc Net::FTP" to see if a particular module is installed.
556561

557562
=back
558563

559-
To build and install these packages, fetch the tar.gz file and
560-
then run these commands:
564+
To build and install these packages you should use the cpan program.
565+
Alternatively, you can fetch the tar.gz file from L<http://www.cpan.org>
566+
and then run these commands:
561567

562-
tar zxvf Archive-Zip-1.16.tar.gz
563-
cd Archive-Zip-1.16
568+
tar zxvf Archive-Zip-1.26.tar.gz
569+
cd Archive-Zip-1.26
564570
perl Makefile.PL
565571
make
566572
make test
@@ -695,11 +701,12 @@ they can be set for new installations using command-line options.
695701
=head2 Step 3: Setting up config.pl
696702

697703
After running configure.pl, browse through the config file,
698-
__CONFDIR__/config.pl, and make sure all the default settings
699-
are correct. In particular, you will need to decide whether to use
700-
smb, tar or rsync transport (or whether to set it on a per-PC basis)
701-
and set the relevant parameters for that transport method.
702-
See the section L<Client Setup|step 5: client setup> for more details.
704+
__CONFDIR__/config.pl, and make sure all the default settings are
705+
correct. In particular, you will need to decide whether to use
706+
smb, tar,or rsync or ftp transport (or whether to set it on a
707+
per-PC basis) and set the relevant parameters for that transport
708+
method. See the section L<Client Setup|step 5: client setup> for
709+
more details.
703710

704711
=head2 Step 4: Setting up the hosts file
705712

@@ -803,9 +810,10 @@ Here's a simple example of a hosts file:
803810

804811
=head2 Step 5: Client Setup
805812

806-
Three methods for getting backup data from a client are supported: smb,
807-
tar and rsync. Smb or rsync are the preferred methods for WinXX clients
808-
and rsync or tar are the preferred methods for linux/unix/MacOSX clients.
813+
Four methods for getting backup data from a client are supported:
814+
smb, tar, rsync and ftp. Smb or rsync are the preferred methods
815+
for WinXX clients and rsync or tar are the preferred methods for
816+
linux/unix/MacOSX clients.
809817

810818
The transfer method is set using the $Conf{XferMethod} configuration
811819
setting. If you have a mixed environment (ie: you will use smb for some
@@ -977,15 +985,22 @@ the client machine and BackupPC connects directly to it.
977985

978986
The relevant configuration settings are $Conf{RsyncdClientPort},
979987
$Conf{RsyncdUserName}, $Conf{RsyncdPasswd}, $Conf{RsyncdAuthRequired},
980-
$Conf{RsyncShareName}, $Conf{RsyncArgs}, and $Conf{RsyncRestoreArgs}.
981-
$Conf{RsyncShareName} is the name of an rsync module (ie: the thing
982-
in square brackets in rsyncd's conf file -- see rsyncd.conf), not a
983-
file system path.
988+
$Conf{RsyncShareName}, $Conf{RsyncArgs}, $Conf{RsyncArgsExtra}, and
989+
$Conf{RsyncRestoreArgs}. $Conf{RsyncShareName} is the name of an rsync
990+
module (ie: the thing in square brackets in rsyncd's conf file -- see
991+
rsyncd.conf), not a file system path.
984992

985993
Be aware that rsyncd will remove the leading '/' from path names in
986994
symbolic links if you specify "use chroot = no" in the rsynd.conf file.
987995
See the rsyncd.conf manual page for more information.
988996

997+
=item ftp
998+
999+
You need to be running an ftp server on the client machine.
1000+
The relevant configuration settings are $Conf{FtpShareName},
1001+
$Conf{FtpUserName}, $Conf{FtpPasswd}, $Conf{FtpBlockSize},
1002+
$Conf{FtpPort}, $Conf{FtpTimeout}, and $Conf{FtpFollowSymlinks}.
1003+
9891004
=back
9901005

9911006
You need to set $Conf{ClientCharset} to the client's charset so that
@@ -1045,7 +1060,7 @@ network data you can use ssh to create a tunnel, or use a
10451060
program like stunnel.
10461061

10471062
Setup instructions for ssh can be found at
1048-
L<http://backuppc.sourceforge.net/faq/ssh.html>.
1063+
L<http://backuppc.sourceforge.net/faq/ssh.html> or on the Wiki.
10491064

10501065
=item Clients that use DHCP
10511066

@@ -1594,7 +1609,7 @@ will be deferred if there is a backup currently running for that host.
15941609
When the restore job is run, smbclient, tar, rsync or rsyncd is used
15951610
(depending upon $Conf{XferMethod}) to actually restore the files.
15961611
Sorry, there is currently no option to cancel a restore that has been
1597-
started.
1612+
started. Currently ftp restores are not fully implemented.
15981613

15991614
A record of the restore request, including the result and list of
16001615
files and directories, is kept. It can be browsed from the host's
@@ -1981,15 +1996,15 @@ same (only displayed if $Conf{XferLogLevel} >= 2).
19811996
=back
19821997

19831998
As BackupPC_tarExtract extracts the files from smbclient or tar, or as
1984-
rsync runs, it checks each file in the backup to see if it is identical
1985-
to an existing file from any previous backup of any PC. It does this
1986-
without needed to write the file to disk. If the file matches an
1987-
existing file, a hardlink is created to the existing file in the pool.
1988-
If the file does not match any existing files, the file is written to
1989-
disk and the file name is saved in __TOPDIR__/pc/$host/NewFileList for
1990-
later processing by BackupPC_link. BackupPC_tarExtract and rsync can handle
1991-
arbitrarily large files and multiple candidate matching files without
1992-
needing to write the file to disk in the case of a match. This
1999+
rsync or ftp runs, it checks each file in the backup to see if it is
2000+
identical to an existing file from any previous backup of any PC. It
2001+
does this without needed to write the file to disk. If the file matches
2002+
an existing file, a hardlink is created to the existing file in the
2003+
pool. If the file does not match any existing files, the file is written
2004+
to disk and the file name is saved in __TOPDIR__/pc/$host/NewFileList
2005+
for later processing by BackupPC_link. BackupPC_tarExtract and rsync
2006+
can handle arbitrarily large files and multiple candidate matching files
2007+
without needing to write the file to disk in the case of a match. This
19932008
significantly reduces disk writes (and also reads, since the pool file
19942009
comparison is done disk to memory, rather than disk to disk).
19952010

@@ -2225,7 +2240,7 @@ a suffix of 0, 1, ....
22252240

22262241
=item XferERR or XferERR.z
22272242

2228-
Output from the transport program (ie: smbclient, tar or rsync)
2243+
Output from the transport program (ie: smbclient, tar, rsync or ftp)
22292244
for the most recent failed backup.
22302245

22312246
=item new
@@ -2235,7 +2250,7 @@ directory is renamed if the backup succeeds.
22352250

22362251
=item XferLOG or XferLOG.z
22372252

2238-
Output from the transport program (ie: smbclient, tar or rsync)
2253+
Output from the transport program (ie: smbclient, tar, rsync or ftp)
22392254
for the current backup.
22402255

22412256
=item nnn (an integer)
@@ -2244,7 +2259,7 @@ Successful backups are in directories numbered sequentially starting at 0.
22442259

22452260
=item XferLOG.nnn or XferLOG.nnn.z
22462261

2247-
Output from the transport program (ie: smbclient, tar or rsync)
2262+
Output from the transport program (ie: smbclient, tar, rsync or ftp)
22482263
corresponding to backup number nnn.
22492264

22502265
=item RestoreInfo.nnn
@@ -2304,11 +2319,11 @@ Stop time of the backup in unix seconds.
23042319

23052320
=item nFiles
23062321

2307-
Number of files backed up (as reported by smbclient, tar or rsync).
2322+
Number of files backed up (as reported by smbclient, tar, rsync or ftp).
23082323

23092324
=item size
23102325

2311-
Total file size backed up (as reported by smbclient, tar or rsync).
2326+
Total file size backed up (as reported by smbclient, tar, rsync or ftp).
23122327

23132328
=item nFilesExist
23142329

@@ -2332,7 +2347,7 @@ Total size of files that were not in the pool
23322347

23332348
=item xferErrs
23342349

2335-
Number of errors or warnings from smbclient, tar or rsync.
2350+
Number of errors or warnings from smbclient, tar, rsync or ftp.
23362351

23372352
=item xferBadFile
23382353

@@ -2431,7 +2446,7 @@ Number of errors from BackupPC_tarCreate during restore.
24312446

24322447
=item xferErrs
24332448

2434-
Number of errors from smbclient, tar or rsync during restore.
2449+
Number of errors from smbclient, tar, rsync or ftp during restore.
24352450

24362451
=back
24372452

@@ -2818,6 +2833,8 @@ Karol 'Semper' Stelmaczonek provided the Polish translation for 3.1.0.
28182833

28192834
Jeremy Tietsort provided the host summary table sorting feature for 3.1.0.
28202835

2836+
Paul Mantz contributed the ftp Xfer method for 3.2.0.
2837+
28212838
Many people have reported bugs, made useful suggestions and helped
28222839
with testing; see the ChangeLog and the mailing lists.
28232840

init.d/src/freebsd-backuppc2

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/bin/sh
2+
3+
# PROVIDE: backuppc
4+
# REQUIRE: LOGIN
5+
#
6+
# Add the following line to /etc/rc.conf to enable BackupPC:
7+
#
8+
# backuppc_enable="YES"
9+
#
10+
# Submitted by Dan Niles
11+
12+
. /etc/rc.subr
13+
14+
name="backuppc"
15+
rcvar=`set_rcvar`
16+
load_rc_config $name
17+
18+
: ${backuppc_enable:="NO"}
19+
: ${backuppc_program:="__INSTALLDIR__/bin/BackupPC"}
20+
: ${backuppc_flags:="-d"}
21+
: ${backuppc_user:="__BACKUPPCUSER__"}
22+
command_interpreter="/usr/bin/perl"
23+
command=$backuppc_program
24+
pidfile="__LOGDIR__/BackupPC.pid"
25+
26+
run_rc_command "$1"

0 commit comments

Comments
 (0)