Re: [RFC] should physmem be cgroup-aware?

Collin Funk <[email protected]>
Newsgroups gmane.comp.lib.gnulib.bugs
Message-ID <[email protected]>
Bruno Haible <[email protected]> writes:

> Sounds fine for physmem_available and physmem_claimable.
>
> For physmem_total, I'm not sure. It is defined as "the total amount of
> physical memory". So, either
>   - leave physmem_total as it is, or
>   - invent a new function physmem_in_container,
>   - or add a 'bool in_container' parameter to physmem_total.

Perhaps a different function would be good. I'm thinking there may be
other platform-specific features that could be supported. E.g., FreeBSD
has jails, but I am not sure they have the ability to limit resources.
For the typical platform it can fallback to one of the physmem
functions.

I guess the hard part is thinking of a name. I considered "usablemem" at
first, but feel that it gives the impression you are returning the
difference if phyiscal memory and used memory at the current moment.

Collin
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.