Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id 28CF01337BA1 for ; Thu, 24 Feb 2011 08:29:22 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 12132-03 for ; Thu, 24 Feb 2011 12:29:14 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from gw.wicourts.gov (gwmta.wicourts.gov [165.219.244.99]) by mail.postgresql.org (Postfix) with ESMTP id 6B6CD133616B for ; Thu, 24 Feb 2011 08:29:14 -0400 (AST) Received: from Courts-MTA by gw.wicourts.gov with Novell_GroupWise; Thu, 24 Feb 2011 06:29:13 -0600 Message-Id: <4D65FAB0020000250003AF7F@gw.wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 8.0.1 Date: Thu, 24 Feb 2011 06:29:04 -0600 From: "Kevin Grittner" To: , Subject: Re: Function execution consuming lot of memory and eventually making server unresponsive Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-4.21 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201102/466 X-Sequence-Number: 42604 "Gnanakumar" wrote: > We're using PostgreSQL v8.2.3 on RHEL5. http://www.postgresql.org/support/versioning The 8.2 release is up to 8.2.20: http://www.postgresql.org/ By the way, 8.2 is scheduled to go out of support later this year: http://wiki.postgresql.org/wiki/PostgreSQL_Release_Support_Policy You might want to start planning to upgrade. > I'm developing a PostgreSQL plpgsql function for one of our > application report. When I try to run the function multiple times > (even twice or thrice), I'm seeing considerable amount of memory > being taken up by PostgreSQL and thereby after sometime, complete > server itself comes to standstill and not responding at all, even > am not able to login to my server using PuTTY client. I then end up > physically restarting the server. You might want to review the bug fixes since 8.2.3 and see if any involve memory leaks: http://www.postgresql.org/docs/8.2/static/release.html -Kevin