1

Need to terminate the instance that is in standby. How can it be done.

I terminated instance using instance_id, instance got terminated but still showing in console as standby node.

How can I terminate node and and move from standby without receiving any requests.

Sumit Murari
  • 1,597
  • 3
  • 28
  • 43

3 Answers3

2

I had the same issue. After terminating the instance, go to auto scaling group -> select that instance -> Actions -> Set to InService.

It gets removed automatically from the list.

Aakash Mangal
  • 125
  • 3
  • 12
  • had to increase the maximum capacity and then reduce the desired capacity, as the unwanted instance is removed, but a new one created to replace it – higuita Mar 11 '23 at 18:30
0

It is not prefer way to terminate instance while it is on stand by mode in Auto Scaling group. If you manually terminate instance which is in stand by mode, it will still show in auto scaling group. If you want to terminate it, You must place instance in service. After that you can de-attach instance and terminate or stop it as required.

KK Patel
  • 153
  • 5
  • 14
0

You can also remove the instance while it is in standby using the autoscaling CLI/API action 'terminate-instance-in-auto-scaling-group' as per the options below.

 $ aws autoscaling terminate-instance-in-auto-scaling-group
--instance-id <value>
--should-decrement-desired-capacity | --no-should-decrement-desired-capacity
[--cli-input-json <value>]
[--generate-cli-skeleton <value>]

Docs: https://docs.aws.amazon.com/cli/latest/reference/autoscaling/terminate-instance-in-auto-scaling-group.html

denverj
  • 128
  • 1
  • 6