public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andy Isaacson <adi@hexapodia.org>
To: Thomas Schenk <tschenk@origin.ea.com>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: Need assistance in determining memory usage
Date: Wed, 6 Nov 2002 13:42:58 -0600	[thread overview]
Message-ID: <20021106134258.A12322@hexapodia.org> (raw)
In-Reply-To: <1036437769.2902.76.camel@shire>; from tschenk@origin.ea.com on Mon, Nov 04, 2002 at 01:22:44PM -0600

On Mon, Nov 04, 2002 at 01:22:44PM -0600, Thomas Schenk wrote:
> On Mon, 2002-11-04 at 13:01, Alan Cox wrote:
> > On Mon, 2002-11-04 at 18:11, Thomas Schenk wrote:
> > > was adequate, I wouldn't be asking here and every reference I could find
> > > indicates that this is not a trivial problem.  There were also
> > > indications I found while searching that these tools do not always
> > > report memory numbers accurately.  If there is a way to determine this
> > > information using /proc, this would be ideal, since I could then
> > > conceivably create a script or simple program that could determine the
> > > answer given the process ID, which is what the developers here really
> > > want.
> > 
> > Neither the question nor the answer are trivial. What are you trying to
> > do with the data may be the most relevant question
> 
> This situation is this:
> 
> We are building an online game system.  On some of the systems, there
> are simulator processes running that each service a player.  There may
> be up to 200 or more of these processes running at any given time and
> each uses a fairly large amount of memory (as reported by ps).  Part of
> this is due to the fact that the processes have not been optimized to
> make the most efficient use of memory.  When the simulator processes
> start swapping, then the systems are becoming unstable, performance goes
> all to hell and sometimes the systems totally hang.  It would be useful
> for us to be able to monitor as closely as possible the amount of memory
> each processes is using and especially to be notified when these
> processes start using significant amounts of swap, so that we can be
> prepared to react before the situation gets out of hand.

I do not believe that the kernel exports the information "what processes
are using swap?".  You can answer some of your questions by using my
pmap program; it's in at least some recent procps packages, or download
the source:
http://web.hexapodia.org/~adi/pmap.c

-andy

  reply	other threads:[~2002-11-06 19:36 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-04 18:11 Need assistance in determining memory usage Thomas Schenk
2002-11-04 18:18 ` bert hubert
2002-11-04 18:34 ` Ketil Froyn
2002-11-04 18:40 ` Richard B. Johnson
2002-11-04 19:01 ` Alan Cox
2002-11-04 19:22   ` Thomas Schenk
2002-11-06 19:42     ` Andy Isaacson [this message]
  -- strict thread matches above, loose matches on Subject: below --
2002-11-04 21:11 Dan Kegel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20021106134258.A12322@hexapodia.org \
    --to=adi@hexapodia.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=tschenk@origin.ea.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox