No Deploy Friday logoNo Deploy FridayHomeShopBlogAbout

AWS Solutions Architect: Exam Question Deep Dive

by Ezra Bowman

Deep dive into a question from the AWS Solutions Architecture Professional Exam about disaster recovery options using EC2, RDS, EBS, and AWS Storage Gateway.

As I have prepared for AWS exams, I found dissecting exam questions helpful to grow my AWS knowledge. This post is a bite-sized study guide that will hopefully expand your knowledge of AWS and help you on your journey to becoming a Solutions Architect as well.

For each post in this series, I am choosing one AWS Solutions Architect Professional exam question. We will explore the required knowledge and strategy to find the right answer and learn about a few AWS services along the way.


The following question is from the AWS Certified Solutions Architect, Professional Level — Sample Exam Questions provided by Amazon.

Your company’s on-premises content management system has the following architecture:

  • Application Tier –Java code on a JBoss application server
  • Database Tier–Oracle database regularly backed up to Amazon Simple Storage Service (S3) using the Oracle RMAN backup utility
  • Static Content–stored on a 512GB gateway stored Storage Gateway volume attached to the application server via the iSCSI interface

Which AWS based disaster recovery strategy will give you the best RTO?

  • A) Deploy the Oracle database and the JBoss app server on EC2. Restore the RMAN Oracle backups from Amazon S3. Generate an EBS volume of static content from the Storage Gateway and attach it to the JBoss EC2 server.
  • B) Deploy the Oracle database on RDS. Deploy the JBoss app server on EC2. Restore the RMAN Oracle backups from Amazon Glacier. Generate an EBS volume of static content from the Storage Gateway and attach it to the JBoss EC2 server.
  • C) Deploy the Oracle database and the JBoss app server on EC2. Restore the RMAN Oracle backups from Amazon S3. Restore the static content by attaching an AWS Storage Gateway running on Amazon EC2 as an iSCSI volume to the JBoss EC2 server.
  • D) Deploy the Oracle database and the JBoss app server on EC2. Restore the RMAN Oracle backups from Amazon S3. Restore the static content from an AWS Storage Gateway-VTL running on Amazon EC2

First, let’s make sure we understand what they are asking. A company has an on-prem data center with two servers that have backups on AWS. For disaster recovery, we are going to move these servers to AWS and get their system back up and running. The question is looking for the best RTO or return to operations. When considering possible solutions, all we need to care about is what is fastest. Don’t worry about the cost or anything else — only speed.

Next, let’s look at the differences in the possible answers. Three elements appear in each of the possible answers. We need to look at how to deploy the servers, recover the database, and recover the static files.

  1. Options for server deployment:
  • Both app and database server on EC2 [A, C, D]
  • App server on EC2; database server on RDS [B]
  1. Options to restore the database:
  • S3 [A, C, D]
  • Glacier [B]
  1. Options to restore static content with the Storage Gateway
  • EBS volume on the JBoss server [A, B]
  • AWS Storage Gateway on EC2 as iSCSI volume on JBoss server [C]
  • Use AWS Storage Gateway-VTL running on an EC2 instance [D]

Just based on how they have differentiated the options in each possible answer, I would guess C or D is the right answer — if you are running low on-time, pick one of these and move on. Let’s see if I am right.

Digging Deeper

First, let’s jump to S3 vs. Glacier. This is the easy one. Glacier is the cold-storage version of S3, which can take hours to provide the requested data. The S3 standard storage class will return data almost immediately, so let’s assume our backups are there. The question does not specify the S3 storage class. Therefore, we can eliminate option B.

Next, since we have eliminated option B, we only need to see what’s different between A, C, and D. All of those answers restore the Oracle database to an EC2 instance, not to RDS. Looking into this won’t get us any better information, so we need to focus on the static data and how to restore it using AWS Storage Gateway.

To answer this, we need to know a bit about AWS Storage Gateway. This service provides a way to backup and store data in S3 for your on-prem servers. It provides 3 different gateway types:

  • File Gateways
  • Volume Gateways
  • Tape Gateways

We can tell from the somewhat clunky wording of the question (“a gateway stored Storage Gateway volume”) that they are using a Volume Gateway, and more importantly, that they are using Stored Volumes. Volume Gateways can be used to access Cached Volumes or Stored Volumes. Based on their wording in this problem, we are using a Stored Volume.

Knowing this means we can eliminate answer D. Answer D refers to VTL, which stands for Virtual Tape Library. Since the question is asking about a Volume Gateway and not a Tape Gateway, D is incorrect.

The following diagram shows the on-prem configuration of an AWS Storage Gateway, specifically a Volume Gateway using Stored Volumes. Stored Volume Storage Gateway

Volume Gateway appliances are virtual machines (VM image provided by AWS) that run in your on-prem data center. This VM provides an iSCSI interface to your local servers to access data.

  • In the Cached Volumes configuration, the primary data store is in the cloud (AWS S3). As the server writes data to the Gateway, it is only cached locally and then written to volumes in S3.
  • In the Stored Volumes configuration, the primary data store is your on-prem storage. As the server writes data to the on-prem volumes, they are backed up to S3 as EBS snapshots.

There we find our answer: A.

The fastest way to recover the static files is simply to restore the backup (saved as an EBS snapshot) to an EBS volume and attach that volume to the JBoss app server. Answer C might also work, but would be slower. The AWS Storage Gateway is a VM image that can be provisioned to an EC2 instance. This instance could then provide the iSCSI interface to the JBoss app server EC2 instance, but the time required to set up the 3rd EC2 instance as the storage gateway isn’t worth it. The EBS snapshot can be restored and used directly by the app server.


In case you are curious — Even though we already found our answer, let’s see if there is any difference in restoring the database server to EC2 or RDS.

In the context of the question, we want to assess whether restoring to a self-managed database server (EC2) or an RDS instance is faster.

RDS makes it easy to spin up database instances of all types, including Oracle. RDS also has settings that automatically backup databases to S3. The reasons to run Oracle on an EC2 instance are for more advanced setups where you need full control of the database and system, or you are using Oracle features or spec limits (e.g., required IOPS) that are not supported by RDS. Initially, it looks like RDS will be faster to get set up. However, there is a problem with this. We are performing disaster recovery for an on-prem Oracle database backed up with RMAN. As of March 2019, RMAN restore isn’t supported for Amazon RDS for Oracle DB instances. This also eliminates answer B.


Thanks for reading! Please leave feedback and let me know if you enjoyed this post. If you are interested in other posts I have written about other AWS services, cloud solutions & architectures, check me out on Medium https://medium.com/@ezrabowman

References

  1. https://docs.aws.amazon.com/storagegateway/latest/userguide/StorageGatewayConcepts.html#storage-gateway-cached-concepts
  2. https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Appendix.Oracle.CommonDBATasks.RMAN.html


No Deploy Friday logo

Related Posts