- 排错
1:
Warning FailedGetResourceMetric 12s (x41 over 20m) horizontal-pod-autoscaler unable to get metrics for resource cpu: unable to fetch metrics from API: the server could not find the requested resource (get pods.metrics.k8s.io)
解决:kube-controller-manager的启动项加上:
--horizontal-pod-autoscaler-use-rest-clients=false
阿里云K8S:修改/etc/kubernetes/kube-controller-manager.yaml
systemctl daemon-reload
systemctl restart kube-controller-manager
2:
heapster启动参数加入:
--api-server
3:
missing request for cpu on container xxxx in pod xxxx/xxxx-xxxxxxxxxxx-xxxxxx
解决:给该应用加上request资源限制
转载于:https://blog.51cto.com/antistand/2119714