Unix Technical Forum

postgresql performace degrading after a while

This is a discussion on postgresql performace degrading after a while within the Pgsql General forums, part of the PostgreSQL category; --> Hi All, I seem to have a problem with postgresql 7.4.2 running on Red Hat Enterprise Linux ES3. I ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > Pgsql General

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-09-2008, 08:08 AM
Ron Marom
 
Posts: n/a
Default postgresql performace degrading after a while

Hi All,



I seem to have a problem with postgresql 7.4.2 running on Red Hat
Enterprise Linux ES3. I am running an application server over a database
in which tables contains at most a few thousands of records. The
problematic table, however, contains 67 records, with an application
daemon updating all those records every 30 seconds.



Everything looks fine as the application goes up, however as it keeps
running, after 1-1.5 days the postgresql connections start consuming
100% of the machine's CPU in kernel mode. When I come to this point,
restart of postgresql, the application and even the entire machine does
not help, as it continues to consume 100% of the CPU immediately after
going up. Nevertheless, I have negated hardware issues/ application bug
as I discovered that when creating a dump of all application data using
the pg_dump utility, then recreating the database using dropdb and
createdb and finally restoring from the dump, I manage to return to the
start point, i.e. everything works fine and I gain more 1-1.5 days of
work.



Can anyone have an idea of what I should do to avoid recreating the DB
every day?



Thanks in Advance.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-09-2008, 08:08 AM
Michael Fuhr
 
Posts: n/a
Default Re: postgresql performace degrading after a while

On Mon, Jan 30, 2006 at 09:02:24AM +0200, Ron Marom wrote:
> I seem to have a problem with postgresql 7.4.2 running on Red Hat
> Enterprise Linux ES3.


If you can't upgrade to 8.0 or 8.1 then at least consider using the
latest version in the 7.4 branch (7.4.11). You're missing almost
two years of bug fixes.

http://www.postgresql.org/docs/7.4/static/release.html

> I am running an application server over a database in which tables
> contains at most a few thousands of records. The problematic table,
> however, contains 67 records, with an application daemon updating
> all those records every 30 seconds.


Are you vacuuming that table frequently? If not then it's accumulating
a lot of dead tuples, which would cause performance to degrade.

Are you vacuuming at all? See "Routine Database Maintenance Tasks"
in the documentation for an explanation of what it is and why it's
necessary.

http://www.postgresql.org/docs/7.4/s...intenance.html

--
Michael Fuhr

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:25 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com