Backing up and restoring a tethered node database

This article describes how to back up and restore the entire Redis database of a node, which includes Node API users, their access keys, and transfer history.

If your transfer server is an IBM Aspera on Cloud (AoC) node, you can migrate AoC data from one node to another by backing up the Redis database on the original node and restoring the database on a new node.

If you need to back up and restore only the Node API user names and passwords (the Node API user database), or if you want to back up and restore only the access keys, refer to the IBM Aspera HSTS documentation.

These instructions assume that the node is using the default port for the Redis database, port 31415. If your deployment uses a different port for Redis, substitute it in the commands accordingly.

Process map

ssl certs firewall HTTPs proxy configure node nginx transfer user optional for HA cluster add node mark remote storage alee and aejd backup and restore

Procedure

  1. Verify that the original node and new node are running the same version of Aspera software.

    Run ascp -A on a command line to view the Aspera product and version

  2. On the original node, stop apseranoded and back up the database:
    # systemctl stop asperanoded
    # /opt/aspera/bin/asredis -p 31415 BGREWRITEAOF

    The backup file is /opt/aspera/var/appendonly.aof.

  3. If you are migrating the database, move the appendonly.aof file to the same location on the new node.
  4. On the new node, stop asperanoded:
    # systemctl stop asperanoded
  5. Flush the existing data from the Redis database on the new node:
    #/opt/aspera/bin/asredis -p 31415 FLUSHALL
  6. Load the backup data into the new node database:
    # cat appendonly.aof | /opt/aspera/bin/asredis --pipe -p 31415
  7. On both nodes, restart asperanoded:
    # systemctl start asperanoded
  8. Confirm the database restoration succeeded.
    Use the following syntax to run the command on both the original node and the new node. If the database restoration succeeded, the output from each is identical.
    # curl -ki -u {node_username:node_password} http[s]://{hostname}:{http_port}access_keys
    Note: Curl is included in many Unix-based distributions. To check if it is installed, enter curl on the command line. If it is not installed, download it from the Curl website: https://curl.haxx.se/download.html.
  9. In AoC, confirm that the hostname matches the DNS entry for the new node.

    To view the node hostname and URL, go to Admin > Nodes and storage.