To backup and restore the Redis database (and your user data up to the point-in-time
of the backup operation), follow the instructions below. Note that the backup and
restore operations should be used for the following scenarios:
- If you need to change the Redis database port number
(<db_port/> in aspera.conf), you should first backup the Redis database. Once
you have changed the port number, you need to restore the database.
- Basic backup and restore (after a data-loss event).
-
Back-up the Redis database.
Use the following command to back-up your Redis database (which should be
done before changing the port number):
# /opt/aspera/bin/asnodeadmin -b /your/backup/dir/database.backup
IMPORTANT NOTE: When backing up the Redis database, all user data
up to that point-in-time will be saved to the backup file. Restoring
the database (see Step 2, below) does not delete users added after
this snapshot was taken. Thus, if you added any users after
backing up the database, then they will still exist in the system and
will not be affected by the restore operation.
-
Restore the Redis database.
Use the following command to restore your Redis database:
# /opt/aspera/bin/asnodeadmin -r /your/backup/dir/database.backup
Recall the "Important Note" in Step 1, which stated that restoring the
database does not delete users added after the database snapshot was
taken. If you do not want to keep users that have been added since
the last backup operation, you can delete them after performing the restore
with the asnodeadmin command -du
username.
-
Restart the asperanoded service.
Use the following command(s) to restart the asperanoded
service (where a RESTART is required, rather than reload):
# /etc/init.d/asperanoded restart