0
votes

I am using aws ELB to report the status of my instances to an autoscaling group so a non-functional instance would be terminated and replaced by a new one. The ELB is configured to ping TCP:3000 every 60 seconds and wait for a timeout of 10 seconds to consider it a health check failure. the unhealthy threshold is 5 consecutive checks. However the ELB always reports my instances as healthy and inservice all the time even though I periodically manually come across an instance that is timing out and I have to terminate it manually and launch a new one despite the ELB reporting it as inservice all the time

Why does this happen ?

1
Decrease the unhealthy threshold to 2 and try againNithin K Anil
I agree, reduce the threshold. Also try using some other monitoring like a simple curl command in a loop polling every ten seconds to see what the outage events are like. Get the "shape" of the problemVorsprung

1 Answers

0
votes

After investigating a little bit I found that I am trying to assess the health of the app through an api callto a web app running on the instance and wait for the response to timeout to declare the instance faulty. I needed to use http as the protocol to call port 3000 with a custom path through the load balancer instead of tcp.

Note: The api needs to return a status code of 200 for the load balancer to consider it healthy. It now works perfectly