Q77 — AWS DOP-C02 Ch.2

Question 77 of 100 | ← Chapter 2

An e-commerce company uses Amazon EC2 instances backed by Amazon EBS volumes. To reduce manual effort for managing instances, a DevOps engineer must automatically restart EC2 instances when scheduled maintenance events occur. How can this be achieved?

Correct Answer: D. Set up an AWS Health Amazon CloudWatch Events rule to execute an AWS Systems Manager Automation document that stops and starts EC2 instances upon occurrence of a scheduled maintenance event.

Explanation

AWS Health publishes service events—including scheduled maintenance—and integrates with Amazon CloudWatch Events to trigger automated responses. AWS Systems Manager Automation documents can be invoked via CloudWatch Events to perform precise remediation actions like stopping and starting EC2 instances in response to AWS Health maintenance notifications. This approach is documented in AWS best practices for automating remediation for EC2 notifications. Option D directly implements this pattern. Option A uses generic scheduling rather than reacting to actual AWS Health events. Option B misuses auto-recovery, which responds to instance failures—not scheduled maintenance. Option C relies on manual scheduling and lacks automation tied to AWS Health events.