You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
When an EC2 has a shared and a in account security group with identical names deleting one from "Change Security Groups" will delete both #10436
When 2 (I assume or more) Security groups with an identical name are assigned to an ENIs security group list, deleting one, will delete all of the same name.
Regression Issue
Select this option if this issue appears to be a regression.
Expected Behavior
I expected to only delete security group ID sg-075407198e27a64bc, but it also deleted sg-0811e4163b09b96c7
Current Behavior
It deletes all security groups with the identical name, which is incorrect, it should delete only the selected item.
Reproduction Steps
This is done via the GUI
I believe this was the order this will work in. It requires the same region and 2 different AWS accounts.
Create and share a vpc and at least 1 subnet in account 1
Share this with account 2 via RAM
Create a SG in account 1 name it "My SG"
Create a SG in account 2 name it "My SG" (must be the same name)
Share the new SG from account 2 to account 1 with RAM
Back in account 1 add BOTH newly created SG to any eni and save it.
Edit the ENIs security groups again and remove the shared one. You will find that both SG disappear.
It looks like the deletion is being done on Security Group Name, NOT Security group ID
Possible Solution
ensure the Remove button on the GUI removes by ID, not name
Thanks for reaching out @TessituraWayne. To contact the EC2 team regarding this, please use the feedback button in the AWS Console while in EC2. You may also reach out to AWS Premium Support for a dedicated, service-related issue support.
This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.
Activity
TessituraWayne commentedon Jun 26, 2026
Images are shown the wrong way around. the POST DELETE is the first image, the PRE DELETE is the second image
adev-code commentedon Jul 1, 2026
Thanks for reaching out @TessituraWayne. To contact the EC2 team regarding this, please use the feedback button in the AWS Console while in EC2. You may also reach out to AWS Premium Support for a dedicated, service-related issue support.
github-actions commentedon Jul 1, 2026
This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.