Re: Newbie questions relating to transactions - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: Newbie questions relating to transactions
Date
Msg-id 20090308154950.GJ3821@alvh.no-ip.org
Whole thread Raw
In response to Re: Newbie questions relating to transactions  (Carl Sopchak <carl.sopchak@cegis123.com>)
Responses Re: Newbie questions relating to transactions  (Carl Sopchak <carl.sopchak@cegis123.com>)
List pgsql-general
Carl Sopchak wrote:
> Well, the upgrade to 8.3 seemed to rid me of the command limit, but now I'm
> running out of memory.  I have 2Gb physical and 8Gb swap (after adding 4Gb).

Do you have AFTER triggers on the involved tables?  They are recorded on
memory and we have no mechanism to spill to disk, so it's frequent that
those cause out-of-memory.  If that's the explanation, your workaround
would be to get rid of them.

> Is there a way for me to run this outside of one huge transaction?  This
> really shouldn't be using more than a few hundred megs of RAM (assuming
> cursor records are all stored in memory)...

Hmm, maybe you're holding too many cursors open and not closing them
timely?  Did you post your function for review?

--
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

pgsql-general by date:

Previous
From: Gregory Stark
Date:
Subject: Re: Newbie questions relating to transactions
Next
From: Andreas Wenk
Date:
Subject: Re: Enable user access from remote host