instance is unhealthy yet doesn't get replaced

0

I have a load balanced + auto scaled .NET Windows application configured with 2 hosts minimum. But when 1 of the hosts is "unhealthy", it doesn't get replaced automatically. I have to kill it and then it will be replaced.

The load balancer also knows it is unhealthy. So why the disconnect with Elastic Beanstalk?

Any ideas what could be configured wrong here?

And FWIW, I'm pretty sure this used to work.

gefragt vor 5 Jahren846 Aufrufe
2 Antworten
0
Akzeptierte Antwort

Hello,

So I get that when the ELB healthchecks fails for the instances, the instances are not replaced. By default the ASG healthcheck type is set to EC2 in Beanstalk. So even if the ELB healthcheck fails, the instances wont be replaced.

In order to replace the instances based on ELB healthchecks, we would have to set the HealthCheckType to ELB using the .ebextions config file:

Resources:
  AWSEBAutoScalingGroup:
    Type: AWS::AutoScaling::AutoScalingGroup
    Properties:
      # Example syntax of a property that takes in the actual value
      HealthCheckType: ELB
      HealthCheckGracePeriod: 600

More info:
https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/environmentconfig-autoscaling-healthchecktype.html

AWS
beantwortet vor 5 Jahren
0

Awesome, thank you!

beantwortet vor 5 Jahren

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen