How to restore configuration and Data - Reinstallation

NethServer Version: 7
Module: Restic

I had NS7 setup as VM over Proxmox in my Dell Server, and the HDD crashed with no redundancy. Luckily there was Proxmox backup to the USB HDD which is scheduled to take snapshot backup, and I was able to restore the NS7 VM almost completely with little help from my FRIEND.

The data have 2 days of missing data, which I intend to recover from the Restic Backup, which is scheduled to run everyday to my NAS. Problem is that in Backup in Cockpit, I cannot see the latest snapshot, which I think should be since the NS don’t know about the backup configuration. I go through the documentation which says that first I need to restore the configuration, and keep the setting reinstall the module checked and then only I am unable to restore the data. But how to restore the configuration – Url, upload the config, and from backup options are there in Restore Configuration.

Good question, cannot find backup-config.tar.xz at the restic backup directories.
It’s there for using the duplicity engine:

find . -name "*config*"
./restic/config
./duplicity/labns01/backup-config.tar.xz

(in /restic did a backup using the restic engine in /duplicity with the duplicity engine)

EDIT:
It is in the restic backup data set (ie repository)

# restic find -p ~/pass -r restic/ backup-config*
repository 6ae51db8 opened successfully, password is correct
Found matching entries in snapshot 92b28223 from 2021-06-24 14:15:58
/var/lib/nethserver/backup/backup-config.tar.xz
/var/lib/nethserver/backup/backup-config.tar.xz-content.md5
/var/lib/nethserver/backup/backup-config.tar.xz.md5

This seems to be a bit unpractical; one needs access to the the restic dataset/repository (with the password) on an instance with restic installed and recover backup-config.tar.xz manually before a disaster-recovery is possible…

Or am I overseeing something?

@stephdl @mrmarkuz Sir, I have the Restic encryption Key, and the backup files in NAS. But I couldn’t see the last backup because, I recovered the NS7 VM from the proxmox backup which was older.

Steps could be to restore the config first, And then the ibay data. I am unable to do that, Pls guide how to do that.
image The Cron on 19th June is missing, and is available in NAS Backup
As you can see on 24th again the Cron Backup takes the backup to the NAS, but lot of unupdated files. Total backup size is 600 GB. Now I need the selected backup to some other place.

In NS7 Cockpit > Backup > config restore there are three option from URL, Upload backup file, and the last is from backup file.
image

Restored the data (Specific) manually using Restic. Its a straight forward method is to first look at the backup snapshot desired.

ssh to the NS or Gui terminal

restic -r /restic-repo snapshots
enter password for respository ( encryption key)

Note restic-repo is the full path location of the restic backup (in my case was the NAS)

After finding the snapshot and in my case e2eeff74 restore using

restic -r /restic-repo restore e2eeff74 --target
enter password/key

If you want to restore the specific folder or file then

restic -r /restic-repo restore e2eeff74 --target --include /work/foo
enter password/key

Note /work/foo is the name of the specific folder in the backup.

2 Likes