Re: query against pg_locks leads to large memory alloc - Mailing list pgsql-performance

From Kevin Grittner
Subject Re: query against pg_locks leads to large memory alloc
Date
Msg-id 1408473810.64930.YahooMailNeo@web122304.mail.ne1.yahoo.com
Whole thread Raw
In response to Re: query against pg_locks leads to large memory alloc  (Dave Owens <dave@teamunify.com>)
Responses Re: query against pg_locks leads to large memory alloc
List pgsql-performance
Dave Owens <dave@teamunify.com> wrote:
> On Tue, Aug 19, 2014 at 11:01 AM, Kevin Grittner <kgrittn@ymail.com> wrote:

>> CREATE TABLE activity_snap_1 AS SELECT * FROM pg_stat_activity;

> Would the you or the list be interested in snapshots of pg_locks as well?

Most definitely!  I'm sorry that copied/pasted the pg_stat_activity
example, I was playing with both.  pg_locks is definitely the more
important one, but it might be useful to try to match some of these
locks up against process information as we drill down from the
summary to see examples of what makes up those numbers.

> I can take a restart tonight and get this going on a half-hourly basis
> (unless you think more frequent snaps would be useful).

Each half-hour should be fine as long as that gives at least three
or four samples before you are unable to query pg_locks.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


pgsql-performance by date:

Previous
From: Dave Owens
Date:
Subject: Re: query against pg_locks leads to large memory alloc
Next
From: "Huang, Suya"
Date:
Subject: query on parent partition table has bad performance