http://mirror.de-labrusse.fr/nethserver/nethserver-BackupPC/
You need to enable epel (thanks to michele)
Add EPEL repo:
yum localinstall http://ftp.heanet.ie/pub/fedora/epel/6/i386/epel-release-6-8.noarch.rpm
Disable it:
eorepo centos-base centos-updates nethserver-base nethserver-updates
and install the module
yum install http://mirror.de-labrusse.fr/nethserver/nethserver-BackupPC/nethserver-BackupPC-1.0.1-1.ns6.noarch.rpm --enablerepo=epel
sources are https://github.com/stephdl/nethserver-BackupPC/tree/ns6
I’m not the first author, it is an adaptation to nethserver of a smeserver contribs of Daniel Berteaud, of course I’m open to discussion, if you think that we can add more features.
For the ldap authentication I use the ‘libuser’, not sure that it is safe, but I wanted to run a apache session with another default user. I used to authenticate with ‘pwauth’ but in this case the backuppc user has to be member of the apache group, that leads to the same, therefore I decided to use ldap.
Once installed, the admin cgi user is ‘admin’ (think to set a password for ns6.6) but any users can perform a login however they can manage only the their backups(eg the admin user needs to set backups for this user). If you want to restrict the cgi interface only for the admin, then set the db ‘CgiMultiUser’ to disabled
see db commands
# config show backuppc
backuppc=service
CgiMultiUser=enabled
examples=enabled
status=enabled
sudo=/usr/bin/rsync,/bin/gtar,/bin/tar
CgiMultiUser -> enabled all users in ldap can use the backuppc CGI, disabled and only admin can do it
sudo-> you can add here more commands available by sudo to backuppc
if you want to modify something, then
config setprop backuppc CgiMultiUser disabled
signal-event nethserver-BackupPC-update
other DB available
# config show httpd-bkpc
httpd-bkpc=service
TCPPort=950
access=none
status=enabled
the service which run the other apache session can be controlled by
service httpd-bkpc restart
#(available stop, start, restart, status)
or (enabled or disabled)
config setprop httpd-bkpc status disabled
signal-event nethserver-BackupPC-update
Then go to https://yourIP/BackupPC or Dashboard->Applications->BackupPC
You will find two urls
https://yourIP/BackupPC -> the cgi interface
https://yourIP/cygwin -> a web page to help the cygwin-rsyncd settings for windows
Automatically, a rsa key is created in /var/lib/BackupPC/.ssh (4098 bits) you can use it to authenticate without password if you want to backup a linux host
first you need to export the public key
su -s /bin/sh backuppc
ssh-copy-id -i ~backuppc/.ssh/id_rsa.pub root@192.168.xxx.xxx
and test if all is ok
ssh root@192.168.xxx.xxx
if it is ok you can log without password, then do ‘exit’ to go out of the shell
Of course you can use a lot of protocol (smb,ftp,rync,rsynd,tar,…)
-
Remove all backups of a client
thenrm -rf /var/lib/BackupPC/pc/client/
sudo -u backuppc /usr/share/BackupPC/bin/BackupPC_serverMesg BackupPC_nightly run -
Remove One backup of a client
cd /var/lib/BackupPC/pc/client/
ls
rm -fR backup_number
sudo -u backuppc /usr/share/BackupPC/bin/BackupPC_serverMesg BackupPC_nightly run
Removing a single backup must be done with extreme care. You can safely remove the last backup for example, but if you remove a backup on which another one is based on, you can screw up your backups
After this, you will see space reclaimed and you can check it with df, but you still need to remove statistic line, otherwise you will see it in your web interface. To do that:
vi /var/lib/BackupPC/pc/client/backups
you can remove the line with the backup_number.
Relog to your web interface and voila! No more backup_number.
- what it can be enhanced
some scripts to wake on lan computer before to backup them
some scripts to backup windows computers with shadows copy
well a lot of more of course, i’m waiting your scripts and your ideas.