Re: [Vserver] memory usage

From: Chuck <chuck_at_sbbsnet.net>
Date: Fri 13 Oct 2006 - 14:01:32 BST
Message-Id: <200610130901.32396.chuck@sbbsnet.net>

On Friday 13 October 2006 08:23, Corey Wright wrote:

i should have read the manual first and asked later :P but in my defense it
was VERY early in the am here and i was still waitinig for coffee to brew so
i had not had even my first cup yet.. i should try not to think until then :P

anyway i discovered virt_mem to put into the flags file which works just fine.

your answers actually answered some future things i will be dealing with so
thank you ahead of time :D

we are letting a friend use a guest as a 'colo' and we want him to have all
the resources he needs, but i want to give him a way to see just what he is
using, not combined statistics, so i put the virt uptime, cpu, mem and load
in there and they report exactly what he will want to see.

> On Fri, 13 Oct 2006 06:31:21 -0400
> Chuck <chuck@sbbsnet.net> wrote:
>
> > is there a way to see how much memory a particular guest is using? maybe
> > something similar to the free command? i have no memory limitations on
> > these first few.
>
> i use vserver-stat for informational purposes and not for placing resource
> limits.
>
> to decipher vsz & rss (as used in vserver-stat), see
> http://oldwiki.linux-vserver.org/Memory+Management.
>
> of course, memory accounting seems to be such a variable thing from command
> to command and os to os (see the many internet discussions at large
> trying to explaining the memory usage reported by top). witnessed within
> vserver's very own wiki:
>
> from http://oldwiki.linux-vserver.org/Memory+Management:
>
> the RSS (resident set size) is the amount of pages which are currently in
> RAM (physical memory)
>
> from http://linux-vserver.org/Memory_Limits:
>
> The Resident Set Size (rss) is the amount of virtual memory (RAM + swap)
> that the context is allowed to use
>
> so from the vserver wiki (both old & new) it appears that for vserver-stat
> rss = guests' RAM usage, but for memory limits rss = guest's RAM + swap.
> and then in my case i use vhashify, so all guests using apache have memory
> shared among them, so properly accounting that shared memory is tricky
> (does the total shared memory get accounted to each guest, or do you divide
> the total shared memory equally among all guests, etc).
>
> but if you don't have to account for shared usage amoung vservers, then i
> presume vserver-stat is pretty accurate of each guests' specific memory
> usage and the difficulty is choosing policy (do you want to limit RAM usage
> or a guest's total memory usage, ie RAM + swap, if you can even have that
> granularity in memory limits).
>
> i looked into memory limits a year ago or so and gave up as i'm in control
> of all guests (though it would be nice to keep a process from running away,
> either from a memory leak or DOS attack).
>
> hopefully somebody will correct me if i'm wrong in my details above, but
> at least look to vserver-stat as a possible answer to your question.
>
> corey
> --
> undefined@pobox.com
> _______________________________________________
> Vserver mailing list
> Vserver@list.linux-vserver.org
> http://list.linux-vserver.org/mailman/listinfo/vserver
>

-- 
Chuck
"...and the hordes of M$*ft users descended upon me in their anger,
and asked 'Why do you not get the viruses or the BlueScreensOfDeath
or insecure system troubles and slowness or pay through the nose 
for an OS as *we* do?!!', and I answered...'I use Linux'. "
The Book of John, chapter 1, page 1, and end of book
_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Fri Oct 13 14:03:23 2006
[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Fri 13 Oct 2006 - 14:03:34 BST by hypermail 2.1.8