10 questions taken from across the 5 paid practice sets, covering every domain of the exam guide. None of them are in the free exam. Try each one, then open the answer to see why every option is right or wrong.
A manufacturing company builds a hardened AMI each week with an EC2 Image Builder pipeline in a tooling account. Auto Scaling groups in three workload accounts launch instances from launch templates.
After each build, an engineer edits the launch templates in each account to use the new AMI. The edits are often late, and once the wrong AMI ID was entered.
The company wants each successful build to make the new AMI the one that new instances launch from in all three accounts, with no manual edits. Auditors want each launch template version to show the exact AMI ID it uses.
Which solution meets these requirements?
Choose one answer.
AA. Create an EventBridge rule in each workload account that invokes a Lambda function when an AMI is shared, and have the function create a new launch template version.
BB. Share each new AMI with the three accounts in the distribution settings, and send an Amazon SNS notification so that an engineer in each account updates the launch templates.
CC. Have each Auto Scaling group use a mixed instances policy with an instance requirements filter for the newest AMI that the tooling account has shared with the workload account.
DD. Add launch template configurations for the three accounts' templates to the distribution settings, create the cross-account distribution role in each account, and have the groups use the templates' default version.
Show the answer and explanation
Answer: D
A. Wrong: This automates the edit, but it means custom code in three accounts that the team must maintain. Image Builder distribution can update the launch templates directly. Learn more: Amazon EventBridge rules (opens in a new tab)
D. Right: Correct. Image Builder can create a new launch template version with the new AMI ID and set it as the default, including in other accounts through the EC2ImageBuilderDistributionCrossAccountRole. Groups that use the default version launch from the new AMI. Learn more: Configure AMI distribution with an EC2 launch template (opens in a new tab)
Explanation
Image Builder distribution settings can include launch template configurations. For each template, Image Builder creates a new version that references the new AMI ID and, by default, makes it the default version. In other accounts it uses the EC2ImageBuilderDistributionCrossAccountRole. Each version records the exact AMI ID for the auditors.
A fintech startup runs its payment-status API as an Amazon ECS service on AWS Fargate behind an Application Load Balancer. Each release registers a new task definition, and the service uses a rolling update.
Last week a release started tasks that could not read their database secret because the secret ARN was wrong. The new tasks failed their health checks, but the service kept retrying them, and the team found the outage 40 minutes later.
The next release must roll back on its own when new tasks cannot become healthy, with no custom code to maintain and no change to the application.
Which change meets these requirements with the LEAST operational overhead?
Choose one answer.
AA. Set the minimum healthy percent to 100 and the maximum percent to 200, then have an on-call engineer watch each deployment and update the service to the previous task definition if tasks fail.
BB. Create a CloudWatch alarm on the load balancer's unhealthy host count and an EventBridge rule that invokes a Lambda function to call UpdateService with the previous task definition whenever the alarm fires.
CC. Enable the deployment circuit breaker with rollback on the ECS service. A rolling deployment whose new tasks keep failing is marked failed and returns to the last completed deployment.
DD. Move the service to an external deployment controller and have the pipeline run a blue/green cutover after a manual approval step, so that an engineer confirms each new task set before traffic moves to it.
Show the answer and explanation
Answer: C
A. Wrong: A person must notice the failure and act, so the rollback depends on response time. This keeps the outage risk the team wants removed.
C. Right: Correct. The circuit breaker counts failed tasks and health check failures during a rolling deployment, then rolls back without human action or custom code. It is a service setting, so the application stays unchanged. Learn more: Amazon ECS deployment circuit breaker (opens in a new tab)
D. Wrong: Blue/green cutover can protect traffic, but the approval step is manual and the requirement is an automatic rollback. A failed task set would also need a separate controller to manage. Learn more: Amazon ECS deployment types (opens in a new tab)
Explanation
A rolling ECS deployment replaces tasks gradually, but by default it keeps launching replacements when they fail. The deployment circuit breaker counts tasks that never reach RUNNING and failing health checks, then marks the deployment failed and rolls back to the last completed deployment when rollback is enabled. Manual watching and custom Lambda automation both add work the team must run and maintain.
Question 3 Configuration Management and IaCFrom Practice set 2
A music streaming company's platform team publishes an AWS CDK construct library. One construct builds the standard ingestion pipeline: an Amazon S3 bucket, a Lambda function and a log group. About a dozen product teams create the construct in their own CDK apps.
The security team requires that every bucket be encrypted with a customer managed KMS key and that every log group keep logs for 400 days. Product teams must not be able to turn either setting off, even by overriding a property.
Which approach enforces these controls with the LEAST effort for the platform team?
Choose one answer.
AA. Publish the synthesized CloudFormation templates for the pipeline in a shared wiki, and ask each product team to copy the template and add the encryption and retention settings by hand before deploying.
BB. Set the customer managed key and the 400-day retention inside the construct without props that change them, and have the construct add a CDK Aspect that fails synthesis when any bucket or log group lacks them.
CC. Ask the security team to check each product's stack after deployment with an AWS Config rule, and have a Lambda function remediate any noncompliant bucket or log group by changing its settings in place.
DD. Have each product team write its own unit test that inspects the synthesized template for encryption and retention settings, and trust the teams to keep the tests in their repositories.
Show the answer and explanation
Answer: B
A. Wrong: Copying templates depends on each team following the steps, so the controls are not enforced. Drift would appear in every team's copy over time.
B. Right: Correct. Product teams cannot turn the settings off through props, and an Aspect added by the construct visits every resource in its scope during synthesis and reports an error when a setting is missing. The control runs in every team's build with no extra work for the platform team. Learn more: Aspects in the AWS CDK (opens in a new tab)
A CDK Aspect visits every construct in its scope during synthesis and can add errors. Setting the key and retention inside the shared construct, with no props that turn them off, plus an Aspect that fails synthesis makes the controls part of every build rather than a manual or after-the-fact process. Wiki templates, post-deployment remediation and per-team tests all leave room for teams to skip the controls.
Question 4 Configuration Management and IaCFrom Practice set 3
An insurance company stores its application configuration as JSON files in a Git repository. A CodePipeline pipeline already builds and deploys the application from the same repository.
Today an engineer copies each configuration change into AWS AppConfig by hand and starts a deployment. The company wants every merged configuration change deployed to the production environment automatically with its existing gradual deployment strategy, and rolled back by AppConfig if the environment's alarm fires.
The team wants no custom scripts or functions.
Which approach meets these requirements with the LEAST operational overhead?
Choose one answer.
AA. Add a CodeBuild action that calls the AppConfig CreateHostedConfigurationVersion and StartDeployment APIs with the AWS CLI for each changed configuration file.
BB. Add an AWS AppConfig deploy action to the pipeline with the application, environment, configuration profile, configuration file path and deployment strategy.
CC. Add an EventBridge rule for pushes to the repository that invokes a Lambda function, and have the function start an AppConfig deployment with the new file.
DD. Store the configuration files in the application package, and have the existing deploy action ship them with each release instead of using AppConfig.
B. Right: Correct. CodePipeline's AppConfig deploy action takes the configuration file from the input artifact and starts an AppConfig deployment with the chosen strategy. The environment's monitors still roll the deployment back on an alarm. Learn more: AWS AppConfig deploy action reference (opens in a new tab)
C. Wrong: This would deploy changes, but it adds a rule and a function to write and maintain. The pipeline already has the files and can deploy them with a built-in action. Learn more: Amazon EventBridge rules (opens in a new tab)
D. Wrong: Shipping configuration with the code loses AppConfig's gradual deployment and automatic rollback. Every configuration change would also need a full release. Learn more: What is AWS AppConfig? (opens in a new tab)
Explanation
CodePipeline has an AWS AppConfig deploy action that takes configuration from an input artifact and starts a deployment to an environment with a deployment strategy. AppConfig's environment monitors keep the automatic rollback. Scripts and functions would do the same with more to maintain.
Question 5 Resilient Cloud SolutionsFrom Practice set 3
A payments company is building a new ledger service on Amazon DynamoDB in three Regions. The table will start empty.
Each Region's application must be able to write, and a read in any Region must return the latest committed write from any other Region. If a Region fails, no acknowledged write may be lost.
The service does not use transactions, local secondary indexes or Time to Live. The team wants a managed solution with no replication code.
Which change meets these requirements with the LEAST operational overhead?
Choose one answer.
AA. Create a global table with multi-Region eventual consistency in the three Regions, so that writes replicate to the other Regions within about a second.
BB. Create the table in one Region, and have the applications in the other Regions write to it remotely and read from DynamoDB Accelerator clusters in their own Regions.
CC. Create separate tables in each Region, and use DynamoDB Streams with Lambda functions to copy each write to the other two Regions.
DD. Create the table as a global table with multi-Region strong consistency across the three Regions, and use strongly consistent reads.
Show the answer and explanation
Answer: D
A. Wrong: Eventually consistent global tables replicate asynchronously, so a read in another Region can miss a recent write. A recently acknowledged write could be lost in a Regional failure. Learn more: How DynamoDB global tables work (opens in a new tab)
D. Right: Correct. Multi-Region strong consistency replicates writes synchronously, so a strongly consistent read in any Region returns the latest version and the recovery point objective is zero. It must start from an empty table and does not support transactions, LSIs or TTL. Learn more: How DynamoDB global tables work (opens in a new tab)
Explanation
DynamoDB global tables offer multi-Region eventual consistency or multi-Region strong consistency. Strong consistency gives a zero recovery point objective and latest-version reads in every Region, and it uses three Regions, or two replicas and a witness. It starts from an empty table and excludes transactions, LSIs and TTL.
Question 6 Resilient Cloud SolutionsFrom Practice set 5
A warehouse operator's order API runs on EC2 instances in an Auto Scaling group behind an Application Load Balancer, and the target group uses the least outstanding requests algorithm. New instances pass the TCP health check as soon as the web server starts, about a minute before the application has loaded its configuration.
Those instances then get a full share of requests while their caches are still cold, so customers see errors after each scale-out.
The team wants new instances to receive no requests until the application is ready, and then a share of traffic that grows over a few minutes while caches warm. The change must stay inside the existing load balancer.
Which TWO actions meet these requirements? (Choose two.)
Choose two answers.
AA. Change the target group's health check to HTTP on a readiness path that returns success only after the application has loaded its configuration, so new targets turn healthy only when ready.
BB. Switch the target group to the round robin algorithm and turn on slow start with a duration that covers cache warm-up, so each new target's share of requests ramps up gradually.
CC. Keep least outstanding requests and turn on slow start with a duration that covers cache warm-up, so new targets ramp up while requests still favor the least busy targets.
DD. Turn on sticky sessions with a long duration, so that each customer stays on the instance that already has a warm cache and new instances receive only new clients.
EE. Increase the Auto Scaling group's health check grace period to cover start-up, so the load balancer holds requests back from each new instance until the grace period ends.
An Application Load Balancer sends requests only to healthy targets, so a readiness-based HTTP health check keeps new instances out until they can serve. Slow start then ramps each new target's share over a set duration, but it cannot be combined with least outstanding requests or weighted random, so the target group must use round robin. Sticky sessions and the Auto Scaling grace period do not control load balancer routing.
Question 7 Monitoring and LoggingFrom Practice set 4
A healthcare startup lets its 70 product teams create CloudWatch Logs log groups directly in their accounts. A new log group keeps its events forever unless someone sets a retention period, and a review found that about one third of the log groups have no retention set, so their storage grows every month.
The compliance team requires that every log group have a defined retention period, and that any log group without one be fixed within a day without a person running a script. The platform team wants the rule defined once, applied to every account, and kept in version control.
Which approach meets these requirements?
Choose one answer.
AA. Create a Config rule that checks each log group has a retention period, with automatic remediation that sets it through a Systems Manager runbook, deployed to all accounts from one template.
BB. Add a nightly Lambda function to each account that lists the log groups and sets a 30-day retention on any without one, and set up each function by hand in the console.
CC. Write an organization policy that denies logs:CreateLogGroup unless the request includes a retention setting, so teams cannot create log groups that never expire.
DD. Export every log group to Amazon S3 each night, and delete the log group after its export so that storage stops growing for groups that have no retention period set.
A Config rule can check whether each log group has a retention period, and an automatic remediation with a Systems Manager runbook sets one when it is missing. Deployed from a single template, the rule applies to every account and stays in version control. Manual Lambda functions, a create policy that cannot see retention, and deleting exported groups each fail a stated requirement.
Question 8 Incident and Event ResponseFrom Practice set 5
An auto parts manufacturer's pipeline has a source stage, a build stage, and a deploy stage that uses AWS CodeDeploy in a separate application account. The build stage succeeds, but the deploy stage fails with an error saying the provided role does not have sufficient permissions. The artifact bucket and its customer managed KMS key are in the tools account.
Other teams have pipelines that deploy to the same account without errors. The release manager needs the root cause, not a workaround, before the next release window opens.
What should the engineer do first?
Choose one answer.
AA. Run the entire pipeline again from the source stage several times to see whether the error clears on its own, since a transient permissions error often disappears on a later run.
BB. Delete the pipeline and create a new one from the same definition, since failed actions cannot be inspected on an existing pipeline and a new pipeline gets fresh permissions.
CC. Read the failed deploy action's error, then check the deploy role, the artifact bucket policy and the KMS key policy, and find the denied call in CloudTrail.
DD. Turn off encryption on the artifact bucket and rerun the deploy stage, since the KMS key is the most common cause of permission errors and removing it confirms the diagnosis.
Show the answer and explanation
Answer: C
A. Wrong: Repeating a permissions failure without reading it wastes time and can produce the same error each run. It does not show which role, bucket or key policy is missing the permission. Learn more: Troubleshooting CodePipeline (opens in a new tab)
B. Wrong: Recreating the pipeline does not change the roles, bucket policy or key policy that caused the denial. It also hides the evidence the team needs to find the root cause. Learn more: AWS CodePipeline concepts (opens in a new tab)
C. Right: Correct. The failed action's details name the failing step, and CloudTrail records the exact denied API call with its principal. Checking the role, bucket and key policies covers the cross-account parts of the deployment path. Learn more: Troubleshooting CodePipeline (opens in a new tab)
D. Wrong: Removing encryption weakens the artifact store and changes the release process, which the team did not ask for. It does not identify the missing permission, and the bucket policy may still block the deploy. Learn more: Troubleshooting CodePipeline (opens in a new tab)
Explanation
A failed pipeline action shows the error that CodePipeline received, and the CloudTrail event shows the denied call and its principal. Checking the deploy role, the artifact bucket policy and the KMS key policy covers the cross-account path, where permissions are most often missing. Reruns, recreating the pipeline and turning off encryption do not identify the cause.
Question 9 Security and ComplianceFrom Practice set 1
A nonprofit's platform team lets its 15 application teams create their own IAM roles for their services. The platform team must make sure a team can never create a role that is more powerful than the boundary it defines, and teams must still be able to attach their own policies to the roles they create.
The teams work in one shared account, and each team's roles must be able to call only the services that the nonprofit approved. The platform team wants the rule enforced by IAM itself and not by reviewing each role.
Which approach meets these requirements?
Choose one answer.
AA. Attach the approved services as an identity-based policy to each team's group, and ask the platform team to review every new role's policy before it is used in production.
BB. Create a service control policy at the organization root that lists the approved services, and rely on it to limit what the new roles can do in the shared account.
CC. Create a permissions boundary with the approved services, and require in each team's role-creation policy that iam:PermissionsBoundary equals that boundary's ARN on role changes.
DD. Give each team a separate AWS account with an AdministratorAccess policy, and use a resource-based policy on each team's S3 buckets to restrict which services the team's roles may call.
B. Wrong: A service control policy applies to the whole account and every principal, which would also affect the platform team. It does not limit each role's permissions on its own, so the per-role rule is not enforced. Learn more: Service control policies (opens in a new tab)
C. Right: A permissions boundary caps the effective permissions of any role that has it, and the condition makes IAM refuse role creation that omits the boundary. Teams can still attach their own policies, but they cannot exceed the approved services. Learn more: Permissions boundaries for IAM entities (opens in a new tab)
A permissions boundary sets the maximum permissions for a role, and a condition on role creation requires the boundary to be attached. Teams keep the ability to attach their own policies, but none can exceed the approved services. Group policies, organization-wide SCPs and resource policies do not cap every role the teams create.
Question 10 Security and ComplianceFrom Practice set 2
An analytics company's data-migration engineer must decrypt and re-encrypt about 40 million records stored in Amazon S3 with a customer managed AWS KMS key in the same account. The work is a one-time migration that will take about two weeks.
The security team requires that the key policy not be edited for this purpose, that the access be removed cleanly when the migration finishes, and that the permission name only the Decrypt and GenerateDataKey operations. The access must also apply only to records that carry the migration's encryption context.
Which approach meets these requirements?
Choose one answer.
AA. Add a statement to the key policy that lets the engineer's role use the key, then remove that statement with a second key policy change when the migration is complete, so that access is removed after the migration.
BB. Attach an IAM policy to the engineer's role that allows kms:* on the key, and detach the policy after the migration, so that the key policy stays unchanged and access ends when the policy is detached.
CC. Give the engineer the AWS managed key for Amazon S3 instead of the customer managed key, so that no key permissions need to be granted, and re-encrypt the records with that key during the migration.
DD. Create a grant on the key for the engineer's role that allows only Decrypt and GenerateDataKey, with an encryption context constraint, and retire or revoke the grant when the migration is complete.
Show the answer and explanation
Answer: D
A. Wrong: A key policy change is the very action the security team forbids for this purpose. Two edits also leave a risk that the second change is forgotten, which would keep the access open. Learn more: Key policies in AWS KMS (opens in a new tab)
B. Wrong: The kms:* action is far broader than the Decrypt and GenerateDataKey operations the team needs. The policy also grants every operation during the migration, which the requirement excludes.
C. Wrong: The AWS managed key is not under the company's control and cannot be scoped to the migration's encryption context. The change also replaces the key the security team requires. Learn more: Key policies in AWS KMS (opens in a new tab)
D. Right: Correct. A grant gives a principal named operations on a key without editing the key policy, and its encryption context constraint limits use to matching records. Retiring or revoking the grant ends the access. Learn more: Grants in AWS KMS (opens in a new tab)
Explanation
A KMS grant lets a named principal use specific operations on a key without changing the key policy, and its constraints, such as an encryption context subset, limit use to matching data. Retiring or revoking the grant ends the access when the migration is done. Key policy edits, broad IAM permissions and switching to the AWS managed key each break a stated requirement.
The DOP-C02 practice sets: 5 sets, 375 questions in the same style, none of them in the free exam. One payment of$14.99, no subscription, with access for at least 12 months.