LoadBalancer not working after updates

Posted July 5, 2021 328 views

I recently upgraded my Kubernetes cluster from 1.20.8-d0.2 to 1.21.2-do.1. This caused cert-manager to no longer work (See this issue)

I decided to use this opportunity to upgrade the load balancer as well, as we were still using the deprecated chart from the Helm stable repository. However, now the load balancer seems to be having issues as well.

After pruning the cert-manager and the nginx-ingress, I used the following to re-install them:

helm repo add nginx
helm repo add jetstack
helm repo update
helm install nginx-ingress nginx/nginx-ingress \
  --create-namespace \
  --namespace nginx-ingress \
  --version 0.10.0 \
  --set-string 'controller.config.entries.compute-full-forwarded-for=true' \
  --set-string 'controller.config.entries.enable-real-ip=true' \
  --set-string 'controller.config.entries.use-forwarded-headers=true' \
  --set-string 'controller.config.entries.use-proxy-protocol=true' \
  --set-string 'controller.service.annotations.service\.beta\.kubernetes\.io/do-loadbalancer-enable-proxy-protocol=true' \
  --set-string 'controller.service.annotations.service\.beta\.kubernetes\.io/'
helm install cert-manager jetstack/cert-manager \
  --create-namespace \
  --namespace cert-manager \
  --version 1.4.0 \
  --set 'installCRDs=true'
kubectl create secret generic digitalocean-dns \
  --from-literal "access-token=$DO_ACCESS_TOKEN" \
  --namespace cert-manager
kubectl apply -f

I also configured the DNS settings in the DigitalOcean cloud console to match the new load balancer (and ensured they are applied using dig.

However, if I make a request now, I get the following output:

$ curl -vv
*   Trying
* Connected to ( port 443 (#0)
* ALPN, offering h2
* ALPN, offering http/1.1
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: /etc/ssl/certs
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* error:1408F10B:SSL routines:ssl3_get_record:wrong version number
* Closing connection 0
curl: (35) error:1408F10B:SSL routines:ssl3_get_record:wrong version number

This is the matching log from the nginx-ingress pod - - [05/Jul/2021:14:09:31 +0000] "PROXY TCP4 34850 443" 400 157 "-" "-" "-"

I also tried if it helps to add ingressClassName: nginx to my ingress, but that doesn’t help either.

What am I missing?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

This is a bug in DigitalOcean Kubernetes version 1.21.2-do.1 and has been fixed in 1.21.2-do.2