Upgrading High-Speed Transfer Server
To upgrade to a new version of Aspera High-Speed Transfer Server (HSTS), back up the Redis database, delete your current HSTS instance, create a new instance, and restore the database to it.
About this task
Procedure
- Identify the cluster leader. For example:
oc get pods -l cluster_role=leader NAME READY STATUS RESTARTS AGE c-quickstart-redis-m-0 4/4 Running 0 14m
- Retrieve your Redis password. You need your Redis password to save the database's dump.rdb and appendonly.aof backup files. The password is defined with the
adminPassword
key in your HSTS YAML configuration file.For example:redis: persistence: enabled: true storageClass: hsts-transfer-pvc-gid disk: 35Gi environment: adminPassword: my_redis_admin_password
- Save the dump.rdb file. The RDB file stores point-in-time snapshots of your dataset at specified intervals. Use the following syntax:
oc exec c-quickstart-redis-m-0 -c db -- redis-cli \ -a my_redis_admin_password save
- Save the appendonly.aof files. The AOF persistence file stores every write operation received by the server, which will be played again at server startup to reconstruct the original dataset.Use the following syntax:
oc exec c-quickstart-redis-m-0 -c db -- redis-cli -a my_redis_admin_password BGREWRITEAOF
- Copy dump.rb and appendonly.aof to your local
drive for later use. In this example, these files are copied to the current local directory in a new subdirectory called db:
oc cp c-quickstart-redis-m-0:/data/dump.rdb ./appendonly.aof -c db
- If you want to upgrade your version of HSTS to a configuration that is identical to your current one, save the contents of the HSTS YAML configuration file.
- Delete the current instance of HSTS.
- Create a new instance of HSTS, specifying the new version to which you will
upgrade.
- Open the YAML configuration file.
- Copy the new version number, which is identified with the
productVersion
key. - Overwrite the current YAML configuration file with your old one.
- Update the version number to the new version number.
- On the new cluster, run the following command to identify the cluster
leader. In this example, the output displays the cluster-leader name
c-quickstart-redis-m-0
:oc get pods -l cluster_role=leader NAME READY STATUS RESTARTS AGE c-quickstart-redis-m-0 4/4 Running 0 14m
- Upload the backup files dump.rd and
appendonly.aof to the cluster leader. For example:
oc cp ./dump.rdb c-quickstart-redis-m-0:/data/ \ -c db && oc cp ./appendonly.aof c-quickstart-redis-m-0:/data/ -c db
- Get the Redis process ID (PID). For example:
oc exec c-quickstart-redis-m-0 -c db -- ps -ef | grep redis 1002010+ 1 0 0 19:17 ? 00:00:00 /usr/bin/runsv /conf/service/redis 1002010+ 84 1 1 20:18 ? 00:00:38 /usr/local/bin/redis-server 0.0.0.0:6379
- Restart Redis by killing its process. For example:
oc exec c-quickstart-redis-m-0 -c db -- kill -9 84
- Check that the database restoration is successful. First use the kubctl get routes command to get the host URL. It is convenient to assign that long string to an environment variable.Then use the following command syntax. The -u option specifies the user credentials for HSTS (user name and password), with which you configured HSTS (see Getting credentials for High-Speed Transfer Server):
curl -kv --request GET \ --url https://$host:443/access_keys \ -u "node_user_name:node_user_password"
If the command returns your access keys, the database restoration was successful.
- Verify that your upgrade is successful using the OpenShift web console:
- Click Home > Projects.
- Select your project (namespace).
- In the Inventory section, click Pods.
- Select an HSTS ascp pod, which will have ascp in the name (for example, development-xeno-pn3-ascp-7f79h).
- Click the Terminal tab.
- From the Connecting to dropdown menu, select ascp.
- Once inside the ascp container shell, run
/opt/aspera/bin/ascp -A
For example:sh-4.4$ /opt/aspera/bin/ascp -A Product version information not found. ascp version 4.0.0.181185 Operating System: Linux FIPS 140-2-validated crypto ready to configure AES-NI Supported Connect Server License max rate=1000 Mbps, account no.=1, license no.=69787. Expiration date: Thu Oct 1 06:59:59 2020 Enabled settings: connect, mobile, cargo, node, drive, http_fallback_server, group_configuration, shared_endpoints, desktop_gui and sync2 sh-4.4$