Restoring the Cluster Node Database

If you relaunch a cluster and have a back ups of your Scale KV database (see Backing up the Cluster Node Database) and access keys (see Backing up and Restoring Access Keys), you can restore the database and access keys to the new cluster nodes.

  1. Restore your access keys.
  2. Log in to a cluster node using the SSH key that you configured in the Provider section of your cluster template.
  3. Copy the backup files to a new cluster node by running the following command:
    # /opt/aspera/bin/axcloudcp url_prefixstorage_acces_key:secret@object_storage_url/path/ .

    This command copies the entire backup directory to the local directory. For example, to copy files back from S3:

    # /opt/aspera/bin/axcloudcp s3://EIFNWEIGUBNDSE:Se3rnf23neifh3@s3.amazonaws.com/mycompany-tmp/backups/ .
  4. Restore the node data by running the following command:
    # /opt/aspera/bin/ascalekvadmin replay --timeout 60 --aof scaledb-default-0-0.aof --aof scaledb-default-1-0.aof

    Add additional --aof options and arguments for each backup file, as needed. During restoration, the following output is generated:

    # /opt/aspera/bin/ascalekvadmin replay --timeout 60 --aof scaledb-default-0-0.aof --aof scaledb-default-1-0.aof
    All data transferred. Waiting for the last reply...
    Last reply received from server.
    All data transferred. Waiting for the last reply...
    Last reply received from server.

    The Scale KV database is propagated to the other cluster nodes.

  5. Confirm that the restoration was successful.
    Attempt a transfer with a Access key that worked prior to the restoration.
    Note: Depending on your original cluster deployment, you might need to upgrade the database or perform other restoration actions.