Docker报swap限制警告

wes1502 / 2023-08-03 / 原文

docker告警

Your kernel does not support swap limit capabilities or the cgroup is not mounted. Memory limited without swap.

/etc/default/grub文件末尾添加

vi /etc/default/grub
...
GRUB_CMDLINE_LINUX="cgroup_enable=memory swapaccount=1"

更新grub,重启服务器

update-grub
reboot