Re: Out of memory on SELECT in 8.3.5 - Mailing list pgsql-general

From Stephen Frost
Subject Re: Out of memory on SELECT in 8.3.5
Date
Msg-id 20090209203331.GG8123@tamriel.snowman.net
Whole thread Raw
In response to Re: Out of memory on SELECT in 8.3.5  ("Matt Magoffin" <postgresql.org@msqr.us>)
List pgsql-general
* Matt Magoffin (postgresql.org@msqr.us) wrote:
> Thanks for the advice. Should we have more than 2GB of swap available? I
> thought the goal for a Postgres system was to avoid swap use at all cost?
> Would it be better for us to add more swap, or adjust this
> overcommit_ratio as you discuss?

You do want to avoid swap, but at the same time you don't want to end up
with lots of real memory unavailable for use (as here..).  After
thinking about this for a bit, my suggestion would be to add swap up to
the amount of memory you have, for starters.  That would give you 24G of
commitable memory.  I would then pay attention to free, swap usage, and
/proc/meminfo.  If you start using alot of swap, you might want to
adjust PG to use less memory; if you see alot of free memory but you're
close to your commit limit, up the ratio some.

Basically, the swap would be there just in case all those folks with
outstanding committed memory decide to actually use it.  That's not all
*that* likely to happen, in the end.

    Thanks,

        Stephen

Attachment

pgsql-general by date:

Previous
From: "Matt Magoffin"
Date:
Subject: Re: Out of memory on SELECT in 8.3.5
Next
From: Scott Marlowe
Date:
Subject: Re: Out of memory on SELECT in 8.3.5