- Mais recentes
- Mais votos
- Mais comentários
Hello.
If you check the container logs, you might be able to find out why it doesn't start properly.
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/using_awslogs.html
You can also check the reason for the stopped task by following the steps in the document below.
https://docs.aws.amazon.com/AmazonECS/latest/userguide/stopped-task-errors.html
Hello, Firstly need to verify logs and events inside services.inside services event we can find each event when anything happens. Also verify cloudwatch logs if any thing bad happening regarding application.
Also please verify target group configuration regarding health check monitoring settings.
The application is a Java Spring application. The cloudwatch logs show the Spring server starting with no errors, and then there is a shutdown message. There is no console log message that indicates an error or why the server is shutdown. This is likely because the process was terminated by an external interrupt.
Some other information, if the ECS service continues for some 5-10 minutes, after 5 attempts at restarting the failed container only for the restarted container to be marked UNHEALTHY and thereby terminated, the container does finally do a restart and is reported as HEALTHY.
Satish's answer says to verify the target group configuration for health check monitoring settings. I am not sure exactly what this refers to or how to do this. In the manifest.yml file used for deployment of the container into ECS, the settings are
------------------------------------------------- manifest.yml for service cst438service -------------------------------------------------- name: cst438service
type: Load Balanced Web Service
http:
path: '/'
healthcheck: '/check'
interval: 300
image:
build: cst438container/Dockerfile
port: 80
cpu: 256 # Number of CPU units for the task.
memory: 512 # Amount of memory in MiB used by the task.
count: 2 # Number of tasks that should be running in your service.
exec: true # Enable running commands in your container.
David
Conteúdo relevante
- AWS OFICIALAtualizada há 2 anos
- AWS OFICIALAtualizada há 2 anos
- AWS OFICIALAtualizada há um ano