Kubelet Service is Unstable due to Invalid vm/Overcommit_memory Kernel Flag
Problem
- kubelet service is unstable showing the below error in the log:
Failed to start ContainerManager invalid kernel flag: vm/overcommit_memory, expected value: 1, actual value: 0
Environment
- Platform9 Edge Cloud v-5.3.0
Cause
- In one of the master node, the vm.overcommit_memory parameter in the /etc/sysctl.conf file set to "0"
x
#sysctl vm.overcommit_memory
vm.overcommit_memory = 0
Resolution
- Replace the value of above parameter in the /etc/sysctl.conffile with 1
# overcommit memory
vm.overcommit_memory=0 >>>>>>>>>>>>>> Replace this with 1
- Run below command to persist the change made above:
# sysctl -p
- After making the change, confirm if the value is reflected for the parameter:
# sysctl vm.overcommit_memory
- Check pf9-kubelet.service status, if it is still stuck in failed state, restart once and confirm if it becomes healthy.
# systemctl status pf9-kubelet
# systemctl restart pf9-kubelet
Was this page helpful?