Reputation: 109
Has any one seen this error Error: forwarding ports: error upgrading connection: Upgrade request required
in Kubernetes
Upvotes: 5
Views: 9963
Reputation: 712
Ran into this today when trying to use Garden.io for a cluster running in Jelastic.
Found the solution in this Github comment:
First acquire a local binary for Tiller (server-version of Helm), either by compiling or by downloading it from the release page.
Then run:
$ export HELM_HOST=":44134"
$ tiller -listen ${HELM_HOST} -alsologtostderr >/dev/null 2>&1 &
This will run a local version of the Kubernetes Helm Server. Now try your original command again, kubectl, that will delegate to this local Helm instead and manage to connect.
Upvotes: 0
Reputation: 109
we were able to resolve it by using ip for the kube server instead of the hostname. This is caused by load balancers not supporting HTTP/2. Instead of using the https://hostname URL to Kube, use the IP address, and disable SSL verification
kubectl config set-cluster $NAME --user=$USER --server=$KUBE_URL --insecure-skip-tls-verify=true
Upvotes: 1
Reputation: 1856
I have seen this before and there were a couple of issues to address:
The Nginx that was proxying requests did not contain the following config (required for HTTP2 support):
proxy_set_header Upgrade 'websocket';
proxy_set_header Connection 'Upgrade';
And we also had to switch our Classic Load Balancer on AWS (ELB) with an Application Load Balancer (ALB).
TBH, the question is a bit vague. Where are you seeing this exactly? It needs more context.
Upvotes: 3