How Do You Delete a Network Interface in AWS When You Get an Error about Not Having Permission?

Problem Scenario
In AWS you try to delete a Security Group.  You cannot do it because you get an error that "These security groups are associated with one or more network interfaces.  Delete the network interfaces, or associate them with different security groups."  You click the link "View your network interfaces."  But you are unable to delete the network interfaces.  You try to "Detach" them (with the "Force detachment" option), but you get "Error deleting network interface. You do not have permission to access the specified resource."

What do you do to delete a Network Interface in AWS when you get this error?

Solution
Look at the "Description" column of "Network Interfaces" (which is under "Network and Security").  Find the relevant item, device or object (e.g., if you see ELB go to Load Balancing -> Load Balancers).  Delete this object if you are procedurally able to do so.  Then go back and delete the Network Interface.  Now you can delete the Security Group.

Advertisement
You may want a book on AWS networking such as one of the following:

1119439833AWS Certified Advanced Networking Official Study Guide: Specialty Exam
B07JCS19YJBuilding a Modular and Scalable Virtual Network Architecture with Amazon VPC: VPC Quick Start
B07S8ZTHPXAWS Certified Advanced Networking - Specialty Exam Guide: Build your knowledge and technical expertise as an AWS-certified networking specialist
B0742HR1Y4AWS Networking Cookbook: Powerful recipes to overcome the pain points of optimizing your Virtual Private Cloud (VPC)

Join the Conversation

1 Comment

Leave a comment

Your email address will not be published. Required fields are marked *