Integrating Rsnapshot backups with Synology NAS systems

Rsnapshot is a simple but indispensable Open Source backup script that leverages the power of the rsync command (and SSH) to make backing up your Lunix/Unix infrastructure easy. It’s a must have tool in my opinion.

BTW, The best book for all things Unix/Linux Backup and Recovery (including Rsnapshot) is W. Curtis Preston’s Backup and Recovery from Orielly.

You can use Rsnapshot to write your backups to a second hard drive, an external USB or FireWire drive, an NFS mount from another computer on your network, or simply over the network to another computer via ssh.

I’ve started to incorporate these cheep and very capable NAS devices from Synology, namely the 8 bay DS1812+. I recommend these 3T Seagate drives with the NAS.

Out of the box, the Synology DS1812+ comes with a powerful web-based user interface that makes setting things up easy. It does not support Rsnapshot be default. However, because the Synology NAS is itself it’s own little Linux machine (its OS is based on the BusyBox distribution), it’s possible to SSH into it to make your own customizations. The steps bellow will walk you through installing the “ipkg” package manager (simular to Yum on RedHat based distributions, or apt-get on Debian), as well as installing and configuring Rsnapshot.

Step one: Installing ipkg.

This first step is specific to the DS1812 and assumse you’ve already created at least one volume via the web-based admin interface. If you have a different model, see here for more details.

First thing to do is to enable SSH via the NAS’s web-based admin page. This is in the “Terminal” section of the Control Panel. Once enabled, SSH into your NAS with username “root” along with your admin password.

Next we want to download and install the ipkg bootstrap script. We first change directory to the “@tmp” directory of your first volume, download the ipkg bootstrap with the “wget” command, make the script executable, and then run the script…


cd /volume1/@tmp
wget http://ipkg.nslu2-linux.org/feeds/optware/syno-i686/cross/unstable/syno-i686-bootstrap_1.2-7_i686.xsh

chmod +x syno-i686-bootstrap_1.2-7_i686.xsh
sh syno-i686-bootstrap_1.2-7_i686.xsh

After the script runs, you can delete it if you like. If your Synology NAS is using DSM 4.0 or newer you also have to edit /root/.profile and comment out the PATH and EXPORT statements at the top.

Now restart your NAS via the web-based admin page to finish the ipkg install. Once it’s rebooted, log back in as “root” via SSH.


Step 2: Installing Rsnapshot

Now that you have the ipkg package manager, installing rsnapshot (as well as many other Linux tools) is trivial… Along with Rsnapshot you will want to install “cron” in order to be able to automate/schedule backups. I also installed GNU screen, less, and mlocate to make life easier.


ipkg update

ipkg install rsnapshot
ipkg install cron
ipkg install less
ipkg install mlocate
ipkg install screen

There you go. The rsnapshot config file is located at /opt/etc/rsnapshot.conf

Note also that Cron on the Synology works differently than what you’re used to on most Linux distributions. For details on how to get cron working properly, see this thread on the Synology forums.

iPad – Infantilizing Hardware?

Crying Baby - techno-elitist
Techno-Elitist

I have to admit that I found Cory Doctorow’s anti-iPad post at Boing Boing quite bizarre and techno-elitist. He seems to dislike both how easy the iPad is to use as well how efficiently it’s physical parts are put together (glue as opposed to screws).

His argument that the iPad is “Infantalizing [sic] hardware” is particularly short-sighted. I view the iPad as a sort of satellite of my  main workstation. With such a device, good user interface design should free the user from the sort of things that make a full blown computer more cumbersome, albeit more powerful. When you’re relaxing on the couch with a cup of coffee, or on a road trip to San Fran, and all you want to do is read Wikipedia, peruse your comic library, or catch up on the latest news, your iPad is probably a good delivery method.

Furthermore, what’s more important? Simple and easy-to-use access to the world’s information database, or you’re ability to disassemble the device your using to read it? The answer is obvious. The benefits of miniaturized (system on a chip) ICs, vertical circuit fabrication, and the power efficiency they bring far, far outweigh the the benefits of being able to disassemble such a device. And I would argue that the physical device itself is far less important in the grand scheme of things compared to the almost infinite software possibilities.

And of course, as a professional Unix admin, I know that options exists for people who want to tinker at a very low level (Linux + cheap commodity hardware). We shouldn’t think of the iPad as a replacement, but rather just another option.