Re: Postgresql takes more time to update - Mailing list pgsql-admin

From Peter Koczan
Subject Re: Postgresql takes more time to update
Date
Msg-id 4544e0330710061030hd4a494y97b350076a76a17d@mail.gmail.com
Whole thread Raw
In response to Postgresql takes more time to update  ("Suresh Gupta VG" <suresh.g@zensar.com>)
List pgsql-admin

We are using "psql 7.4.2" version of Postgresql, these days all the transactions on the database are taking long time to execute. We are planning to do "ANALYZE " command on the database. Could you please advice us, how much time it takes and what are the conditions we need to keep on an eye.


As an alternative to Scott's suggestion (upgrading to the newest 7.4), you could update your postgresql installation to 8.2, or if you can wait a few months, 8.3. There are *huge* performance gains (I recently made a similar switch and everything is blazing fast). Please note that this will require a dump/restore of the data and more involved testing, so only do it if you can devote the time, money, and energy.

As far as analyze goes, you should be running ANALYZE VERBOSE, or better yet, VACUUM ANALYZE VERBOSE (see http://www.postgresql.org/docs/7.4/interactive/sql-vacuum.html ) so you can interpret the output. The vacuum also helps manage disk space, and this isn't a big performance hit because it doesn't require exclusive locks (though a VACUUM FULL would, again, read the docs). In fact, you should be doing this regularly, daily if possible.

For me, I have a 30 GB database cluster, and vacuum/analyze takes about 3 minutes, though YMMV. You want to look for output regarding FSM pages and relations and adjust as necessary (otherwise you're running into index bloat).

Can you please tell us whether we had any other commands are available on postgresql to increase the performance of the database and database tools available for Postgresql on Solaris sparc machine?

I think Scott covered all of this. Alternatively, you could look to upgrading your hardware (multi-core x86 hardware is very nice), but without knowing your needs, usage, or budget, I can't make that determination.

Hope this helps.

Peter
 


pgsql-admin by date:

Previous
From: "Scott Marlowe"
Date:
Subject: Re: Postgresql takes more time to update
Next
From: "Darren Reed"
Date:
Subject: Is my database now too big?