Backup server for the raspberry pi

Binaries of UrBackup for Raspian are available now here (Update: See the nighlty builds or the “wheezy” folder of Debian of the official releases). Performance isn’t that good on the raspberry pi, obviously. I’d avoid using any kind of compression, for example.

Setup instructions:

First setup the backup storage. I suggest using btrfs. Plug in a USB-hard disk and create a partition, e.g. using cfdisk. Then install btrfs and create the filesystem:

apt-get update
apt-get install btrfs-tools
mkfs.btrfs /dev/sda1
mkdir /media/backup

Add an entry to /etc/fstab to automatically mount the USB-hard disk:

/dev/sda1 /media/backup btrfs defaults,nossd 0 0

Then mount the hard disk:

mount /media/backup

Download the UrBackup server package and install it:

wget http://sourceforge.net/projects/urbackup/files/Server/1.2RC/urbackup-server_1.2-1_armhf.deb/download
dpkg -i urbackup-server_1.2-1_armhf.deb

Resolve the dependencies:

apt-get -f install

Enter e.g. /media/backup/urbackup when it asks for the backup storage path.

UrBackup server should run now and automatically backup clients as soon as you install the UrBackup client on one of your PCs in the local network (from here). If you want to change any settings you should go to the web interface. Let 192.168.0.42 be the IP of your raspberry pi. You can then access the web interface of UrBackup via typing http://192.168.0.42:55414 into your address bar. If you want to access your files you should share /media/backup/urbackup e.g. via samba. There are guides on how to install samba on a raspberry pi (here for example).

Sidenote: I’ve heard that it runs even better on a Cubieboard. It has a SATA-port so the USB-Bottlenet is gone. Unfortunately, they’re even harder to get than Raspberry Pis.

2 thoughts on “Backup server for the raspberry pi

  1. Installation issues on a Raspi 3B running Raspbian “jessie”:

    I installed Urbackup Server 2.0.38 along the lines of the above blog post. When the installer asked for the backup storage path I am pretty sure it suggested my intended path /media/backup/urbackup. In any case, I accepted the suggestion. However, the actual setting turned out to be /media/BACKUP/urbackup. And since the BACKUP directory created by the installer or by the backup server resided on the main device, the backup soon clogged the 16GB of the Raspi SD card … After I have rectified the setting and removed the spurious BACKUP dir things work okay.

    The upgrade to release 2.1.18 failed due to libguestfs-tools not being available from the standard Raspbian package repository. “Resolving the dependencies” actually results in urbackup server being deinstalled (when followed through. I preferred to reinstall 2.0.38 rather than get the missing package elsewhere.)

  2. You might have qualified your recommendation of btrfs by the proviso that this is an experimental file system with limited recovery options.

Leave a Reply

Your email address will not be published. Required fields are marked *