NEW Featured eBook: AWS Cloud Cost Allocation: The Complete Guide - Download Now

How to Delete Terminated EC2 Instances in AWS

To delete terminated EC2 Instances, locate the instance you want to delete in the EC2 Console under the Instances page. Click on the instance and select the Terminate option. Once you’ve selected “terminate,” you will receive a pop-up confirmation. Click “Yes” to confirm.

The image represents the “terminate instance” option that you need to choose for EC2 instance termination.

The instance will remain on the AWS console for about an hour before the system deletes it completely. After you terminate an instance, you will also delete all attached Amazon EBS volumes. However, any volumes attached after launching the instance will persist. It is essential to back up the data before terminating the instance.

Terminating vs. Stopping an Instance

You can either terminate or stop an instance from running. Terminating or stopping an instance ensures it does not accrue additional charges. The instance will shut down in both, and the virtual machines will disappear.

The concept of Terminating an EC2 instance is completely different from stopping them. Terminating is when you don’t need an instance and want to delete it completely from your AWS infrastructure which cannot be recovered. However, if you have an AWS snapshot, you can create an AWS AMI that will enable you to restore an instance to the date when you created the snapshot.

Stopping an instance is a general action a cloud administrator applies during maintenance. Sometimes it is required for specific reasons like changing instance type, applying any patches, etc. After stopping, we can start the instance at any time if needed.

When stopping an instance, EBS volume will remain. The attached bootable EBS volume will also remain. The volume will continue persisting in its availability zone and will incur standard charges. It is a good idea to stop any instances that you will not be using for a short period. Unless you plan to start an instance within a short time, you should terminate it to avoid any unnecessary charges.

Can I Restart a Terminated Instance?

Terminated instances take some time to disappear from the AWS console completely. Because terminated instances are not part of the AWS infrastructure, they cannot be restarted. You must create a new one. Additionally, you cannot recover the data associated with the terminated instance.

Protecting EC2 Instances from Termination

Since you cannot restart a terminated instance, protecting your instances from accidental termination is essential. This saves you from losing resources and crucial data.

Here are some handy ways to prevent EC2 Instance termination:

AWS Termination Protection

You can enable AWS termination protection to prevent accidental deletion. The DisableApiTermination attribute is responsible for preventing accidental deletion. However, you cannot protect the termination of Spot Instances. Spot Instances will automatically terminate after you have exceeded the agreed-upon price.

You can enable AWS termination protection to prevent accidental deletion. The DisableApiTermination attribute is responsible for preventing accidental deletion. However, you cannot protect the termination of Spot Instances. Spot Instances will automatically terminate after you have exceeded the agreed-upon price.

You can enable termination protection under the Instance Settings on the Actions page for running and stopping instances.

Select your EC2 Instance > Action > Instance Settings > Change termination protection > Check or uncheck the box as needed.

The image represents the “Change termination protection” dialog box.

You can disable this protection at any time through the Instance Settings.

Identity and Access Management (IAM)

Access management is crucial when it comes to using AWS resources securely. AWS Identity and Access Management (IAM) is a service that helps manage user identities and access to AWS resources. It enables you to centrally manage permissions for controlling the resources users can access. IAM is used for authentication and authorization purposes, allowing you to create or manage resources at AWS and manage IAM users, groups, and roles. For enhanced security, IAM also offers multi-factor authentication (MFA). The best part is that it is a free service, with no additional charges.

Manage EC2 Instances with nOps

 

It’s easy for cloud costs to get out of control without the right safeguards and tools. nOps Cloud Optimization Essentials makes it easy to tackle time-consuming cost optimization tasks, such as:

  • One-click stop EC2 instances: Halt idle instances effortlessly, for immediate savings while retaining full operational flexibility with the option to reactivate instances as needed
  • Automated resource scheduling: Leveraging ML, nOps Essentials learns your usage patterns to recommend optimal scheduling, automatically implementing approved suggestions via certified AWS EventBridge integration
  • Automated Rightsizing: Simply plug in your CloudWatch or Datadog monitoring solution for the most accurate, reliable and data-backed rightsizing recommendations available — simply approve to apply.
  • One-click EBS volume migration: nOps automatically and intelligently updates EBS configurations from gp2 to gp3, offering up to 20% in cost savings and facilitating bulk storage instance updates

Our mission is to make cloud cost optimization easy and safe, so you can focus on what matters most: building and innovating. 

nOps manages over $1.5 billion in cloud spend and was recently named #1 in G2’s Cloud Cost Management category. To find out how to start saving in just 10 minutes, book a demo call today.