Rancher部署metrics-server报错

Rancher Server 设置

  • Rancher 版本:v2.6.3

下游集群信息

  • Kubernetes 版本: v1.20.14

问题描述:
rancher部署metrics-server报错
重现步骤:

结果:

预期结果:

截图:

其他上下文信息:

日志

kubectl top node

Error from server (ServiceUnavailable): the server is currently unable to handle the request (get nodes.metrics.k8s.io)

kube-apiserver 日志:
E0512 09:46:29.423237 1 available_controller.go:508] v1beta1.metrics.k8s.io failed with: Operation cannot be fulfilled on apiservices.apiregistration.k8s.iov1beta1.metrics.k8s.io”: the object has been modified; please apply your changes to the latest version and try again
E0512 09:46:34.589259 1 available_controller.go:508] v1beta1.metrics.k8s.io failed with: Operation cannot be fulfilled on apiservices.apiregistration.k8s.iov1beta1.metrics.k8s.io”: the object has been modified; please apply your changes to the latest version and try again

rancher 创建的集群已经自带 metrics-server ,不需要重新部署了

先谢谢您的回复!
那为什么无法使用kubectl top node?

➜  root kubectl top node
error: Metrics API not available

自带的metrics-server是在哪个空间中?