Обсуждение: Synchronization Primitives

Поиск
Список
Период
Сортировка

Synchronization Primitives

От
"崔岩ccuiyyan@sina.com"
Дата:
Hi all:<br /><br />      I am a fresh men in PostgreSQL. And i work on benchmark study these days using PostgreSQL.<br
/><br/>Now i have a question: Is there some way to show the lock contention of PostgreSQL?<br /><br />As I know, you
canuse <b>show mutex status</b>  in MySQL to find which mutex is hot. But i don't know in<br /><br />PostgreSQL.<br
/><br/>    Any ideas?<br /><br />     Thanks!<br /><br />       <br /><br /> 

Re: Synchronization Primitives

От
Hannu Krosing
Дата:
On Thu, 2008-11-13 at 18:55 +0800, 崔岩ccuiyyan@sina.com wrote:
> Hi all:
> 
>       I am a fresh men in PostgreSQL. And i work on benchmark study
> these days using PostgreSQL.
> 
> Now i have a question: Is there some way to show the lock contention
> of PostgreSQL?
> 
> As I know, you can use show mutex status  in MySQL to find which mutex
> is hot. But i don't know in PostgreSQL.

look at pg_locks system view


-- 
------------------------------------------
Hannu Krosing   http://www.2ndQuadrant.com
PostgreSQL Scalability and Availability   Services, Consulting and Training



Re: Synchronization Primitives

От
Markus Wanner
Дата:
Hi,

Hannu Krosing wrote:
>> As I know, you can use show mutex status  in MySQL to find which mutex
>> is hot. But i don't know in PostgreSQL.
> 
> look at pg_locks system view

Or read about dtrace to analyze lower level locking contention:
http://www.postgresql.org/docs/8.3/static/dynamic-trace.html

Regards

Markus Wanner