Koozali.org: home of the SME Server

Backuppc contrib

duncan

Backuppc contrib
« on: September 30, 2004, 03:23:47 PM »
Backuppc is described as a "high-performance, enterprise-grade system for backing up Linux and WinXX PCs and laptops to a server's disk. BackupPC is highly configurable and easy to install and maintain." - basically it is a superb network to disk backup solution using smb, rsync or tar.

A SME built rpm can be got from  here. The RsyncP rpm is required if you want to use rsync as a backup method.
The package installs the configs, backup locations and web stuff in /opt/backuppc. Prior to the rpm installation - you need to add a user called "backuppc".

To enable do;
/sbin/e-smith/db configuration setprop backuppc  status enabled
/sbin/e-smith/signal-event console-save
reboot

You can browse to http://server-address/backuppc/cgi-bin/BackupPC_Admin.cgi to access the web front end. Username admin has access to everything. I have set this up to use pwauth - so you can use any sme username/password combo to limit access (In the hosts file). On gateway machines - this page will be accessible from the internet albeit behind a username/password combo. You should edit the httpd custom-template and limit access only to your internal networks.

This backup solution is not for the faint hearted. It is highly configurable and very flexible. You will need to get your hands dirty. It is well worth the effort though.

jcoleman

Backuppc contrib
« Reply #1 on: September 30, 2004, 06:30:17 PM »
Bravo Duncan!

Backuppc is a great tool and making it work on the SME Server is an excellent idea.

I will install on a test machine later today and get back with you (and all) with results.

Thanks for the hard work you've been putting in to enhance the SME Server.

-jeff

mbachmann

Backuppc contrib
« Reply #2 on: October 01, 2004, 09:30:58 AM »
Superb. Have not tested yet but i will.

Duncan, the smoke free sig has gone away for what reason?

duncan

Backuppc contrib
« Reply #3 on: October 01, 2004, 11:01:15 AM »
Quote from: "mbachmann"
Superb. Have not tested yet but i will.

Duncan, the smoke free sig has gone away for what reason?


Not sure - Its still in my account. I am at about 6 months now. ;-)

mbachmann

Backuppc contrib
« Reply #4 on: October 01, 2004, 11:16:30 AM »
Aehm, you write one have to create an (user) account called "backuppc" and if so, what's the users first and last name? Like b.ackuppc? Or doesn't it matter?

duncan

Backuppc contrib
« Reply #5 on: October 01, 2004, 11:28:06 AM »
It doesnt matter - Something descriptive perhaps.

Offline percheron

  • *
  • 17
  • +0/-0
Backuppc contrib
« Reply #6 on: October 01, 2004, 01:09:51 PM »
Duncan,
Thanks for doing this work. I would like to try this contrib. After installing on an SME 6.01 server on my local network I am unable to access the cgi script. I can't get past the "You don't have permission to access /backuppc/cgi-bin/BackupPC_Admin.cgi on this server" message when trying to access the script with http://server-address/backuppc/cgi-bin/BackupPC_Admin.cgi.

Looking in the /opt/backuppc/cgi-bin directory I see this file:

-r-sr-xr--    1 backuppc shared       3925 Sep 30 02:55 BackupPC_Admin.cgi

I have a user called backuppc and have set a password. I also followed the rest of your instructions in your post. Any suggestions?

Thanks,
jim

duncan

Backuppc contrib
« Reply #7 on: October 01, 2004, 02:01:25 PM »
Hi Jim, not sure what the problem might be. The cgi-bin permissions are root.root which might be causing a problem.

I have just done a fresh install with no problems on another machine. Perhaps checkout the /var/log/httpd files to see whats going on.

Offline percheron

  • *
  • 17
  • +0/-0
Backuppc contrib
« Reply #8 on: October 01, 2004, 02:32:58 PM »
Duncan,
Thansk for the quick reply. I looked at the error logs but did not see anything peculiar. Here is some more info: on the first install I got the message the backuppc user did not exist and the install was using root. I removed both rpm's and reinstalled them after creating the backuppc user. When I could not get access to the cgi script, I removed the rpm's again, deleted the /opt/backuppc directory and re-installed the rpm's again. I have also used these commands in the process as specified in your post:

/sbin/e-smith/db configuration setprop backuppc status enabled
/sbin/e-smith/signal-event console-save
reboot

I have not done anything related to external access - I am strictly working on the LAN at this point.

Do you think my failure to have created the backuppc user on the first install is causing this problem? If so how can I correct it? What permissions should be set on the backuppc directory and cgi script?

Thanks again,
jim

duncan

Backuppc contrib
« Reply #9 on: October 02, 2004, 02:42:01 AM »
Installing the package without adding the user first does cause problems. However - a simple

rpm -e smeserver-backuppc
add the user
reinstall

Fixes that. If there was an easy way to create the user during the rpm installation - I would add that facility.

You should get challenged with a username/password dialogue when accessing the page. If you log in using your sme admin username/password - you will have access to all machines. If you log in as one of your sme users - you will have access to the machines you have given them access to in the /opt/backuppc/files/conf/hosts file. If you log in as a sme user not set up in the above file - they will see the page - but have access to nothing.

If you dont get the challenge dialogue (some sort of page error) then there is a problem.

Offline percheron

  • *
  • 17
  • +0/-0
Backuppc contrib
« Reply #10 on: October 02, 2004, 02:48:58 AM »
Duncan,
I do not get the user name, password challenge. I simply get the permission denied message. I have removed and re-installed the rpms four times. I did a console-save and reboot in between each install and made sure to delete the /opt/backuppc direcotry on the last two attempts. I only have one test server, the rest are production so I hesitate to try it. The server is fairly stock, just a couple of rpms. It operates in server/gateway mode. I get the same result with Mozilla and IE. I'm not sure what else to try.

Thanks for your reply.
jim

duncan

Backuppc contrib
« Reply #11 on: October 02, 2004, 03:11:51 AM »
I will set up one of my test machines as server/gateway and see how that goes.

Its a long weekend here - and I will be avoiding technology for the most part  :-)

Offline percheron

  • *
  • 17
  • +0/-0
Backuppc contrib
« Reply #12 on: October 02, 2004, 04:21:28 AM »
Duncan,
I will test the install again when you either post a revision or suggest something for me to try. If anyone else has an idea, please chime in.
Thanks again and enjoy your weekend,
jim

monkey

Backuppc contrib
« Reply #13 on: October 02, 2004, 05:28:55 PM »
Duncan,

This looks neat. Thanks for your effort on this!

I will be testing this one out, as I have a number of development PCs on my network with a very fragmented backup system. Backing up to my SME box makes sense.

I will report back my findings for you

Cheers!

Mike

duncan

Backuppc contrib
« Reply #14 on: October 04, 2004, 04:03:41 AM »
I have added a new backuppc version to the contribs directory.

Added -

rsyncd server run from xinetd (will only accept connections from 127.0.0.1 and any defined local networks - password protected, which should be changed)
The backuppc page will now list a 127.0.0.1 machine. This will backup /etc and parts of /home. This should also serve as an example to get you started with networked machines. Edit /etc/rsyncd.conf for additions.

For backing up Win machines - I would suggest using cwrsync from here.

I have only tested this a clean install. I have no idea what a rpm upgrade from the previous version will do.
If you want to add an additional drive for the backups then add some thing like this to /etc/fstab

Code: [Select]
/dev/hdxx        /opt/backuppc/files    ext3    defaults        1 2