The DevOps engineer must automate restarts for several EC2 instances after receiving AWS Health notifications, and the remediation must run only during the company’s scheduled maintenance windows. How should an Amazon EventBridge rule be set up to trigger Systems Manager to restart the instances?
Choose an answer
Tap an option to check your answer.
Correct answer: Use AWS Health as the event source and subscribe to event types that indicate scheduled instance termination or retirement. Set the rule’s target to the AWS- RestartEC2Instance Systems Manager Automation runbook to restart the EC2 instances..
Why this is the answer
The correct option directly addresses the requirements: AWS Health provides notifications for scheduled instance termination or retirement, which are the events that necessitate a restart. Setting the rule's target to the AWS-RestartEC2Instance Systems Manager Automation runbook directly performs the required action. The question specifies that remediation must run only during maintenance windows, which implies the trigger for the restart should be the AWS Health event, and the execution of the restart should be constrained by the maintenance window, often handled within the runbook itself or by a separate mechanism that pauses execution until the window. The second option is incorrect because Systems Manager as an event source for maintenance windows would trigger at the maintenance window, not when an AWS Health event occurs. The third and fourth options are overly complex, introducing a Lambda function to register a maintenance window task. While possible, it's not the most direct or efficient solution when a direct EventBridge to Systems Manager Automation integration exists for this exact purpose.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed