-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
metrics-server unable to authenticate to apiserver #278
Comments
Anyone that could please help? |
There is some one there?. After searching a loot I´ve found that this metrics server version is not working with kubernetes 1.14. I've tested the standard solution: command: But is does't work to me, I still can't access to the data on my node workers: $ kubectl top nodes This is the error I can see at the logs: E0619 17:46:11.232435 1 manager.go:111] unable to fully collect metrics: [unable to fully scrape metrics from source kubelet_summary:kubernetesworker2: unable to fetch metrics from Kubelet kubernetesworker2 (192.168.137.112): Get https://192.168.137.112:10250/stats/summary/: dial tcp 192.168.137.112:10250: i/o timeout, unable to fully scrape metrics from source kubelet_summary:kubernetesworker1.enova.mx: unable to fetch metrics from Kubelet kubernetesworker1.enova.mx (192.168.137.111): Get https://192.168.137.111:10250/stats/summary/: dial tcp 192.168.137.111:10250: i/o timeout] The port is open in both nodes(10250), I can access directly, but the metric server can't. This seems to be a problem related with permissions but, I don't know where to do that configuration. $ kubectl get nodes Thanks in advance for their help. |
Have you solved the problem?
My k8s version is v1.14, and my metrics server version is v0.3.3 |
Your problem is about the host name resolution, ensure that the names of the master and workers are in the /etc/hosts file |
Seems that nobody is giving support here |
/lifecycle stale |
There are a bunch of people reporting this and it seems to be due to a whole bunch of problems. |
/remove-lifecycle stale |
I'm going to work on a PR to try using the API server node proxy endpoint, which I think will make the default, out of hte box, setup, much easier. |
One option I don't think I've seen mentioned, as a temporary workaround:
|
Thanks @tcolgate but your recommendation is not working at 1.14.4 version. Reading the doc seems that the solution is giving right access via RBAC, still reading how this can be done. |
Had to edit Deployment object manually and add this to the container's command:
Later added to helm chart's |
Thanks ! |
After trying to install metric-server 0.36 on a three node server with the following configuration: CentOS 8.0.1905 (Kernel 4.18.0-80.11.2.) I found a default installation of metrics-server (0.3.6) inoperable. I found my way here thanks to this error in the pertinent logs:
Sadly, eskp's findings alone did not suffice for me. With further findings, eskp's settings plus one key extra setting got my install working. I'm still quite new to Kubernetes so I'm spelling this out for anyone who stumbles across this in the hopes that it saves them some time:
Add the following four lines under spec:spec:containers.** I put it before the "image" k8s.gcr.io/metris-server-amd64:v0.3.6" line, like so:
The metric-resolution=30s line is NOT required. It just changes the refresh rate from the default of 60 seconds to 30.
Adding hostNetwork: true is what finally got metrics-server working for me. Without it, nada. Without the kubelet-preferred-address-types line, I could query my master node but not my two worker nodes, nor could I query pods, obviously undesirable results.. Lack of kubelet-insecure-tls also results in an inoperable metrics-server installation. |
thank you verymach |
I created an environment with kubeadm on Vagrant.
After changing as follows, "hostNetwork: true" is no longer needed
|
Closing per Kubernetes issue triage policy GitHub is not the right place for support requests. |
Hello,
I just been trying to install metrics-server 1.8 over k8s 1.14. I've followed the standard instructions:
$ git clone https://github.com/kubernetes-incubator/metrics-server.git
$ kubectl create -f metrics-server/deploy/1.8+/
But it always loop in an error state:
metrics-server-58dfcc7fcc-lsrgw 0/1 CrashLoopBackOff 5 8m21s
looking at the logs I see the next:
0614 22:38:04.236395 1 serving.go:312] Generated self-signed cert (apiserver.local.config/certificates/apiserver.crt, apiserver.local.config/certificates/apiserver.key)
Error: Get https://10.96.0.1:443/api/v1/namespaces/kube-system/configmaps/extension-apiserver-authentication: dial tcp 10.96.0.1:443: i/o timeout
panic: Get https://10.96.0.1:443/api/v1/namespaces/kube-system/configmaps/extension-apiserver-authentication: dial tcp 10.96.0.1:443: i/o timeout
I guess that this issue is maybe related to a fw rules but I'm not sure.
I'm using Calico
Maybe the next info could be useful:
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
calico-typha ClusterIP 10.108.145.124 5473/TCP 66d
kube-dns ClusterIP 10.96.0.10 53/UDP,53/TCP,9153/TCP 66d
metrics-server ClusterIP 10.97.65.85 443/TCP 81m
traefik-ingress-service ClusterIP 10.99.53.245 80/TCP,8080/TCP 4d1h
Thanks in advance for your help
The text was updated successfully, but these errors were encountered: