Difference between revisions of "AWS EC2 Instance lifecycle"

From wikieduonline
Jump to navigation Jump to search
 
(15 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
* https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html
 
* https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-instance-lifecycle.html
  
* <code>pending</code>
+
 
* <code>running</code>
+
* <code>[[pending]]</code>
* <code>stopping</code>
+
* <code>[[running]]</code>
* <code>stopped</code>
+
* <code>[[stopping]]</code>
* <code>shutting-down</code>
+
* <code>[[stopped]]</code>
* <code>terminated</code>
+
* <code>[[shutting-down]]</code>
 +
* <code>[[terminated]]</code>
 +
 
 +
== Terminated ==
 +
In AWS, when an instance is terminated, it is no longer running and cannot be restarted. The amount of time that a terminated instance remains visible in the [[AWS Management Console]] depends on the retention period set for the [[Auto Scaling group]] or the [[EC2 instance]]. The default [[retention period]] is one hour, but it can be configured to be up to seven days. Once the retention period has expired, the terminated instance is permanently deleted and is no longer visible in the AWS Management Console. Ref: [[ChatGPT]]
 +
 
 +
Two days, according to [[ChatGPT]]
 +
* <code>[[aws autoscaling update-auto-scaling-group]] --auto-scaling-group-name my-asg --termination-policies OldestInstance</code>
 +
* [[Launch configuration]]
 +
 
 +
* <code>[[aws autoscaling describe-termination-policy-types]]</code>
 +
 
 +
== Related ==
 +
* [[Lifecycle]]: [[spot]]
 +
* <code>[[An instance was taken out of service in response to a EC2 health check indicating it has been terminated or stopped]]</code>
 +
* [[AWS CloudTrail]]
 +
* <code>[[aws cloudtrail lookup-events]] --lookup-attributes AttributeKey=EventName,AttributeValue=TerminateInstances</code>
  
 
== See also ==
 
== See also ==

Latest revision as of 10:41, 16 January 2024


Terminated[edit]

In AWS, when an instance is terminated, it is no longer running and cannot be restarted. The amount of time that a terminated instance remains visible in the AWS Management Console depends on the retention period set for the Auto Scaling group or the EC2 instance. The default retention period is one hour, but it can be configured to be up to seven days. Once the retention period has expired, the terminated instance is permanently deleted and is no longer visible in the AWS Management Console. Ref: ChatGPT

Two days, according to ChatGPT

Related[edit]

See also[edit]

Advertising: