Backups

Backups of the dockerised caliper system can be made by simply copying the data folders. From the root of the caliper system folder (this is the caliper folder of the git repository) these data folders are:

  • volumes - this is the data folder associated to Fuseki
  • showvoc-docker/volumes - this data folder contains both the data for ShowVoc and VocBench


Backups can be done by running the backup_volumes.sh script in the scripts folder of the respository. You can edit the backup script accordingly as the script is highly documented. You only have to update the following specific parts:


  1. Google Cloud Storage (GCS) bucket that you have access to and want to use. (Line 23). In the case of the test instance this value is fao-datalab-backups.
  2. The full system directory where the caliper instance is installed, in the case of the datalab caliper internal test instance, this is /opt/caliper_internal_test/caliper. (Line 20)
  3. GCS storage directory. (Line 51). In this case …/caliper/internal/test


The backup script archives both data directories and uploads the archives to Google Cloud Storage. The archives follow these conventions:


  1. Fuseki - fuseki_volume_<BACKUP_TIMESTAMP>.tar.gz
  2. ShowVoc/VocBench - vocs_volume_<BACKUP_TIMESTAMP>.tar.gz


Restore

Restores can be done by running the restore_volumes.sh script in the scripts folder of the git repository. You can edit the restore script accordingly as the script is highly documented. You only have to update the following specific parts:


  1. Ensure that the docker services are not currently running
  2. The caliper root folder. In the case of the test instance, it’s /opt/caliper_internal_test/caliper (Line 19)
  3. The Google Cloud Storage (GCS) bucket. In the case of the test instance this value is fao-datalab-backups (Line 20)
  4. Backup timestamp (Line 25). This is the timestamp of the backup you want to use from the GCS bucket.
  5. The GCS storage directory (Lines 34 and 62). In this case it’s …/caliper/internal/test


The restore_volumes.sh script, deletes the existing data folders if any, downloads the backup files from GCS and extracts them to the relevant data folder paths.

Write a comment…