GCP GKE HPA无法读取指标值的问题

时间:2020-10-23 11:05:58

标签: google-cloud-platform google-kubernetes-engine

我们在GKE GCP上使用CPU利用率进行了扩展测试,但是遇到了“ HPA无法读取度量标准值”的CPU利用率错误。我找不到解决方法。之前的安装程序使用完全相同的安装步骤,但现在出现此错误。在事件中,错误是

unable to get metrics for resource cpu: unable to fetch metrics from resource metrics API: the server is currently unable to handle the request (get pods.metrics.k8s.io)   FailedGetResourceMetric 
    
failed to compute desired number of replicas based on listed metrics for Deployment/testscale/testscale: failed to get cpu utilization: unable to get metrics for resource cpu: unable to fetch metrics from resource metrics API: the server is currently unable to handle the request (get pods.metrics.k8s.io)   FailedComputeMetricsReplicas

我尝试通过在yaml中放置资源请求,但是不起作用。还尝试了以下操作以获取有关度量服务器的一些信息,但显示服务器不可用。有人有建议吗?

kubectl get pods --all-namespaces | grep metrics-server
kube-system   metrics-server-v0.3.6-856b7cfdd5-6ngjt                      0/2     Pending   0          5h40m
kubectl get --raw "/apis/metrics.k8s.io/v1beta1/namespaces/default/pods"
Error from server (ServiceUnavailable): the server is currently unable to handle the request

0 个答案:

没有答案