kubernetes指标服务器无法获取pod指标

时间:2019-04-07 05:29:12

标签: kubernetes

我正在安装安装了公制服务器的HPA,但是在公制服务器日志中出现错误

webhook.go:192] Failed to make webhook authorizer request: 0-length response
 errors.go:90] 0-length response
unable to fetch pod metrics for pod
unable to fetch metrics from Kubelet kmaster (10.1.1.134): request failed - "401 Unauthorized", response: "Unauthorized"

我也设置了这些标志

- command:
        - /metrics-server
        - --kubelet-insecure-tls
        - --kubelet-preferred-address-types=InternalIP

kubectl获取--raw /apis/metrics.k8s.io/v1beta1/namespaces/nava/pods/elasticsearch-58c6df47f-xb7pd

{“ kind”:“ PodMetrics”,“ apiVersion”:“ metrics.k8s.io/v1beta1","metadata":{"name":"elasticsearch-58c6df47f-xb7pd","namespace":"nava” ,“ selfLink”:“ / apis / metrics.k8s.io / v1beta1 / namespaces / nava / pods / elasticsearch-58c6df47f-xb7pd”,“ creationTimestamp”:“” 2019-04-07T06:01:17Z“},” timestamp“ :“” 2019-04-07T06:00:59Z“,”窗口“:” 30s“,”容器“:[{”名称“:” elasticsearch“,”用法“:{” cpu“:” 5397519n“,”内存“:” 1499976Ki“}}]}

kubectl获取--raw /apis/metrics.k8s.io/v1beta1/namespaces/default/pods/busybox

服务器错误(未找到):podmetrics.metrics.k8s.io“默认/繁忙框”未找到

0 个答案:

没有答案