Hetzner - DokuWiki



Applying for backup space

In addition to your dedicated/virtual server you can acquire a backup space to use for your own backups. This backup space can be ordered via Robot. To do so, click on the Server menu on the left, select your server and then go to the "Backup" tab. Here you can order different sizes of backup space, as well as up/downgrading your current backup space. The available backup space options can be found in the table below (all prices include 19% VAT):

Backup Space Size Monthly Fee Setup Fee
100 GB [*] 4.90 € [*] 4.90 € [*]
500 GB 9.90 € 9.90 €
2,000 GB 19.90 € 19.90 €
5,000 GB 44.90 € 44.90 €
10,000 GB 79.90 € 79.90 €

* Clients with servers costing 49 Euros per month or more can get the 100 GB backup space for free.

Important: please note that the backup space can only be used from your server as access is only permitted from within the Hetzner network.

Functions in Robot

In Robot (under the "Backup" tab) you can generate a new password for your backup space and also erase the content of the backup space. Furthermore, you can have your current backup usage displayed graphically. The data for this display is updated every 10 minutes.

Useful software

  • Backup with Tartarus
    • "On-the-fly” backup on FTP server
    • Support of LVM snapshots
    • Encryption (symmetrical or asymmetrical by key or password)
    • Incremental security measures
    • Based on prevalent Unix tools, enabling easy recovery from the rescue system (tar, bzip2, etc.)
    • Profile configuration files
    • Integrated "Hooks" make it suitable for special cases
    • Removal of old security measures from the FTP server using the charon tool
    • Tartarus backup configuration with examples and instructions
  • Backup with Backup2l/gpg/ftp
  • Duplicity – GPG encrypted, compressed, incremental backup from untrustworthy media or unencrypted protocols such as the FTP offered exclusively by Hetzner to the backup server. Also works with rsync and ssh.

General tips

Please note that the upload speed for the backup account is dependent on how many other clients are simultaneously accessing the backup server. Consider running your backups at another time if you experience performance problems.

It is also important to use the DNS names assigned to you (<username>.your-backup.de; only affects new backup space accounts) in place of the underlying IP address as the IP address can change.


You can access your backup space by means of FTP, SFTP and SCP. Please use the host names assigned to you (<username>.your-backup.de) as well as your username and password.

For SFTP/SCP it is possible to authenticate yourself with a Public Key. You can provide a Public Key in RFC4716 format in the file .ssh/authorized_keys on your backup space. You can convert your Public Key into RFC4716 format with the “ssh-keygen” program with the parameters “-e” and “-f <input pubkey>”. It is important that the automatically inserted comment line be erased. You need to manually create the .ssh directory if required.

For example:

server# ssh-keygen
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is:
cb:3c:a0:39:69:39:ec:35:d5:66:f3:c5:92:99:2f:e1 root@server
The key's randomart image is:
+--[ RSA 2048]----+
|                 |
|                 |
|                 |
|         .   =   |
|      . S = * o  |
|   . = = + + =   |
|    X o =   E .  |
|   o + . .   .   |
|    .            |

server# ssh-keygen -e -f .ssh/id_rsa.pub | grep -v "Comment:" > .ssh/id_rsa_rfc.pub

server# cat .ssh/id_rsa_rfc.pub

server# cat .ssh/id_rsa_rfc.pub >> backup_authorized_keys

server# echo mkdir .ssh | sftp u15000@u15000.your-backup.de
Connecting to u15000.your-backup.de...
The authenticity of host 'u15000.your-backup.de (' can't be established.
RSA key fingerprint is 3d:7b:6f:99:5f:68:53:21:73:15:f9:2e:6b:3a:9f:e3.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'u15000.your-backup.de ,' (RSA) to the list of known hosts.
u15000@u15000.your-backup.de 's password:
sftp> mkdir .ssh

server# scp backup_authorized_keys u15000@u15000.your-backup.de:.ssh/authorized_keys
u15000@u15000.your-backup.de's password:
backup_authorized_keys                                        100%  406     0.4KB/s

server# sftp u15000@u15000.your-backup.de
Connecting to u15000.your-backup.de...
sftp> ls
sftp> exit

Note: When uploading the Public Key you cannot use ssh-copy-id.


You have the option of integrating your backup space with Samba/Cifs. To do so you can use the following UNC path:

mount.cifs -o user=USERNAME,pass=PASSWORD //USERNAME.your-backup.de/backup /PATH/FOLDER

Furthermore, with the following line of code in /etc/fstab the backup space will be mounted automatically during boot time (it is just one line of code!)

//<username>.your-backup.de/backup /mnt/backup-server       cifs    iocharset=utf8,rw,credentials=/etc/backup-credentials.txt,uid=<Systemkonto>,gid=<Systemgruppe>,file_mode=0660,dir_mode=0770 0       0

The file /etc/backup-credentials.txt (mode 0600) should contain the following two lines:


On Debian-based distributions, the command is provided via the package cifs-utils (apt-get install cifs-utils).


The direct use of rsync is not possible. The backup space can however be locally mounted using smbfs, sshfs or ftpfs, allowing a limited use of rsync. To take full advantage of rsync (such as incremental backups using hardlinks) an image file must be created, which should be mounted via loopback. In addition to this it is also possible to add encryption via encfs (Encrypted File System) to protect the data.


You can also access your backup space with the same hostname via IPv6. To get the IPv6 address you can for example use the following command:

dig AAAA <username>.your-backup.de

Determining memory usage

To find out how much free space you have (be it via backup scripts or status emails) you can use the "sftp" or "lftp" program:

apt-get install sftp
echo "df"     | sftp USERNAME@BACKUPSERVER
echo "df -h"  | sftp USERNAME@BACKUPSERVER
echo "df -hi" | sftp USERNAME@BACKUPSERVER

Under certain circumstances lftp can give you incorrect values, which is why sftp is recommended. Following is the variant with lftp:

# apt-get install lftp

Determining memory usage:

# echo du -s .  \

This is more readable with the parameter -h:

# echo du -hs .  \

The following command allows you to use a hook to link with Tartarus, by inserting the following lines in the Tartarus configuration:

echo "du" | /usr/bin/lftp -u "$STORAGE_FTP_USER,$STORAGE_FTP_PASSWORD" "$STORAGE_FTP_SERVER" | awk -v LIMIT=100 '$2=="." {print ((LIMIT*1024*1024)-$1)/1024 " MiB backup space remaining"}'

© 2020. Hetzner Online GmbH. Alle Rechte vorbehalten.