-
Notifications
You must be signed in to change notification settings - Fork 742
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dangling ENIs without any association with Instances #1447
Comments
Hi @Buffer0x7cd Do you have short lived instances/cluster? Also do you have any node termination policy? There is one known issue (#1223), After ENI is detached, it will take few seconds for the ENI to delete, if in the mean time node is terminated then the ENI will be dangling in the account. |
HI @jayanthvn It doesn’t seems like this is the issue. amazon-vpc-cni-k8s/pkg/awsutils/awsutils.go Line 836 in 9db2ae6
From my understanding , In the case here. ENI will be First detached and deleted. Assuming the ENI was first Attached It should have the node.k8s.amazonaws.com/instance_id tag, Even after being detached ( As there is no steps to delete tags in the freeENI method).
In our observed case we can see that the dangling ENIs have no |
Yeah makes sense, I quickly ran a test and detached an ENI and I still see the instance_id tag even though the ENI is detached. Can you please open a support case? |
Hi @Buffer0x7cd For the ENI, do you see the "node.k8s.amazonaws.com/createdAt" tag present? |
@jayanthvn yes i can see the node.k8s.amazonaws.com/createdAt at tag present |
Thanks for checking @Buffer0x7cd. So looks like createENI is fine but if attachENI failed we would have deleted the ENI - amazon-vpc-cni-k8s/pkg/awsutils/awsutils.go Lines 612 to 614 in 9db2ae6
|
We've noticed this while working on https://github.com/weaveworks/eksctl/ too. We recently managed to reproduce this issue: eksctl-io/eksctl#4214 (comment) |
We're seeing a similar/related issue but have cases where none of the active pods have ENIs that are attached to instances (the node has 2 ENIs with 10 and 1 private IP addresses respectively, and there are 13 pods on the node none of which use those ENIs). Not sure if this is actually the same issue but we've raised a support ticket (
And further investigation led us to this issue, but it's unclear whether the issues are related. |
Same issue running |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days |
Not stale |
@aclevername - in the issue you mentioned we do see the @bryantbiggs or @GaruGaru - Can one of you please share IPAMD logs? You can email the log bundle to - |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days |
Not stale |
Tagging teammate @vidhyadharm about this "dangling ENI" issue, suggested by @bryantbiggs as root cause for our vpc deletion issue in eks blueprints and the corresponding vpc deletion issue in aws vpc module. |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days |
/not stale |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days |
Issue closed due to inactivity. |
Is there any fix for this issue? Coming from terraform-aws-modules/terraform-aws-vpc#283 that cannot delete VPC due to DependencyViolation |
In my case, there were nginx and eks related security groups left behind after EKS deletion. Once I removed those manually via AWS console, the VPC was destroyed within a couple of seconds. |
This still appears to be an issue. It seems that the only workaround is to manually delete the VPC. |
This is still an issue. |
What happened:
During one of incidents , where pods are failing due to IP address exhaustion, We noticed that there a lots of ENIs that are allocated , But are not attached to any Instances. Our first assumption was these might be the ENIs that are created to maintain warm pool on the nodes, But After checking them we discovered that there are no tags
node.k8s.amazonaws.com/instance_id
tags available on those ENIs, Which doesn’t seems like expected behaviour.amazon-vpc-cni-k8s/pkg/awsutils/awsutils.go
Line 606 in 9db2ae6
As far i can see, Allocation and attachment of ENIs are so there shouldn’t be the case where ENIs are allocated but are not attached and have missing tags, Except here (
amazon-vpc-cni-k8s/pkg/awsutils/awsutils.go
Line 616 in 9db2ae6
ENI attach and delete both failed). To verify this i checked the prometheus metrics for
AttachNetworkInterface
api for any errors , but there are no significant increases here that explains this being the cause of increase in Allocated ENIs.The text was updated successfully, but these errors were encountered: