most-airport-92897
02/28/2025, 2:42 PM/etc/rancher/rke2/config.yaml.d/thresholds.yaml
and content:
systemReserved:
cpu: "1"
kubeletArgs:
- "--eviction-hard=memory.available<16Gi"
After restarting with systemctl restart rke2-agent
, the following entry appears in the node yaml:
<http://rke2.io/node-args|rke2.io/node-args>: >-
["agent","--server","*****","--token","*****","--systemReserved","[{cpu
1}]","--kubeletArgs","--eviction-hard=memory.available\u003c16Gi"]
Additionally, the kubelet parameters that show up in systemctl status rke2-agent do not include my additions and there already is an eviction parameter that is set by default:
"--eviction-hard=imagefs.available<5%,nodefs.available<5%"
When i spawn containers and force the total memory usage on the above the specified threshold of 16Gi, the pods do not get evicted and the node reaches an OOMKill state, which I try to avoid. Are there any mistakes in my configuration? Or does my config get overwritten by the default eviction values of the rke2-agent? Many thanks!