kubernetes-sigs / aws-load-balancer-controller

A Kubernetes controller for Elastic Load Balancers
https://kubernetes-sigs.github.io/aws-load-balancer-controller/
Apache License 2.0
3.9k stars 1.45k forks source link

ALB is only registered to 2 subnets after upgrading to v2.7.2 #3698

Open jmtsi opened 4 months ago

jmtsi commented 4 months ago

Describe the bug After upgrading the ALBC to v2.7.2, only 2 of our 3 correctly-annotated subnets are registered to ALB, which causes some of the ip-targets to have status Unused with an error: Target is in an Availability Zone that is not enabled for the load balancer

Steps to reproduce Create an ingress without specifying annotation alb.ingress.kubernetes.io/subnets. A new ALB gets created, but only having 2 of the 3 subnets.

Expected outcome The load balancer gets created with all 3 subnets that have the label kubernetes.io/role/internal-elb=1

Environment Kubernetes: 1.29.1 ALBC: v2.7.2 EKS platform version: eks.6

Additional Context: I tried to find anything subnet-discovery related from ALBC debug logs, but found nothing.

As a workaround, I added the alb.ingress.kubernetes.io/subnets annotation with a list of all 3 subnets, which fixed the issue for now.

Full list of annotations used: alb.ingress.kubernetes.io/backend-protocol: HTTP
alb.ingress.kubernetes.io/healthcheck-path: /ping
alb.ingress.kubernetes.io/ip-address-type: dualstack
alb.ingress.kubernetes.io/listen-ports: [{"HTTP": 80}]
alb.ingress.kubernetes.io/load-balancer-attributes: routing.http2.enabled=false alb.ingress.kubernetes.io/scheme: internal
alb.ingress.kubernetes.io/target-group-attributes: load_balancing.algorithm.type=round_robin
alb.ingress.kubernetes.io/target-type: ip
kubernetes.io/ingress.class: alb

aravindsagar commented 4 months ago

Hi! Thanks for reporting the issue. Can you please let us know which version were you using prior to 2.7.2? Controller logs would also be helpful. Thanks!

k8s-triage-robot commented 1 month ago

The Kubernetes project currently lacks enough contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle stale

k8s-triage-robot commented 2 weeks ago

The Kubernetes project currently lacks enough active contributors to adequately respond to all issues.

This bot triages un-triaged issues according to the following rules:

You can:

Please send feedback to sig-contributor-experience at kubernetes/community.

/lifecycle rotten