HDD-Housing e.U.

Disaster recovery: install the backup drive at your site and start the services

Note: Replace poolname in all commands with your customer ID.

For large amounts of data, the postal route is faster than a restore over the internet: you send us new drives with enough space, we copy your pool onto them and send them back. Your offsite backup with us remains unchanged. By default we copy the pool with all snapshots. If you only need the current state or a specific snapshot from before the incident, let us know – this saves time and space on the drives.

The drives contain the same ZFS pool as on our server, including your VersityGW users and Syncthing configuration. The procedure therefore largely matches the setup, just without creating the pool: import the pool, start the services, restore.

1. Import the pool

Install the drives (or connect them via USB), then on the Proxmox host or Debian/Ubuntu system:

zpool import            # lists importable pools
zpool import poolname
zpool status poolname
zfs list -r poolname    # poolname/versitygw and poolname/syncthing

If zpool import reports that the pool is in use by another system, import it with zpool import -f poolname.

zfs list -t snapshot -r poolname lists the copied snapshots. Their content is available read-only under /poolname/versitygw/.zfs/snapshot/ and /poolname/syncthing/.zfs/snapshot/.

2. Check permissions

On our server the services run in unprivileged LXC containers, so the files belong to user IDs 101100 (VersityGW) and 101110 (Syncthing).

chown -R 1100:1100 /poolname/versitygw
chown -R 1110:1110 /poolname/syncthing

3. Create the container (Proxmox only)

Create an LXC container as described in the LXC guide and mount both datasets with mp0 and mp1. One container for both services is enough.

4. Start VersityGW

Install VersityGW as described in the VersityGW guide and create the user and configuration. Keep the following in mind:

systemctl enable --now versitygw@versitygw
systemctl status versitygw@versitygw

The S3 storage is now reachable on your local network at http://container-IP:7070.

5. Start Syncthing

Install Syncthing as described in the Syncthing guide and create the user with the same commands (groupadd, useradd with ID 1110 and home directory /poolname/syncthing).

The Syncthing configuration, including the device ID, is stored in the home directory on the pool. So the same instance as on our server starts, with the same folders, devices and the same web GUI password.

Important:

  • The same instance must not run in two places at once. We stop the instance on our side after shipping the drives or at a time agreed with you. Only start it at your site after that.
  • If your devices were hit by ransomware, clean or replace them first. Otherwise they will immediately synchronise the encrypted files to the restored instance again.
systemctl enable --now syncthing@syncthing
systemctl status syncthing@syncthing  # shows the IP and port in use

6. Restore your data

Use your backup software as usual, just with the local address instead of https://s3.customerid.hdd-housing.at, e.g. http://192.168.1.50:7070 (IP of your container or server). Credentials and passwords stay the same.

All data is also stored as ordinary files on the pool: S3 buckets under /poolname/versitygw/buckets/, Syncthing folders under /poolname/syncthing/. On the machine with the pool, Restic and Borg repositories can also be opened directly via this path.

Questions about the procedure? Email us at support@hdd-housing.at.