Linux Docker uses excessive memory

Read Time:24 Second


  • I have a 16G memory and configured swap as 16G.
  • When start mysql docker, mysqld uses crazy amount of memory and make the system freeze.



$ 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

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.