Menü schliessen
Created: April 2nd 2013
Last updated: May 1st 2020
Categories: IT Support
Author: Marcus Fleuti

How to install rsnapshot on a Qnap Intel Atom x86 (TS-269L or similar) for creating automatic hourly, daily weekly and monthly snapshot backups to USB medias

Donation Section: Background
Monero Badge: QR-Code
Monero Badge: Logo Icon Donate with Monero Badge: Logo Text
82uymVXLkvVbB4c4JpTd1tYm1yj1cKPKR2wqmw3XF8YXKTmY7JrTriP4pVwp2EJYBnCFdXhLq4zfFA6ic7VAWCFX5wfQbCC

Update 11.12.2016 - Qnap now supports this by default

You do no longer need to set up a snapshot backup manually. The current Qnap software supports this already. For more information consult the qnap tutorial page:
DE: https://www.qnap.com/de-de/tutorial/con_show.php?op=showone&cid=164
EN: https://www.qnap.com/en/tutorial/con_show.php?op=showone&cid=164

The goal

What we want to achieve is configuring the rsnapshot service on a Qnap NAS that's equipped with an Intel Atom CPU.

Preliminaries

In order to being able to install you're going to need to download a few tools beforehand:

  1. Logon to your NAS' web administration
  2. Navigate to System Administration -> Firmware Update and update to the newest release possible before going any further
  3. Navigate to Applications -> QPKG Center
  4. Select the tab AVAILABLE and Search for Optware (IPKG) and install it
  5. Download one of the following file (originally found here):
    1. rsnap_3.1.2_x86.qpkg (for TS-xxx with Intel-CPU (e.g. Intel Atom)
    2. rsnap_3.1.2_arm-x19.qpkg (for TS-xxx with ARM-CPU)
  6. Unzip the file into a folder
  7. Navigate to Applications -> QPKG Center
  8. Select the tab GET MORE
  9. Upload and install the qpkg file you've just downloaded and decompressed
    • Hint: The first time the installation failed giving me an absurd error. As I tried it again it worked nicely
  10. Now configure the mail services on your NAS to enable it sending out log emails (you should do this anyway in order to be able to monitor your device - also you should enable the HDD SMART options that periodically checks your harddrives for errors and reports if anything goes wrong. But that's not part of this manual)
    1. Navigate to System Administration -> Notification and configure (and test) an outgoing mail service (server)
    2. Navigate to the tab ALERT NOTIFICATION and enable email reporting as well as setting a destination email address where you want to receive the logfiles and error reports in the future.
  11. Now it's time to attach your backup USB harddrive (or memory stick). In case you intend on creating Snapshots on a NFS volume you can skip the rest
  12. Navigate to External Device -> External Storage Device and format your USB drive with the EXT4 filesystem. Attention: All data on this disc will be lost!!!

It's installed, harddrive is ready - What to do next?

Once the software is installed navigate to the following URL on your QNAP:

http://qnapNASNameOrIP:8080/rsnap

You can login using the default credentials

Username:   admin
Password:  admin

--> You should change the password immediately
In here you can manage your various backup-sets easily.

You are done now. Next: Get familiar with the tool, create some first backups. To check if a backup worked out you do the following:
Navigate to the basic UNC path of your NAS by entering this in a Windows Explorer window (or on mac: select the NAS in the list of external devices):

\\qnapNASNameORIP

You should see some default shares like "Download" or "Public" as well as the share named USBDisk1.

--> Klick on the USBDisk1 share

You should now see one or more folder(s) that's named like this:

  • hourly.x
  • daily.x
  • weekly.x
  • monthly.x

These folders are holding up your snapshot backups, If you want to recover a lost file you can directly pull it out of one of these folders. If you sort the directories by date you can easily go back in time and restore files that were accidentally deleted months ago - with just a few clicks!

That's it - have fun!

 

Fehler - configuration.cgi Seite wird nicht angezeigt

In einigen Fällen kommt es vor, dass bei der Anzeige der Seite configuration.cgi eine Fehlermeldung an Stelle der Konfigurationsseite ausgegeben wird. Das liegt an einem Bug in der HTML-Datei. Der Content-Type ist falsch. Diese Information wurde in diesem Forum-Thread gefunden:
Gehe zu /home/httpd/rsnap/
Folgende Zeilen in den Dateien configuration.cgi und configuration_event.cgi ersetzen:

#---------------------------------------------------------------------------------------------------------------------
echo "<meta http-equiv='content-type' content='text/html; charset=ISO-8859-1'>"   <-----ersetzen
echo ""
echo "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\""
echo "\"http://www.w3.org/TR/html4/loose.dtd\">"
echo "<html>"
echo "<head>"

durch:

#---------------------------------------------------------------------------------------------------------------------
echo "content-type: text/html"
echo ""
echo "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\""
echo "\"http://www.w3.org/TR/html4/loose.dtd\">"
echo "<html>"
echo "<head>"

Geändert wird also nur die Content-Type-Angabe.
Dies muss über eine SSH/Telnet-Konsole gemacht werden. Wir verwenden hierzu den Editor "nano" der sich mittels folgendem Kommando installieren lässt:

ipgk install nano

Die externe USB Festplatte wird nicht als Speicherort angezeigt

Wir hatten schon das Problem, dass die externe USB-Festplatte nicht als Speicherort des Backups angezeigt wird:

Das Problem liess sich einfach lösen, indem wir der Festplatte beim Formatieren die Bezeichnung USBDisk1 vergaben: