Table of Contents

BackupPC

Installation

  Listen 8085
  NameVirtualHost *:8085
  <VirtualHost *:8085>
          SuexecUserGroup backuppc backuppc
          DocumentRoot /var/www/
 
          #Also prevent access to our .htpasswd file
          <Files ~ "\.htpasswd$">
                  Order allow,deny
                  Deny from all
          </Files>
          <Directory /var/www/>
                  Options Indexes FollowSymLinks MultiViews
                  AllowOverride None
                  Order allow,deny
                  Deny from all
          </Directory>
          <Directory /var/www/BackupPC>
                  Order allow,deny
                  Allow from all
          </Directory>
          <Directory /var/www/cgi-bin>
                  AddHandler cgi-script .cgi .pl
                  Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
                  Order allow,deny
                  Allow from all
 
                  AuthType Basic
                  AuthName "BackupPC"
                  AuthUserFile /var/www/backuppc.htpasswd
                  Require valid-user
          </Directory>
 
          ErrorLog /var/log/apache2/error-backuppc.log
          LogLevel warn
          CustomLog /var/log/apache2/access-backuppc.log combined
          ServerSignature On
  </VirtualHost>

Troubleshooting

Backup failed: unable to read 4 bytes

This means the ssh connection has failed. The most likely cause is that ssh is waiting for user input to ask a question about the host key. the solution is to log into the backups box, then switch to the backuppc user and attempt to connect to the target machine manually. If you see any prompts about unknown or changed host keys, then resolve the problem and backups should run cleanly once more.

Notes