Welcome to the Linux Foundation Forum!

Lab 4.5. Setting Pod Resource Limits and Requirements: Cannot get Metrics Server to Work

Hello,

I did not have metrics server installed for lab 4.5, so I went to install it with this command:

kubectl apply -f https://github.com/kubernetes-sigs/metrics-server/releases/latest/download/components.yaml

This command finished without issue. However, when I run kubectl top nodes or kubectl top pods, I am getting this error and I cant find a way to get around it:

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

When I run kubectl get deployment metrics-server -n kube-system I see this:

notready

and when I run kubectl describe pods metrics-server -n kube-system is see that the readiness probe failed:

describe

I tried the solution here: https://stackoverflow.com/questions/62138734/metric-server-not-working-unable-to-handle-the-request-get-nodes-metrics-k8s but that did not fix the problem. It spun up a second metrics-server deployment that is now failing with a CrashLoopBack off:

Any thoughts or solutions? Thanks :smile:

Answers

  • Posts: 10
    edited June 13

    For anyone wondering here: I don't think the task is to run the kubectl top node or kubectl top pod command. Just the node you are logged in (which is actually either one of the VM you created) run the command: top
    It is not about Kubernetes resources but from all of the recourses of the VM, if you run the command "top" you will see on the worker node that the stress is on the top of the table with it's resource consume.

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Categories

Upcoming Training