I am running Ubuntu 14.04 LTS inside a OpenVZ (Virtuozzo) container. There are basic services running (Apache, Postfix, Dovecot, MariaDB, OpenVPN, LDAP, memcached, php-fpm, nscd) and I am already hitting some limits as seen in /proc/user_beancounters
, in particular kmemsize:
Version: 2.5
uid resource held maxheld barrier limit failcnt
79053013: kmemsize 39057604 41549824 41943040 50331648 18
This after only about 12 hours uptime; before there were lots (hundreds) of failures with kmemsize, shmpages, tcpsndbuf.
My questions would be:
- is it possible that some of the services leak resources (which don't get released even if I restart them), or that resource usage increases in time even without leaks?
- how can I see restricted resource usage with better granularity, so that I know what to tweak?
- any tips/links on lowering those in question (in particular kmemsize, shmpages)?
- any guesses which service is the most resource-hungry?