Unable to connect to the server: dial tcp 192.168.0.101:6443: i/o timeout
Someone know how to fix this?
That means that the kubetl client is not able to make a connection to the kube apiserver. I think, when enabled, the non TLS port is exposed over local host for that service?
At any rate, it's worth:
- checking that the kube-apiserver is running, and is configured to listen on that port
- there are no firewalls in place between the client (kubectl) and the kube-apiserver
If you run
kubectl get pods -v=9
Kubectl will show you a cURL command you can use to further debug the issue.
Thanks! I had this problem for a long time, when running kubectl commands, it took 5-10 seconds before getting results back. With the kubectl get pods -v=9 i was able to debug the slow responses, and found out that my cache/discovery folder in .kube, had the wrong permissions.
This is the reponse time for kubectl get pods now:
real 0m0.105s
user 0m0.111s
sys 0m0.018s