Read Time:24 Second
Issue:
- I have a 16G memory and configured swap as 16G.
- When start
mysql docker,mysqld usescrazy amount of memory and make the system freeze.
References:
Solution
$ sudo sysctl -a |grep 'vm.swapp*\|vm.over*'
$ sudo sysctl vm.swappiness=0
$ sudo sysctl vm.overcommit_memory=1
$ sudo sysctl -a |grep 'vm.swapp*\|vm.over*'
$ cat /proc/sys/vm/overcommit_memory
$ cat /proc/sys/vm/swappiness