I currently have an elastic load balancer with some servers behind it. I want them to scale as traffic moves up and down.

I currently have a scaling policy to add instances whenever CPU util is over 50% for 60 seconds. This sort of works OK.

However, how can I trigger an auto scaling action when there are no healthy instances? So if there's a rush of traffic and the servers just die, they don't report CPU util over 50% and nothing happens to the auto scaling.

How can I set up ELB/auto scaling to jump in as soon as there are no healthy instances? Or is there a better way to achieve this?


2 Answers 2


You are probably looking for Scaling Based on Metrics, which allows you to use metrics collected by Cloudwatch for scaling decisions. The healthy/unhealthy instance counts from ELB are accessible through Cloudwatch.

Auto scaling can use the instance health as determined by ELB but that's probably not exactly what you are after, since an unhealthy instance would be declared dead and replaced, which is not exactly what you want, since if the unhealthy state were caused by load, then you don't want to exacerbate the issue by getting rid of machines that might recover...

...but you may also need to anticipate load more aggressively to prevent machines from getting into this state to begin with. Once an instance fails health checks due to traffic load, I would argue that you may have already acted too late, and your system is going to spend some time in a death spiral. You will also want ELB to use the minimum number of consecutive successful checks (2) to bring the instances back so they rejoin the pool quickly.

  • Thank you, that's very helpful and just what I was looking for. I was looking to have healthy instance based scaling in addition to my CPU util scaling policies - just as a back up rather than main approach. I will look into your ideas, thanks.
    – samiles
    Jul 5, 2016 at 12:54

You can configure your ASG to use ELB health checks instead of the standard EC2 health checks. This will accomplish what you are looking for, I believe.

  • Hi, thank you, yeah that was what I was asking but does anyone know how? I can't find it within the interface.
    – samiles
    Jul 5, 2016 at 8:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.