Does Elastic Beanstalk automatically create a new instance and fail-over if an instance fails?

0

I have several EB clusters, with capacity scaling based on CPU usage. For each cluster, the idle state is just 1 instance, and it will scale-up from there based on load.

But what about if an instance fails? Say that 1 instance above has some hardware or network fault, and the load balancer can't communicate with it? Will EB automatically spin-up a new instance and direct traffic to it?

And secondly, when creating a new instance, either due to load or in this fault scenario, does EB always choose a different Availability Zone, in order to maximize resilience? Or, do I have to specifically set the "Availability Zones" setting to something other than "Any" or "Any 1"?

Btw, I know that for the ultimate fault-tolerance, we should always have N+1 instances spread across zones... but I'm specifically asking about the scenario above when the minimum instances is 1.

Thank you.

已提問 5 個月前檢視次數 214 次
1 個回答
0

Hello.

EC2 in Elastic Beanstalk is managed by AutoScaling.
Due to the utoScaling specification, if a failure occurs in an Availability Zone or EC2, a new instance will be launched.
This behavior is the same even if there is only one instance.
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-recover.html#limitations-simplified-recovery

Simplified automatic recovery is not initiated for instances in an Auto Scaling group. If your instance is part of an Auto Scaling group with health checks enabled, then the instance is replaced when it becomes impaired.

https://docs.aws.amazon.com/autoscaling/ec2/userguide/auto-scaling-benefits.html

Better fault tolerance. Amazon EC2 Auto Scaling can detect when an instance is unhealthy, terminate it, and launch an instance to replace it. You can also configure Amazon EC2 Auto Scaling to use multiple Availability Zones. If one Availability Zone becomes unavailable, Amazon EC2 Auto Scaling can launch instances in another one to compensate.

profile picture
專家
已回答 5 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南