Configuring Backtracking


Configuring Backtracking

Setting the backtrack window for Amazon Aurora clusters allows you to "rewind" the database cluster to the time you specify much more easily than manually restoring from a snapshot. Learn more about the benefits of backtracking in this article from AWS.

Backtracking is not available for AWS GovCloud.

The default value for the BacktrackWindowParameter is 0, which means backtracking is disabled. Since the backtrack value must be set during the initial deployment of the database, existing users must redeploy their database to enable it. If you choose to redeploy your database, you won't lose any of your data.

To add backtracking, create a new database with the setting enabled, switch over the Kion application to the new database, and delete the old database. This process will result in some application downtime.

To create a new database, you will need an AWS CloudFormation template. Before beginning this process, download the kion-aurora.yml file from the AWS Deployment Guide.

To Create a New Database and Move the Kion Application:

  1. Start by taking a manual backup. For guidance on taking manual backups, see our AWS Database Backup Guide.

  2. Let users know that the application is going down for maintenance.
  3. Create a new database using the cloudtamer-aurora.json file.
  4. Change the Namespace field in the AWS CloudFormation template, ensuring it is different from the namespace field in the current database.
  5. Paste your latest snapshot ARN into the DBSnapshotID field. The snapshot ARN can be found by accessing the AWS Console, navigating to Services > RDS > Snapshots . Click the name of the snapshot you want to restore from. The ARN is at the top of the details listed. 
  6. Change the BacktrackWindowParameter field to a number greater than 0 to enable it. The parameter value is in seconds, so entering 3,600 would be 3,600 seconds or 1 hour. The maximum value is 259,200 (72 hours).
  7. Launch the creation of the stack.
  8. Once the database is available, update the cloudtamer-app AWS CloudFormation stack with the new database URL. Ensure you use the cluster writer endpoint, not the reader endpoint.
  9. In the first Additional Security Groups field (above HTTP_PROXY), remove the existing entry that has kion-rds (or cloudtamer-rds), and update it with the security group ID for your new database stack. If you have other selections in this box, leave them alone as these control the security groups assigned to your Kion nodes or tasks.
  10. Once the app AWS CloudFormation stack finishes, check that you can access the application from your web browser.
  11. Once you have verified the application is working, you can delete the old DB AWS CloudFormation stack.

The backtrack feature does have some limitations, which are detailed in this article from AWS.