【问题标题】:EKS Ingress (for ALB) gets no endpoint when deploying more than 3 IngressesEKS Ingress(用于 ALB)在部署超过 3 个 Ingress 时没有端点
【发布时间】:2019-11-21 15:05:37
【问题描述】:

我在入口控制器中使用 AWS ALB 部署超过 3 个应用程序时偶然发现了这个奇怪的限制。

最多 3 个应用程序,没有问题,当配置第 4 个入口时,它没有得到端点:

但是 LoadBalancer (ALB) 是按预期配置的:

我不知道有 3 个 Ingress 的限制吗?还是我在配置中的某个地方设置了这个限制?

“失败”入口的kubectl describe ingress 的输出(注意缺少的地址 - 其他 3 个入口都有地址):

Name:             some-ingress
Namespace:        default
Address:          
Default backend:  default-http-backend:80 (<none>)
Rules:
  Host  Path  Backends
  ----  ----  --------
  *     
        /    ssl-redirect-default:use-annotation (<none>)
        /*   ssl-redirect:use-annotation (<none>)
        /*   some-service:80 (192.168.92.252:8080)
Annotations:
  alb.ingress.kubernetes.io/actions.ssl-redirect:          {"Type": "redirect", "RedirectConfig": { "Protocol": "HTTPS", "Port": "443", "StatusCode": "HTTP_301"}}
  alb.ingress.kubernetes.io/actions.ssl-redirect-default:  {"Type": "redirect", "RedirectConfig": { "Protocol": "HTTPS", "Path": "/someapp/#{path}", "Port": "443", "StatusCode": "HTTP_301"}}
  alb.ingress.kubernetes.io/certificate-arn:               arn:aws:acm:eu-central-1:...
  alb.ingress.kubernetes.io/listen-ports:                  [{"HTTP": 80}, {"HTTPS":443}]
  alb.ingress.kubernetes.io/scheme:                        internet-facing
  kubernetes.io/ingress.class:                             alb
Events:
  Type    Reason  Age                From                    Message
  ----    ------  ----               ----                    -------
  Normal  CREATE  16m                alb-ingress-controller  LoadBalancer some-alb created, ARN: some-alb-arn:loadbalancer/app/some-alb/some-ids
  Normal  CREATE  16m (x2 over 16m)  alb-ingress-controller  rule 1 created with conditions [{    Field: "path-pattern",    Values: ["/"]  }]
  Normal  CREATE  16m (x2 over 16m)  alb-ingress-controller  rule 2 created with conditions [{    Field: "path-pattern",    Values: ["/*"]  }]
  Normal  CREATE  16m                alb-ingress-controller  rule 3 created with conditions [{    Field: "path-pattern",    Values: ["/*"]  }]

【问题讨论】:

  • 能否提供以下输出:kubectl describe ingress -n
  • @Arul 我将输出添加到问题中
  • @simon 我也遇到了类似的问题,你找到问题的根本原因/解决方案了吗?
  • @shivMagus 我添加了答案。

标签: kubernetes-ingress amazon-eks aws-elb


【解决方案1】:

发现问题了,apparently there is a Security Group Limit of 5 per Cluster Node ENI (Elastic Network Interface), and every new application instance with ALB Ingress adds a SG。这是一个服务配额,可以增加:

相关日志是通过以下方式找到的:

kubectl logs -n kube-system   deployment.apps/alb-ingress-controller

我已经有 2 个用于 ENI 的 SG,所以在部署了 3 个应用程序实例后,就达到了限制。我刚刚将限制增加到 15(每个服务配额请求),瞧,我可以使用 ALB 入口部署更多应用程序实例。

对我来说,这解决了这个问题,但这个解决方案不会无限扩展,因为每个应用程序实例都会向 ENI 添加一个新的安全组,所以 13 个应用程序实例对我来说是新的限制。

【讨论】:

  • 感谢您的回复,这是有道理的..我曾通过 nginx ingress 解决过 :) ..
  • ALB Ingress 处理安全组的方式已经改变,因此这应该不再是问题 - 请查看该问题并尝试发布 1.1.3 或更高版本(changelog 有详细信息)。 AWS ALB 入口控制器也已重命名为 AWS 负载均衡器控制器(提及以帮助人们找到它)。
  • 我发现通过 AWS Support 提高限制需要几天时间,因此最好在控制器中进行修复。
猜你喜欢
  • 2019-06-28
  • 2020-07-03
  • 1970-01-01
  • 1970-01-01
  • 2023-03-05
  • 2021-06-13
  • 1970-01-01
  • 2020-01-25
  • 1970-01-01
相关资源
最近更新 更多