BackupPC #2
In part 1, we left our hero with BackupPC installed but with nothing to back up. Or so he thought....
When I came downstairs this morning, I refreshed the BackupPC Server Status page, and found that the file pool now contained 928 files! From where? It seems that the default setup will backup the localhost machine. Now, this box only has a few hundred MB of files on it - Ubuntu and the BackupPC files. Apparently, a full backup was done during the night, and I was greeted with a successful backup status. That means it works!
Now it's time to setup the main file server for backup. I started tonight by adding the server to the hosts file - /etc/backuppc/hosts. I added the following line:
hostname 0 username(You can insert your hostname and username instead of my italicized placeholders.)
And I used this command to setup the user in BackupPC:
htpasswd /etc/backuppc/htpasswd usernameFor this next part, I'm going to deviate a little from the instructions. The config.pl file is setup to backup localhost (as I learned this morning), and I don't want to change that. So instead, I will create a new config file for the file server. It will be called:
/etc/backuppc/hostname.plI only need to enter the settings that are different from the main config file. Here's what I came up with (sorry for the extra line breaks):
We'll see what happens.
# BackupPC config file for hostname
# Set the file transfer method
$Conf{XferMethod} = 'rsync';
# Use $hostIP for the client path
$Conf{RsyncClientCmd} = '$sshPath -q -x -l root $hostIP $rsyncPath $argList+';
$Conf{RsyncClientRestoreCmd} = '$sshPath -q -x -l root $hostIP $rsyncPath $argL$
# Name the partition
$Conf{RsyncShareName} = '/';
# Limit backup to the /export directory
$Conf{BackupFilesOnly} = '/export';
# Skip the music files and podcasts
$Conf{BackupFilesExclude} = ['/export/music', '/export/Podcasts'];
After restarting the daemon, it's time to configure SSN and rsync. I followed the instructions on page 4 of the tutorial.
I'm getting totally hosed on the public/private key stuff. I wonder if it is because I've already generated keys before for openssh access. I'm going to pack it in for the night, so stay tuned for part 3.
Labels: backup
0 Comments:
Post a Comment
<< Home