-
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
segfault after node rebooted #914
Comments
Hmm, interesting. The line referenced is this one: https://github.com/aws/amazon-vpc-cni-k8s/blob/release-1.5.5/pkg/awsutils/awsutils.go#L820 It looks like we are assuming that a) All of those assumptions should be asserted in the code. I'll push up a patch. Thanks for the bug report @kgtw! :) |
Practice good code safety in the `EC2MetadataCache.DescribeENI()` method by not assuming that either the `DescribeNetworkInterfacesOutput` struct's `NetworkInterfaces` field is not empty and that the first `NetworkInterface` struct that collection has a non-nil `Attachment` field. Fixes Issue aws#914
Practice good code safety in the `EC2MetadataCache.getENIAttachmentID()` method by not assuming that either the `DescribeNetworkInterfacesOutput` struct's `NetworkInterfaces` field is not empty and that the first `NetworkInterface` struct that collection has a non-nil `Attachment` field. Fixes Issue aws#914 however note that with aws#909, the source code changed dramatically and this patch will need to be written differently for v1.5.x branches.
Practice good code safety in the `EC2MetadataCache.getENIAttachmentID()` method by not assuming that either the `DescribeNetworkInterfacesOutput` struct's `NetworkInterfaces` field is not empty and that the first `NetworkInterface` struct that collection has a non-nil `Attachment` field. Fixes Issue #914 however note that with #909, the source code changed dramatically and this patch will need to be written differently for v1.5.x branches.
Fix merged |
Note that the fix was merged to master (1.6 release series) and would need to be backported to the 1.5 release branch... |
Thanks for the quick response @jaypipes ! |
Practice good code safety in the `EC2MetadataCache.getENIAttachmentID()` method by not assuming that either the `DescribeNetworkInterfacesOutput` struct's `NetworkInterfaces` field is not empty and that the first `NetworkInterface` struct that collection has a non-nil `Attachment` field. Fixes Issue aws#914 however note that with aws#909, the source code changed dramatically and this patch will need to be written differently for v1.5.x branches.
Practice good code safety in the `EC2MetadataCache.getENIAttachmentID()` method by not assuming that either the `DescribeNetworkInterfacesOutput` struct's `NetworkInterfaces` field is not empty and that the first `NetworkInterface` struct that collection has a non-nil `Attachment` field. Fixes Issue #914 however note that with #909, the source code changed dramatically and this patch will need to be written differently for v1.5.x branches.
@jaypipes any chance of getting this back-ported to the 1.5 branch ? |
@kgtw apologies, I was on PTO. Will try to backport this into the 1.5 branch, sure thing! |
We use kured to reboot nodes for security patches, after a node got rebooted the cni pod consistently failed to start due to a segfault.
Kubernetes: v1.16.7
CNI Plugin: 0.7.5-1
AWS CNI: 1.5.5
The text was updated successfully, but these errors were encountered: