Restart Elastic Beanstalk App Server when Health is Severe

0

Hello, I am running a spring boot application on Elastic Beanstalk using Tomcat 8.5 with Corretto 11 running on 64bit Amazon Linux 2/4.2.12. Every couple of days I am getting the error "Following services are not running: tomcat.", with Severe Health status and a down server. I am not seeing useful information in the catalina.2022-xx-xx.log files. Restarting the app server fixes the issue. Instance type is t2.micro. I would appreciate help in understanding

  1. how to understand what is wrong with my setup.

  2. recover and restart the server automatically so I won't have to manually do it every time until a fix has been found.

Thank you.

  • Hi, Have you checked the monitoring tab in your ec2 t2.micro instance? I guess the error can be a lack of CPU/RAM, ...

demandé il y a 2 ans2328 vues
1 réponse
0

The tomcat / catalina.log logs should reveal the cause, you may need to up the logging level or add additionally logging. It is possible it is resource related and some of the tomcat memory parameters need updating eg max heap size but you need to be sure this is the cause.

if you are using a load balancer you could add a load balancer health check and configure automatic termination within the autoscale group (I believe this is not a native config and will require ebextensions)

If not using a load balancer you could add a cloudwatch alarm on the environment health metric and then configure an alarm action to reboot the instance - see here

AWS
EXPERT
Peter_G
répondu il y a 2 ans

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions