在使用k3d运行kubectl命令时,会出现“服务器目前无法处理该请求”的错误提示
首先
我在搭建k3d环境时出现了错误,让我感到困扰,因此我将其总结如下。
请问有什么需要帮助的吗?
我用k3d创建集群并运行”kubectl get po”时出现了错误。
E0406 10:16:14.156000 1794 memcache.go:287] couldn't get resource list for metrics.k8s.io/v1beta1: the server is currently unable to handle the request
E0406 10:16:14.231443 1794 memcache.go:121] couldn't get resource list for metrics.k8s.io/v1beta1: the server is currently unable to handle the request
E0406 10:16:14.233014 1794 memcache.go:121] couldn't get resource list for metrics.k8s.io/v1beta1: the server is currently unable to handle the request
E0406 10:16:14.234844 1794 memcache.go:121] couldn't get resource list for metrics.k8s.io/v1beta1: the server is currently unable to handle the request
解决方案 ‘àn)
使用下面的命令成功删除并重新创建了集群。
$ k3d delete cluster
$ curl -sfL https://get.k3s.io |INSTALL_K3S_EXEC="--disable traefik --disable local-storage --node-name hkm.int.h.net --node-ip 192.168.151.10 server --node-taint CriticalAddonsOnly=true:NoExecute" sh -
$ k3d create cluster
最后
虽然一开始构建的时候遇到了相同的错误,但奇怪的是,过了一段时间错误就消失了,也许重新打开终端试试会有好结果。
请参考