pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Scott Marlowe <scott.marlowe@gmail.com>
To: Alexy Khrabrov <deliverable@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: two memory-consuming postgres processes
Date: Fri, 2 May 2008 13:30:38 -0600
Message-ID: <dcc563d10805021230i5916561k3962a41e2afa894c@mail.gmail.com> (raw)
In-Reply-To: <A728C858-76CF-473F-917B-3C9EA4AA75CF@gmail.com>
References: <A728C858-76CF-473F-917B-3C9EA4AA75CF@gmail.com>

On Fri, May 2, 2008 at 1:24 PM, Alexy Khrabrov <deliverable@gmail.com> wrote:
> Greetings -- I have an UPDATE query updating a 100 million row table, and
> allocate enough memory via shared_buffers=1500MB.  However, I see two
> processes in top, the UPDATE process eating about 850 MB and the writer
> process eating about 750 MB.  The box starts paging.   Why is there the
> writer taking almost as much space as the UPDATE, and how can I shrink it?

Shared_buffers is NOT the main memory pool for all operations in
pgsql, it is simply the buffer pool used to hold data being operated
on.

Things like sorts etc. use other memory and can exhaust your machine.
However, I'd like to see the output of vmstat 1 or top while this is
happening.

How much memory does this machine have?



view thread (21+ messages)  latest in thread

Message-ID: <dcc563d10805021230i5916561k3962a41e2afa894c@mail.gmail.com>
Permalink:  ../dcc563d10805021230i5916561k3962a41e2afa894c@mail.gmail.com/
Also on:    postgresql.org/message-id/dcc563d10805021230i5916561k3962a41e2afa894c@mail.gmail.com

 · 

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: scott.marlowe@gmail.com, deliverable@gmail.com
  Subject: Re: two memory-consuming postgres processes
  In-Reply-To: <dcc563d10805021230i5916561k3962a41e2afa894c@mail.gmail.com>

* 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