[lxc-users] Default memory.limit_in_bytes seems high

Serge Hallyn serge.hallyn at ubuntu.com
Mon Apr 14 17:49:16 UTC 2014


Quoting Nels Nelson (nels.n.nelson at gmail.com):
> I'm guessing that the default for memory.limit_in_bytes is supposed to just
> be effectively unlimited.

Right.

> # lxc-create -n test -t minimal
> # lxc-start -n test -d
> # lxc-attach -n test -- cat
> /sys/fs/cgroup/memory/lxc/test/memory.limit_in_bytes
> 18446744073709551615
> 
> Is that so?  I've been trying to find documentation on default values for
> cgroups, but I've not found anything yet.
> 
> Neither https://www.kernel.org/doc/Documentation/cgroups/cgroups.txt, nor
> https://www.kernel.org/doc/Documentation/cgroups/memory.txt seem to
> indicate what are the defaults.

I'd recommend running the container for a bit, look at
memory.max_usage_in_bytes, and use that as a guideline for a sane
value for 'lxc.cgroup.memory.limit_in_bytes =' in the container
configuration.


More information about the lxc-users mailing list