containerd does not support systemd cgroupDriver

Bug #1951911 reported by Hua Zhang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Containerd Subordinate Charm
New
Undecided
Unassigned

Bug Description

If we want to use cgroupDriver=systemd, we need to do:

1, configure kubelet to use cgroupDriver=systemd

juju config kubernetes-worker kubelet-extra-config="{cgroupDriver: 'systemd'}"

# grep -r 'cgroupDriver' /root/cdk/kubelet/config.yaml
cgroupDriver: systemd

2, configure containerd to use SystemdCgroup = true according to issue [1] and [2].

[plugins."io.containerd.grpc.v1.cri".containerd.runtimes.runc.options]
  SystemdCgroup = true

but containerd charm [3] doesn't support to configure cgroupDriver, so we saw the following issue that memory metric just has one item workingSetBytes.

root@juju-88a257-k8s-4:~# curl -qk -H "Authorization:Bearer $(kubectl -n kube-system get secret metrics-server-token-rtz6s -o jsonpath={.data.token} | base64 -d)" -k https://127.0.0.1:10250/stats/summary 2>/dev/null| jq .pods[0].containers[0].memory
{
  "time": "2021-11-23T03:45:56Z",
  "workingSetBytes": 65458176
}

[1] https://github.com/kubernetes/kubernetes/issues/106514
[2] https://github.com/containerd/containerd/issues/4900
[3] https://github.com/charmed-kubernetes/charm-containerd/blob/master/templates/config.toml

Tags: seg
Hua Zhang (zhhuabj)
tags: added: seg
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.