简体   繁体   English

如何修复 DigitalOcean Kube.netes 负载均衡器抛出错误 - SyncLoadBalancerFailed

[英]How to fix DigitalOcean Kubernetes load balancer throwing errors - SyncLoadBalancerFailed

I am having trouble with kube.netes cluster and setting up a load balancer with Digital Ocean.我在使用 kube.netes 集群和使用 Digital Ocean 设置负载均衡器时遇到问题。 The config has worked before, but I'm not sure if something is an outdated version or needs some other change to make this work.配置以前工作过,但我不确定是否有过时的版本或需要一些其他更改才能使其工作。 Is there a way to ensure the SyncLoadBalancer succeeds?有没有办法确保 SyncLoadBalancer 成功? I have waited for more than an hour and the load balancer has long been listed as online in the DigitalOcean dashboard.等了一个多小时,负载均衡器在DigitalOcean dashboard中早就显示在线了。

Name:                     my-cluster
Namespace:                default
Labels:                   app.kubernetes.io/instance=prod
                          app.kubernetes.io/managed-by=Helm
                          app.kubernetes.io/name=my-company
                          app.kubernetes.io/part-of=my-company
                          app.kubernetes.io/version=1.1.67
                          helm.sh/chart=my-company-0.1.51
Annotations:              kubernetes.digitalocean.com/load-balancer-id: e7bbf8b7-29e0-407c-adce-XXXXXXXXX
                          meta.helm.sh/release-name: prod
                          meta.helm.sh/release-namespace: default
                          service.beta.kubernetes.io/do-loadbalancer-certificate-id: 8be22723-b242-4bea-9963-XXXXXXXX
                          service.beta.kubernetes.io/do-loadbalancer-disable-lets-encrypt-dns-records: false
                          service.beta.kubernetes.io/do-loadbalancer-name: prod-load-balancer
                          service.beta.kubernetes.io/do-loadbalancer-protocol: https
                          service.beta.kubernetes.io/do-loadbalancer-size-unit: 1
Selector:                 app.kubernetes.io/instance=prod,app.kubernetes.io/name=my-company,app.kubernetes.io/part-of=my-company
Type:                     LoadBalancer
IP Family Policy:         SingleStack
IP Families:              IPv4
IP:                       10.245.16.78
IPs:                      10.245.16.78
LoadBalancer Ingress:     24.199.70.237
Port:                     https  443/TCP
TargetPort:               http/TCP
NodePort:                 https  32325/TCP
Endpoints:                10.244.0.163:80
Session Affinity:         None
External Traffic Policy:  Cluster
Events:
  Type     Reason                  Age                 From                Message
  ----     ------                  ----                ----                -------
  Warning  SyncLoadBalancerFailed  18m                 service-controller  Error syncing load balancer: failed to ensure load balancer: load-balancer is not yet active (current status: new)
  Warning  SyncLoadBalancerFailed  18m                 service-controller  Error syncing load balancer: failed to ensure load balancer: failed to update load-balancer with ID e7bbf8b7-29e0-407c-adce-94a3205b38b5: PUT https://api.digitalocean.com/v2/load_balancers/e7bbf8b7-29e0-407c-adce-94a3205b38b5: 403 (request "b06545a5-c701-46d1-be84-3740196c21c7") Load Balancer can't be updated while it processes previous actions
  Warning  SyncLoadBalancerFailed  18m                 service-controller  Error syncing load balancer: failed to ensure load balancer: failed to update load-balancer with ID e7bbf8b7-29e0-407c-adce-94a3205b38b5: PUT https://api.digitalocean.com/v2/load_balancers/e7bbf8b7-29e0-407c-adce-94a3205b38b5: 403 (request "27b58084-7ff0-46a3-830b-6210a12278ab") Load Balancer can't be updated while it processes previous actions
  Warning  SyncLoadBalancerFailed  17m                 service-controller  Error syncing load balancer: failed to ensure load balancer: failed to update load-balancer with ID e7bbf8b7-29e0-407c-adce-94a3205b38b5: PUT https://api.digitalocean.com/v2/load_balancers/e7bbf8b7-29e0-407c-adce-94a3205b38b5: 403 (request "22ff352c-8486-4a69-8ffc-a4bba64147dc") Load Balancer can't be updated while it processes previous actions
  Warning  SyncLoadBalancerFailed  17m                 service-controller  Error syncing load balancer: failed to ensure load balancer: failed to update load-balancer with ID e7bbf8b7-29e0-407c-adce-94a3205b38b5: PUT https://api.digitalocean.com/v2/load_balancers/e7bbf8b7-29e0-407c-adce-94a3205b38b5: 403 (request "ec7f0138-99ba-4932-b1ff-1cfe46ed24c5") Load Balancer can't be updated while it processes previous actions
  Normal   EnsuringLoadBalancer    15m (x10 over 10h)  service-controller  Ensuring load balancer
  Normal   EnsuredLoadBalancer     15m (x5 over 10h)   service-controller  Ensured load balancer

Below are troubleshooting steps that might help resolve your issue:以下是可能有助于解决您的问题的故障排除步骤:

  1. If you are specifying 2 ports in the yaml file the load balancer will take the whole range between the 2 ports, thus blocking and making them unable to be reused for another service如果您在 yaml 文件中指定 2 个端口,负载均衡器将占用这 2 个端口之间的整个范围,从而阻塞并使它们无法重新用于其他服务
  2. If you are already using a port ex:8086 for the forwarding rule it cannot be reused for another service如果您已将端口 ex:8086 用于转发规则,则不能将其重新用于其他服务
  3. If you have health checks enabled on your load balancer check if those health checks are all passing.如果您在负载均衡器上启用了健康检查,请检查这些健康检查是否全部通过。
  4. Verify that the load balancer is reachable from the public inte.net.验证负载平衡器是否可以从公共 inte.net 访问。
  5. Finally restart the cluster and try to deploy again.最后重启集群,再次尝试部署。

For more information follow troubleshooting documentation .有关详细信息,请参阅故障排除文档 Adding issue with a similar error.添加具有类似错误的问题

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在 kube.netes.network 策略中将 digitalocean 负载均衡器列入白名单? - How to whitelist digitalocean load balancer in kubernetes network policy? DigitalOcean上的Kubernetes外部负载均衡器服务 - Kubernetes External Load Balancer Service on DigitalOcean Kubernetes 负载均衡器终止 SSL 以反向代理入口 DigitalOcean - Kubernetes Load Balancer Terminating SSL to Reverse Proxy Ingress DigitalOcean 将流量从DigitalOcean负载均衡器转发到Kubernetes服务不起作用 - Forwarding traffic from a DigitalOcean Load Balancer to a Kubernetes Service not working Digitalocean kube.netes 集群负载均衡器不能正常工作作为循环法 - Digitalocean kubernetes cluster load balancer doesn't work properly as round robin 如何在aws上创建Kubernetes负载均衡器 - How to create Kubernetes load balancer on aws 如何在Kubernetes中设置HTTPS负载均衡器 - How to setup HTTPS load balancer in kubernetes 如何使用juju访问kubernetes服务负载均衡器 - How to access kubernetes service load balancer with juju 如何在kubernetes的aws上创建应用程序负载均衡器 - How to create application load balancer on aws for kubernetes 将负载均衡器与 Kubernetes 一起使用 - Using a Load Balancer with Kubernetes
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM