[Lxc-users] total RAM limit

Guido Jäkel G.Jaekel at DNB.DE
Thu Jan 31 07:26:56 UTC 2013


On 2013-01-31 07:41, Gary Ballantyne wrote:
> *# echo '64M' > /sys/fs/cgroup/memory/lxc/memory.limit_in_bytes*
> # cat /sys/fs/cgroup/memory/lxc/memory.limit_in_bytes (return 67108864)

Dear Gary,

what's the value of '/sys/fs/cgroup/memory/lxc/'? If it's not '1', all cgroup settings in "lxc" will not be used as a template for the container "lxc/foo".

It might be much simpler to add lxc config entries like 'lxc.cgroup.memory.limit_in_bytes = 64M' to your container configuration.

And to limit use of swap, to my knowledge you also have to limit 'memory.memsw...'. But i may be wrong, on my LXC environmet i don't use swap at all.


greetings

Guido




More information about the lxc-users mailing list