- Newest
- Most votes
- Most comments
You can describe the details of the stopped task by using the command shown below. This will provide insights into the stopCode
and stoppedReason
values which can be used to determine the reason for the failure.
aws ecs describe-tasks --tasks <task-id> --cluster <cluster-name>
In the same output, you can review the containers section and retrieve the exitCode
of the container process. This will be very useful in determining the reason for the container process termination.
If the container was terminated due to an OOM issue, the exitCode
would be 137.
You can also setup Cloud Watch Container Insights metrics for gathering task level resource metrics to identify any issues with system level resources.
I hope this is helpful to you. Please let me know if you need more clarification on this information.
After looking at the fargate task metrics, I found the 100% CPU usage. Added one more CPU made everything running smoothly.
Relevant content
- Accepted Answerasked a year ago
- AWS OFFICIALUpdated 5 months ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated 3 years ago
Could you provide the task error code? Should be helpful for an initial indication of what went wrong.