Applying Disaster Recovery Techniques in AWS

Hands-On Lab


Photo of Craig Arcuri

Craig Arcuri

AWS Training Architect II in Content





In this learning activity, the student will investigate different techniques in AWS for disaster recovery. The lesson will present AWS Disaster Recovery techniques and quantify the appropriate use cases, based RTO/RPO, for each technique. The student will then utilize a CloudFormation template to recover a large environment with many AWS Resources. This exercise will show that CloudFormation is a viable option for all but the most aggressive recovery timeline. A risk in using CloudFormation in Disaster Recovery is that hardcoded AMI IDs can change. The student will examine a CloudFormation template that has a Lambda function and can retrieve AMIs in real-time. The student will execute this template and verify that an EC2 instance was created.

What are Hands-On Labs?

Hands-On Labs are scenario-based learning environments where learners can practice without consequences. Don't compromise a system or waste money on expensive downloads. Practice real-world skills without the real-world risk, no assembly required.

Applying Disaster Recovery Techniques in AWS


In this hands-on lab, we will use a CloudFormation template to tackle stack recreation and get a chance to dive further into disaster recovery techniques through AWS.


Log in to the AWS live environment via the cloud_user credentials provided. We must also ensure that we are working in the us-east-1 (N. Virginia) region.

Create a CloudFormation Stack

  1. From the AWS Management Console, navigate to S3.

  2. Go into the provided S3 Bucket and copy the URL of one of the provided templates (JSON or YAML, they both create the same resources).

    Note: A URL is provided in the Additional Information and Resources section to retrieve the file.

  3. Click Upload.

  4. Click Next.

  5. Click Next.

  6. Click Next.

  7. Click Upload.

Create a Cross-Stack Reference

  1. Select the main CloudFormation stack via the checkbox and click Actions > Delete Stack.

  2. Click on the GitHub template and copy the template's code, instead of directly downloading the template this time.

  3. Click Design Template in CloudFormation, and then create the stack using the revisions we made in the template.

    Note: Ensure that we remain on the template tab when pasting any of the revisions in.

  4. On the S3 Management Console, click on the JSON file and copy the URL of it.

  5. Navigate back to the CloudFormation Management Console.

  6. Click Create Stack.

  7. Ensure that Specify an Amazon S3 template URL is selected via the bubble.

  8. Paste in the URL of the revised template.

  9. Click Next.

  10. In the Stack name field, provide a name for the stack e.g., DR Stack.

  11. Under Parameters, click on the WebServerKeyName dropdown and choose drkey.

  12. Click Next on the Options page.

  13. Click Create on the Review page.

    Now, we will create a stack using the "AMILookup" Template.

  14. Navigate back to the S3 Management Console.

  15. Click AMILook.json template file.

  16. On the Overview tab, copy the URL.

  17. Navigate back to the CloudFormation Management Console.

  18. Click Create Stack.

  19. Click the bubble to select Specify an Amazon S3 template URL.

  20. Paste in the template URL.

  21. Click Next.

  22. Create a Stack name, such as amilookup.

  23. Set up the following for the Parameters section:

    • InstanceType: t2micro
    • ModuleName: amilookup
    • S3Bucket: Copy and paste the S3 bucket URL located towards the top of the S3 Management Console page
    • S3 Key:
  24. Click Next.

  25. Accept defaults, click Next.

  26. Check the "I acknowledge that AWS CloudFormation might create IAM resources" portion at the bottom of the page.

  27. Click Create.

    Our stack creation is now completed.

  28. It is optional, but we can verify further by navigating back to the S3 Management Console > EC2.

  29. Click Running instances.

    Note: We should see the new instance that was created, that shows as "initializing" under Instance State.

  30. If we click on the checkbox on the left-hand side next to our instance, then we can view more details on our creation via the Description tab.


Congratulations - you've completed this hands-on lab.