BackupPC Web Interface: Difference between revisions

From wiki.zmanda.com
Jump to navigation Jump to search
No edit summary
 
Line 25: Line 25:
Next, we need to add a users file.  Go to the <tt>conf.d</tt> for apache (For Red Hat and derivative distributions, this is <tt>/etc/httpd/conf.d</tt>, for Suse, it is <tt>/etc/apache2/conf.d</tt>) and run the following command:
Next, we need to add a users file.  Go to the <tt>conf.d</tt> for apache (For Red Hat and derivative distributions, this is <tt>/etc/httpd/conf.d</tt>, for Suse, it is <tt>/etc/apache2/conf.d</tt>) and run the following command:


<tt>htpasswd -c backuppc_community.conf admin</tt>
<tt>grep AuthUserFile backuppc_community.conf</tt>
 
This returns to us:
 
<tt>AuthUserFile /etc/BackupPC/BackupPC.users</tt>
 
Now go to the directory which contains the users file - <tt>cd /etc/BackupPC</tt> - and, on Red Hat, run the following command on the file referenced in our config:
 
<tt>htpasswd -c BackupPC.users admin</tt>


For Suse machines, the command will be
For Suse machines, the command will be


<tt>htpasswd2 -c backuppc_community.conf admin</tt>
<tt>htpasswd2 -c BackupPC.users admin</tt>


You will then be prompted for a password for the admin user.  Enter in something your users won't guess, and hit enter.
You will then be prompted for a password for the admin user.  Enter in something your users won't guess, and hit enter.

Revision as of 05:00, 18 March 2009

Overview

BackupPC includes a very powerful web interface from which all administrative tasks can be done. The setup of BackupPC's CGI library is quite versatile, and requires execution on the local machine.

Built-In Apache Configuration

BackupPC Community Edition is bundled with scripts to automatically configure an existing apache server and suidperl to accept connections from the local machine.

By default, BackupPC Community Edition comes with htpasswd authentication. In order to use the BackupPC web interface, these are the steps you need to follow:

Add a CGI Administrator

Before you start BackupPC Community Edition, as the root user, open up /etc/BackupPC/config.pl and go to line 2020, which should look like this:

$Conf{CgiAdminUsers} = ;

Change this line to

$Conf{CgiAdminUsers} = 'admin';

or some other name of your choosing. The name is irrelevant and is not related to the users of the machine.

Add a Users File

Next, we need to add a users file. Go to the conf.d for apache (For Red Hat and derivative distributions, this is /etc/httpd/conf.d, for Suse, it is /etc/apache2/conf.d) and run the following command:

grep AuthUserFile backuppc_community.conf

This returns to us:

AuthUserFile /etc/BackupPC/BackupPC.users

Now go to the directory which contains the users file - cd /etc/BackupPC - and, on Red Hat, run the following command on the file referenced in our config:

htpasswd -c BackupPC.users admin

For Suse machines, the command will be

htpasswd2 -c BackupPC.users admin

You will then be prompted for a password for the admin user. Enter in something your users won't guess, and hit enter.

Enabling Machine Access

For security reasons, BackupPC Community Edition is very restrictive as to which IPs have access to the server. By default, only the localhost is allowed to open the user interface. If you would like to change this to your local network's IP range, while still in the apache open up backuppc_community.conf with your text editor of choice and go to line 15:

allow from 127.0.0.1

Change the access level to what you you feel is appropriate.

Apache Setup

Detailed instructions, technical overview, etc. can be found in the BackupPC Documentation: Step 9 CGI Interface.

Lighttpd Setup

A popular option for users running BackupPC on dedicated storage units. Documentation on installation for Debian can be found on the BackupPC wiki.