Kubernetes Cluster Collector Container Metrics: No data

CMK version: 2.2.0p12
OS version: Ubuntu 22.10

Error message: Container Metrics: No data(No container metrics were collected from the cluster collector )CRIT

Output of “cmk --debug -vvn hostname”: (If it is a problem with checks or plugins)

PU resources        Requests: 0.000 (0/2 containers with requests), Limits: 0.000 (0/2 containers with limits), Allocatable: 0.000
Cluster collector    Cluster collector version: 1.5.0, Nodes with container collectors: 1/1, Nodes with machine collectors: 1/1, Container Metrics: No data(!!), Machine Metrics: OK
Info                 Name: kube
Kubernetes API       Live, Ready
Memory resources     Requests: 0 B (0/2 containers with requests), Limits: 0 B (0/2 containers with limits), Allocatable: 0 B
Nodes                No worker nodes found, Control plane nodes 1/1
Pod resources        Running: 0, Pending: 1, Succeeded: 0, Failed: 0, Unknown: 0, Allocatable: 0

I will try to get some Monitoring Data from my Kubernetes Cluster. (K3S - Single Node Cluster / Server Version: v1.27.2+k3s1).

The Helm Release 1.5.0 has been successfully installed and i will get all deployments, pods, services, etc. All will work fine.
But no Metric Data can be found.

Is this maybe a problem with the kubernetes version, or while i’m using k3s instead k8s ?

The Debug output will only show not really an error.

Is there any other point where i can check ?

Kind regards
Michél

For k3s you have to add an extra option to the cadviser container args so that it can find the countainerd socket.

kubectl -n checkmk-monitoring edit daemonsets.apps checkmk-node-collector-container-metrics
...
  containers:
  - args:
  ...
    - --storage_duration=1m0s
    - --containerd=/run/k3s/containerd/containerd.sock

last line is the one to add

For reference: in current versions of the helm chart a separate option exists in values.yaml to achieve this:

containerdOverride: "/run/k3s/containerd/containerd.sock"
1 Like