Re: proposal for 9.5: monitoring lock time for slow queries

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: proposal for 9.5: monitoring lock time for slow queries
Дата
Msg-id CAB7nPqSP97fU9Tom=+UYWpXrNBTrAG2ggRwazDJvsnC9dtBZcw@mail.gmail.com
обсуждение исходный текст
Ответ на proposal for 9.5: monitoring lock time for slow queries  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: proposal for 9.5: monitoring lock time for slow queries  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: proposal for 9.5: monitoring lock time for slow queries  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-hackers
On Wed, Aug 13, 2014 at 4:59 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> Any idea how to show a lock time in some practical form together with logged
> slow query?

Doing a join on pg_stat_activity and pg_locks is not going to help
much as you could only get the moment when query has started or its
state has changed. Have you thought about the addition of a new column
in pg_locks containing the timestamp of the moment a lock has been
taken? I am sure that we are concerned about the performance impact
that extra calls to gettimeofday could have though...
Regards,
-- 
Michael



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: failures on barnacle (CLOBBER_CACHE_RECURSIVELY) because of memory leaks
Следующее
От: Amit Kapila
Дата:
Сообщение: Re: Scaling shared buffer eviction