Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Aaron Bono
I queried pg_stat_activity a bunch of times and was able to tell what tables were being queried. I finally honed in on the section of code causing the problem and fix it and all is good on the server now - over 90% idle. I think the reason some of the processes were showing high CPU usage was th

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread adey
The following query with the stats_command_string parameter turned on will give you some of the SQL per transaction:- SELECT datid, datname as "DB Name", substr(procpid,1,6) as "Procpid", substr(usesysid,1,5) as "UseSysid", usename, current_query as "SQL", query_start FROM pg_stat_activity order

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Tomeh, Husam
cerely, -- Husam From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Aaron Bono Sent: Wednesday, November 22, 2006 1:14 PM To: Tomeh, Husam Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] Monitoring PostgreSQL Process On 11/22/06, Tomeh, Husam <[EMAIL PROTECTED]> wrote:

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Tomeh, Husam
D] On Behalf Of Aaron Bono Sent: Wednesday, November 22, 2006 1:46 PM To: Tomeh, Husam Cc: pgsql-admin@postgresql.org Subject: Re: [ADMIN] Monitoring PostgreSQL Process On 11/22/06, Tomeh, Husam <[EMAIL PROTECTED]> wrote: This indicates that some stats parameters are not enabled in

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Aaron Bono
h, Husam *Cc:* pgsql-admin@postgresql.org *Subject:* Re: [ADMIN] Monitoring PostgreSQL Process On 11/22/06, Tomeh, Husam <[EMAIL PROTECTED]> wrote: > > You may query the system view, pg_stat_activity to check out the > current SQL statements running. To track down executed SQL state

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Aaron Bono
I check these tables. -- *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On Behalf Of *Aaron Bono *Sent:* Wednesday, November 22, 2006 1:46 PM *To:* Tomeh, Husam *Cc:* pgsql-admin@postgresql.org *Subject:* Re: [ADMIN] Monitoring PostgreSQL Process On 11/22/06, Tomeh, Husam <

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Aaron Bono
On 11/22/06, Tomeh, Husam <[EMAIL PROTECTED]> wrote: You may query the system view, pg_stat_activity to check out the current SQL statements running. To track down executed SQL statements into a physical log file, you may want to enable statement logging. For more details on that, check out: ht

Re: [ADMIN] Monitoring PostgreSQL Process

2006-11-22 Thread Tomeh, Husam
You may query the system view, pg_stat_activity to check out the current SQL statements running. To track down executed SQL statements into a physical log file, you may want to enable statement logging. For more details on that, check out: http://www.postgresql.org/docs/8.1/static/runtime-config-lo