-
Notifications
You must be signed in to change notification settings - Fork 39.9k
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
handle multiple internal IPs from aws cloud provider #44686
Comments
sample proposed fix: https://github.com/jlz27/kubernetes/pull/1/files |
The change you suggest would certainly be reasonable, but AFAIK kubernetes itself doesn't currently have great support for instances with multiple IPs. What is your reason for multiple IPs? As an aside, I do think it would be cool to use this functionality of AWS a bit better - it's come up a few times in relation to elastic IPs for services that do IP-based filtering (but there a proxy seems easier). And it would also be nice to build an ingress method using this. |
The specific issue I ran into was that we configured separate ENIs for our ec2 instances that were not I don't have enough context to comment on the need to support multiple EIP kubelets, but the current bug does not allow kublets to request non I'm happy to clean up my CR with unit tests and put it up for review if you'd like. |
Automatic merge from submit-queue (batch tested with PRs 51301, 50497, 50112, 48184, 50993) AWS: handle multiple IPs when using more than 1 network interface per ec2 instance **What this PR does / why we need it**: Adds support for kubelets running with the AWS cloud provider on ec2 instances with multiple network interfaces. If the active interface is not eth0, the AWS cloud provider currently reports the wrong node IP. **Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*: fixes #44686 **Special notes for your reviewer**: There is also some work necessary for handling multiple DNS names and such but I didn't fix them in this PR. **Release note**: ```release-note Fixed bug in AWS provider to handle multiple IPs when using more than 1 network interface per ec2 instance. ```
What keywords did you search in Kubernetes issues before filing this one? (If you have found any duplicates, you should instead reply there.):
Kubernetes version
1.5.2
Feature Request
Hi, I am trying configure a cluster on AWS where my kubelets are running on EC2 instances with multiple interfaces.
I want to force the kubelets to report a specific IP so I am using the
node-ip
flag when starting my kubelets. For example, on a node with 2 interfaceseth0: IP0
andeth1: IP1
, I set my kubeletnode-ip: IP1
. I would expect my kubelet to come up but instead, I get:running
aws ec2 describe-instances ...
shows me that thePrivateIP
field on the instance object is actuallyIP0
but the instance has multiple active network interfaces andIP1
is present in one of the interfaces.Digging through the code, it looks like the
node status
reporting already handle multiple ip addresses correctly so this seems enhancement in this file: https://github.com/kubernetes/kubernetes/blob/master/pkg/cloudprovider/providers/aws/aws.go#L963There is already a TODO for supporting multiple IP addresses, would it be a reasonable change to iterate through the
network interfaces
returned on theinstance
and report additional active interfaces?The text was updated successfully, but these errors were encountered: