query io stats and finding a slow query

From: "Kamen Stanev" <hambai(at)gmail(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: query io stats and finding a slow query
Date: 2007-09-20 21:36:59
Message-ID: de5063670709201436y5cbff0d0k70ade289a4c68199@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Hi everybody,

Is there a way to find which query is doing large io operations and/or which
is using cached data and which is reading from disk. I need to see this on a
production server to localize a slow and resource eating query. The
pg_statio* tables are very handy, but don't help me at all in finding the
most disk intensive** query, just the most used table which I already knew.

And besides that, please share your experience on how do you decide which
queries to optimize and how to reorganize your database? Is there any tools
that you use to profile your database.

Regards,
Kamen Stanev

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Decibel! 2007-09-20 23:04:01 Linux mis-reporting memory
Previous Message Scott Marlowe 2007-09-20 21:25:42 Re: Upgraded from 7.4 to 8.1.4 QUERIES NOW SLOW!!!