SaveMyCert
Log in
2 of 2 free questions left today·for 5 a day
Monitoring, Logging, Analysis, Remediation, and Performance Optimization

Automated Remediation: EventBridge, Runbooks, and EC2 Recovery (SOA-C03)

20 min readSOA-C03 · Monitoring, Logging, Analysis, Remediation, and Performance OptimizationUpdated

Automated remediation is the practice of detecting an operational problem from metrics, alarms, or events and fixing it without a human logging in — the core of SOA-C03 Task 1.2. The exam assumes the metrics and alarms already exist (that was Task 1.1) and asks what happens next: how you isolate the failing component with metric math, anomaly detection, and CloudTrail correlation, and how you wire detection to action — an alarm's EC2 recover or reboot action, Auto Scaling replacing an unhealthy instance, EventBridge routing an event to Lambda, or a Systems Manager Automation runbook executing a documented fix. It also tests the unglamorous parts: shaping event input for targets, scheduling automation, routing events across Regions and accounts, troubleshooting an EventBridge rule that never fires, and verifying a remediation actually worked. This lesson walks the full detect-route-act-verify loop, compares the remediation patterns the exam makes you choose between, and covers the newer signal sources: the AWS Health Dashboard, Kiro, and AWS DevOps Agent.

What you’ll learn

  • Trace the remediation loop — detect, route, act, verify — and place each AWS service in it
  • Analyze incidents with metric math (including IF), composite alarms, tuned anomaly detection, and CloudTrail change correlation
  • Choose between EC2 recover and reboot actions, offline OS repair, Auto Scaling replacement, Lambda, and Systems Manager runbooks for a given failure
  • Build and troubleshoot EventBridge rules, target input modes, schedules, and cross-Region and cross-account routing
  • Run predefined and custom Automation runbooks with the right permissions, and choose between Run Command, State Manager, and maintenance windows
  • Use OpsCenter, the AWS Health Dashboard, Kiro, and AWS DevOps Agent as parts of the remediation loop

The 10 parts · about 16 min of reading

  1. The remediation loopStart hereEvery remediation design is detect, route, act, verify, and the exam favours managed loops that confirm the metric recovered.1 min
  2. Isolating the failing componentMetric math for rates and gated conditions, anomaly detection for cyclical metrics, and CloudTrail to find the change behind an outage.2 min
  3. EC2 status checksSystem versus instance check failures map to recover versus reboot, plus offline root-volume repair and Auto Scaling health replacement.3 min
  4. Choosing a remediation patternA menu of five remediation wirings and two habits: prefer managed capability over code, and match the action to the blast radius.1 min
  5. EventBridge in depthBuses, exact case-sensitive patterns, input shaping without Lambda, and a metric-led checklist for rules that never fire.2 min
  6. Scheduling automationRate versus six-field cron expressions, and why EventBridge Scheduler with a time zone beats a UTC-only rule for local times.1 min
  7. Routing events across Regions and accountsForwarding events to a central bus across Regions or accounts: the policies and roles each side needs, and the one-hop limit.1 min
  8. Systems ManagerAutomation runbooks and their permissions, Run Command versus State Manager versus maintenance windows, and OpsCenter OpsItems.2 min
  9. Wider signalsAWS Health events as a remediation source and their Regional delivery, plus what Kiro, DevOps Agent and Amazon Q are each for.2 min
  10. Walkthrough: auto-healing a web tierA worked design: ELB health checks heal the fleet, two status-check alarms protect a stateful server, and a pattern bug gets fixed.1 min

Mind map

Signals: alarms, status checks, HealthRoute via alarm action, SNS orEventBridgeVerify the detecting metric recoversManaged loops beat hand-run commands1✓Detect, route, act,verifyMetric math: alarm on error rateIF() gates on request volumeAnomaly bands for cyclical metricsCloudTrail shows what changed and who2✓Isolate the failingcomponentSystem check: recover to new hardwareInstance check: reboot or OS repairRecover keeps ID, IPs and EBS volumesEC2Rescue repairs an unbootable rootvolumeGrace period above warm-up time3✓EC2 status checksManaged capability over custom codeFleets: Auto Scaling replacementMulti-step fixes: Automation runbookNotify humans via SNS in parallel4✓Choosing a patternPatterns: exact and case-sensitiveInput transformer reshapes withoutLambdaMatchedEvents zero: pattern, bus orRegionFailedInvocations: target permissions5✓EventBridge in depthrate(6 hours); singular only for 1cron has six fields; one day field is?Scheduled rules run cron in UTC onlyScheduler: IANA time zone, follows DST6✓Scheduling automationRule targets a bus in another RegionReceiver policy: aws:PrincipalOrgIDCLI and IaC need the sender IAM roleOne hop only; no third-accountforwarding7✓Cross-Region andcross-accountNo assume role: starter permissionsapplyRun Command: once, at scale, no SSHState Manager reapplies, incl. newnodesOpsItems dedupe on /aws/dedup8✓Systems ManagerAccount health shows your retirementsHealth events arrive per RegionOne us-west-2 rule gets all RegionsDevOps Agent investigates; Kiro builds9✓Health events and AItoolsELB health checks heal the fleetSystem-check alarm with recover actionInstance check routes to a restartrunbookBug: pattern missed nested state.value10✓Walkthrough: auto-healingAutomatedremediation
Mind map

Automated Remediation: EventBridge, Runbooks, and EC2 Recovery (SOA-C03)

Signals: alarms, status checks, HealthRoute via alarm action, SNS orEventBridgeVerify the detecting metric recoversManaged loops beat hand-run commands1✓Detect, route, act,verifyMetric math: alarm on error rateIF() gates on request volumeAnomaly bands for cyclical metricsCloudTrail shows what changed and who2✓Isolate the failingcomponentSystem check: recover to new hardwareInstance check: reboot or OS repairRecover keeps ID, IPs and EBS volumesEC2Rescue repairs an unbootable rootvolumeGrace period above warm-up time3✓EC2 status checksManaged capability over custom codeFleets: Auto Scaling replacementMulti-step fixes: Automation runbookNotify humans via SNS in parallel4✓Choosing a patternPatterns: exact and case-sensitiveInput transformer reshapes withoutLambdaMatchedEvents zero: pattern, bus orRegionFailedInvocations: target permissions5✓EventBridge in depthrate(6 hours); singular only for 1cron has six fields; one day field is?Scheduled rules run cron in UTC onlyScheduler: IANA time zone, follows DST6✓Scheduling automationRule targets a bus in another RegionReceiver policy: aws:PrincipalOrgIDCLI and IaC need the sender IAM roleOne hop only; no third-accountforwarding7✓Cross-Region andcross-accountNo assume role: starter permissionsapplyRun Command: once, at scale, no SSHState Manager reapplies, incl. newnodesOpsItems dedupe on /aws/dedup8✓Systems ManagerAccount health shows your retirementsHealth events arrive per RegionOne us-west-2 rule gets all RegionsDevOps Agent investigates; Kiro builds9✓Health events and AItoolsELB health checks heal the fleetSystem-check alarm with recover actionInstance check routes to a restartrunbookBug: pattern missed nested state.value10✓Walkthrough: auto-healingAutomatedremediation

How the exam tests this

Task 1.2 questions hand you a failure and make you pick the remediation wiring. "Underlying hardware failure" points to a StatusCheckFailed_System alarm with the recover action — unless the instance is in an Auto Scaling group or on a Dedicated Host; an OS hang points to the instance check and the reboot action, and an OS that will not boot points to offline repair. Expect questions on what recovery preserves, why an EC2 action is unavailable (no InstanceId dimension), and Auto Scaling grace periods. EventBridge questions cover target input modes, cron and rate syntax, Scheduler time zones, cross-Region and cross-account routing, and "the rule never ran" troubleshooting with rule metrics. "Least operational overhead" and "no custom code" steer you toward predefined Automation runbooks; runbook permission failures point to the assume role; "stays enforced, including new instances" points to State Manager; duplicate OpsItems point to deduplication strings.

Key takeaways

  1. The recover action attaches only to a StatusCheckFailed_System alarm: it keeps instance ID, IP addresses and EBS volumes, loses RAM, instance store data and uptime, and is not supported for Auto Scaling group members or Dedicated Hosts.
  2. StatusCheckFailed_Instance means an OS-level problem — a system-check alarm never fires for it; use the reboot action, and repair an unbootable OS offline with AWSSupport-ExecuteEC2Rescue or a helper instance.
  3. EC2 alarm actions need a per-instance metric (InstanceId dimension); Auto Scaling replaces unhealthy fleet instances, ELB health checks catch application hangs, and the grace period must exceed warm-up time.
  4. Gate multi-condition alerts with a metric math IF expression or a composite AND alarm; exclude abnormal periods from anomaly detection training, and remember a higher band threshold widens the band.
  5. An EventBridge rule invokes all its targets immediately; target input can be the whole event, an input path, constant JSON, or an input transformer template.
  6. Rule cron is six fields in UTC with ? in one day field; rate units are singular only for 1; EventBridge Scheduler adds IANA time zones with daylight saving adjustment.
  7. Cross-account bus targets need a receiving bus policy (aws:PrincipalOrgID for an organization) and a sender-side IAM role; events are never forwarded on to a third account.
  8. Without an AutomationAssumeRole a runbook runs with the starter’s permissions; State Manager enforces configuration continuously, maintenance windows run only in their window, and OpsCenter dedup strings stop duplicate OpsItems.
  9. AWS Health events reach EventBridge per Region (global events in us-east-1, backups in us-west-2); a single us-west-2 rule (simplified integration) collects account-specific events from all Regions.
0/10
Ready to start

Part 1: The remediation loop

Every remediation design is detect, route, act, verify, and the exam favours managed loops that confirm the metric recovered.

1 min read · 10 parts, about 16 min in allStart lesson

Frequently asked questions

What is the difference between EC2 system status checks and instance status checks?

A system status check (StatusCheckFailed_System) monitors the AWS infrastructure the instance runs on — physical host hardware, power, and network connectivity. A failure there is AWS's layer, and the fix is moving the instance to new hardware via the recover action or a stop/start. An instance status check (StatusCheckFailed_Instance) monitors the instance itself — exhausted memory, a corrupted filesystem, misconfigured network settings, or a failed kernel. That failure is inside your OS, so it needs a reboot or hands-on repair; new hardware won't help.

How does EC2 auto recovery work and what does it preserve?

You attach a recover action to a CloudWatch alarm on StatusCheckFailed_System — it cannot be attached to other metrics. When the alarm fires, CloudWatch migrates the instance to healthy underlying hardware. The recovered instance keeps its instance ID, private IP addresses, Elastic IP addresses, attached EBS volumes and instance metadata. Anything in memory and any data on instance store volumes is lost, and the OS uptime resets, because recovery restarts the instance on the new host. Recovery is not supported for instances in an Auto Scaling group or on Dedicated Hosts, and it cannot fix OS-level problems.

Why is my EventBridge rule not triggering?

Use the rule's metrics to find which half is broken. If MatchedEvents or TriggeredRules stays at zero, the problem is upstream: the event pattern doesn't match the real event (matching is exact and case-sensitive, so test it against a sample event), the rule is disabled, the event arrives on a different bus, or it occurs in a different Region — EventBridge is regional. If the rule matches but FailedInvocations rises, the target lacks permission: Lambda and SNS targets need a resource-based policy allowing EventBridge, while Systems Manager Automation and cross-account or cross-Region bus targets need an IAM role on the target.

Sign up free to mark lessons complete, bookmark topics and track your exam readiness.

Spotted a mistake in this lesson?