Remediation
Review and Pause the ECS Serviceβ
- Review CPU and memory utilization, task counts, metric coverage, and recent deployments in CloudWatch and Amazon ECS. Check requests, queue activity, and scheduled or event-driven jobs over a representative workload cycle.
- Confirm with the service owner whether the workload can be paused. Check downstream dependencies and any standby or disaster recovery role. If the service must stay available, evaluate smaller tasks or fewer replicas under representative load.
- Record the current desired count, Service Auto Scaling settings, and scheduled actions. Confirm how the service will resume. ECS publishes service CPU and memory metrics while tasks are running, so verify an independent demand signal or plan to restore capacity manually. Amazon ECS CloudWatch metrics Β· Amazon ECS Service Auto Scaling
Using the AWS CLIβ
-
Coordinate the pause with the service owner. Adjust any minimum capacity or scheduled actions that would restart the service during the pause. For services managed through infrastructure as code, apply the change through the existing deployment process.
-
Set the desired task count to zero.
aws ecs update-service \
--region {{region}} \
--cluster {{cluster-name}} \
--service {{service-name}} \
--desired-count 0
Verify the Changeβ
- Confirm that the running and pending counts reach zero. Verify that dependent workloads remain healthy and monitor requests, queues, and scheduled jobs for returning demand.
- If demand returns or a dependency is affected, restore the recorded scaling settings and run the update command with the previous desired count. Verify that the tasks start and pass their health checks.
- If the service owner confirms permanent retirement, resolve its dependencies before deleting the service.
Estimate Fargate savings from the avoided billable task-hours and applicable rates. For ECS on EC2, estimate compute savings from the backing capacity that can be removed.