ASG - Terminate before Launch

0

I have a ASG with a single instance. I use a ASG for the health checks to relaunch if there is an issue. Ideally I need the instance to be terminated before the replacement is launched.

Is there a way to achieve this?

Paddy
질문됨 일 년 전285회 조회
2개 답변
1

It depends what you mean with launched. If you mean being brought into service you could probably use Lifecycle Hooks to keep the instance in Pending:wait state, checking the status of the terminating instance, before bringing the instance being launched into service.

https://docs.aws.amazon.com/autoscaling/ec2/userguide/lifecycle-hooks-overview.html

profile picture
전문가
답변함 일 년 전
  • To add on to this: By default, the termination for the healthcheck will start right before the launch, but the ASG won't wait for the termination to finish before the launch starts

0

Would advise you look into using the right Instance Maintenance Policy for your use case and then depending on timing, consider the use of Lifecyle Hooks. https://docs.aws.amazon.com/autoscaling/ec2/userguide/instance-maintenance-policy-overview-and-considerations.html

AWS
ASGDude
답변함 3달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠