A user has enabled instance protection for his Auto Scaling group that has spot instances. If Auto Scaling wants to terminate an instance in this Auto Scaling group due to a CloudWatch trigger unre-lated to bid price, what will happen?
A.
Auto Scaling will notify the user for the next action
B.
Auto Scaling will remove the instance from the Auto Scaling Group
C.
Auto Scaling overwrites the instance termination attribute and terminates the instances
D.
The EC2 instance will not be terminated since instance protection from scale-in is enabled.
Suggested Answer:D🗳️
Auto Scaling protects instances from termination during scale-in events. This means that Auto Scal-ing instance protection will receive the CloudWatch trigger to delete instances, and delete instances in the Auto Scaling group that do not have instance protection enabled. However, instance protec-tion won't protect Spot instance termination triggered due to market price exceeding bid price. Reference: http://docs.aws.amazon.com/autoscaling/latest/userguide/as-instance-termination.html#instance-protection
When instance protection is enabled for an Auto Scaling group, it prevents instances from being terminated due to scale-in actions triggered by Auto Scaling. This means that if Auto Scaling wants to terminate an instance in the group for any reason, including a CloudWatch trigger unrelated to bid price, the instance protection feature will prevent the termination.
there are two level of scale-in protection.
on the scaling group, it means newly added instance will be protected.
on the 'instance management' tab, you can set protection on individual instance, ( not for spot instance ).
Answer: D
ASG doesnt know whether the instances are On-demand/Spot. It will acts equally for all instances. So, the instance protection service remain intact. However, in Spot instance, if the Bid prices is maximum, then only Spot instance will be terminated.
Answer is C.
Instance protection does not protect for the below cases
1.Manual termination through the EC2 console, the terminate-instances command, or the TerminateInstances API.
2.Termination if it fails health checks and must be replaced
3.Spot instances in an Auto Scaling group from interruption
Answer D: As the Termination protection is at the Autoscalling level, not instance level.
https://docs.aws.amazon.com/autoscaling/ec2/userguide/as-instance-termination.html
Instance scale-in protection does not protect Auto Scaling instances from the following:Spot Instance interruptions. A Spot Instance is terminated when capacity is no longer available or the Spot price exceeds your maximum price.
True, you cant enable termination protection for Spot Instances. So the Answer should be C.
" When Amazon EC2 interrupts a Spot Instance, it provides a Spot Instance interruption notice, which gives the instance a two-minute warning before Amazon EC2 interrupts it. You can't enable termination protection for Spot Instances. "
The question does not state that the Auto Scaling Group has ONLY Spot Instances; it could be having a combination of On-Demand and Spot Instances. In this case, the On-Demand Instances can have termination protection enabled.
C is correct ;
You can't enable termination protection for Spot Instances.
2nd paragraph last line
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/how-spot-instances-work.html
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
albert_kuo
10 months, 1 week agoalbert_kuo
6 months, 3 weeks agoapwangzh
2 years, 6 months agoImranR
2 years, 6 months agoJGD
2 years, 6 months agoSriramps
2 years, 6 months agoDem
2 years, 7 months agosen12
2 years, 7 months agojaribu
2 years, 7 months agoaksliveswithaws
2 years, 7 months agokarmaah
2 years, 7 months ago