pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@commandprompt.com>
To: henk de wit <henk53602@hotmail.com>
Cc: Scott Marlowe <scott.marlowe@gmail.com>
Cc: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: Re: Huge amount of memory consumed during transaction
Date: Wed, 17 Oct 2007 17:40:58 -0300
Message-ID: <20071017204058.GR5737@alvh.no-ip.org> (raw)
In-Reply-To: <BAY124-W594E8378868281E1035467F5A70@phx.gbl>
References: <BAY124-W276814F77A7A7ABE7596B1F5A70@phx.gbl>
	<dcc563d10710110727p224f69aeoa54647185a70ebef@mail.gmail.com>
	<BAY124-W594E8378868281E1035467F5A70@phx.gbl>

henk de wit escribió:
> > How is the memory consumed?  How are you measuring it? I assume you
> > mean the postgres process that is running the query uses the memory.
> > If so, which tool(s) are you using and what's the output that shows it
> > being used?
> 
> It's periodically measured and recorded by a script from which the relevant parts are:
> 
> GET_VSZ="ps aux | grep $REQ_GREP | grep -v grep | grep -v $$ | awk '{print \$5}'
>  | sort -n | tail -n1";
> GET_RSS="ps aux | grep $REQ_GREP | grep -v grep | grep -v $$ | awk '{print \$6}'
>  | sort -n | tail -n1";

Huh, this seems really ugly, have you tried something like just

$ ps -o cmd:50,vsz,rss -C postmaster
CMD                                                   VSZ   RSS
/pgsql/install/00head/bin/postmaster                51788  3992
postgres: writer process                            51788  1060
postgres: wal writer process                        51788   940
postgres: autovacuum launcher process               51924  1236
postgres: stats collector process                   22256   896


-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.



view thread (16+ messages)  latest in thread

Message-ID: <20071017204058.GR5737@alvh.no-ip.org>
Permalink:  ../20071017204058.GR5737@alvh.no-ip.org/
Also on:    postgresql.org/message-id/20071017204058.GR5737@alvh.no-ip.org

 · 

reply

Reply instructions:

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

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: alvherre@commandprompt.com, henk53602@hotmail.com, scott.marlowe@gmail.com
  Subject: Re: Huge amount of memory consumed during transaction
  In-Reply-To: <20071017204058.GR5737@alvh.no-ip.org>

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

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox