k8s关于支持的cgroup driver问题-systemd

k8s关于支持的cgroup driver问题

社区在2019

  1. 8月29号有一个issue提到在redhat系列系统中默认支持cgroup driver为systemd

    https://github.com/kubernetes-sigs/kubespray/issues/5134

    k8s关于支持的cgroup driver问题-systemd

  2. issue 5134提到在使用systemd作为cgroup管理时需要更新systemd为v242版本
    k8s关于支持的cgroup driver问题-systemd

官档在描述cgroup driver时也申明,linux发行版本在linux发行版下使用也应设置cgroup driver为systemd

因为cgroup的发展,linux的发行版本基本都是使用systemd服务来管理cgroup的,如果k8s使用cgroupfs而系统采用systemd,则系统中会存在两套管理cgroup,在资源使用有压力的情况下会导致使用不稳定。
https://kubernetes.io/docs/setup/production-environment/container-runtimes/#cgroup-drivers

k8s关于支持的cgroup driver问题-systemd

rhel默认对应的system版本为219

即我们现在所面临的systemd的dbus问题均是因为默认采用了systemd的cgroup driver,但systemd的版本低于v242

https://github.com/cri-o/cri-o/issues/3808
解决rhel 7使用cgroup driver的问题,需要升级systemd版本为v242

参考文章:

Jan 30 22:40:01 iZwz959djw7jznons1li1gZ systemd-logind: Failed to start session scope session-31684.scope: The maximum number of pending replies per connection has been reached

https://github.com/coreos/bugs/issues/1435
https://github.com/kubernetes/kubeadm/issues/1394
https://github.com/systemd-rhel/rhel-7   
https://github.com/systemd-rhel/rhel-8/tree/v245
https://systemd.io/CONTRIBUTING/

systemd v242版本才修复
https://github.com/lnykryn/systemd-rhel/issues/266   systemd stop read and process dbus event of runc cgroup invokes #266
issue 226 对应的fix issue
          https://github.com/systemd/systemd/pull/11818  sd-bus: deal with cookie overruns #11818
           https://github.com/systemd/systemd/issues/11809 sd_bus->cookie as 32bit dbus1 message serial number overflow and systemd1 dbus no response. #11809

k8s关于支持的cgroup driver问题-systemd

猜你喜欢

转载自blog.51cto.com/bingdian/2667503