Home Cloud / DevOps / IT Support How To Protect EC2 Instance From Accidental Termination/Delete

How To Protect EC2 Instance From Accidental Termination/Delete

by Zaki Ghassan
0 comments
Cloud Consulting Services hex64


In this blog, we will show you how to secure EC2 instances against accidental termination by root user/Superuser. Please follow the below configuration to secure the EC2 instance.

If you are launching a new EC2 instance-

  1. Login on AWS cloud console.
  2. Go to Services > Compute > EC2 > EC2 Dashboard
  3. On the EC2 Dashboard, click on Instances.
  4. Click on Launch the Instances to create a new EC2.

5. Start configuration of EC2, once you reach step-3 “configure instance”, check the option “Protect against accidental termination” and finish the EC2 configuration.

If you have a running EC2-

  1. Login on AWS cloud console.
  2. Go to Services > Compute > EC2 > EC2 Dashboard
  3. On the EC2 Dashboard, click on Instances.
  4. Select the EC2 instance that you want to protect against accidental termination and click on Action.

5. Once you click on Action, a drop-down menu list will appear, select Instance Setting and then select the option “Change termination protection”.

6. Check Enable option and then click on Save button to save the changes.

Conclusion:

After enabling Termination Protection when any user will try to terminate the EC2, it won’t be deleted and the below error will appear.


You may also like

Welcome to Technova Pulse – Your Gateway to Technology & Innovation

At Technova Pulse, we dive into the fast-moving world of technology and innovation.

Subscribe

Subscribe my Newsletter for new blog posts, tips & new photos. Let's stay updated!

© 2010-2025 Mahasun.site. All rights reserved.