Skip site navigation (1) Skip section navigation (2)

Re: How does the partitioned lock manager works?

From: Heikki Linnakangas <heikki(at)enterprisedb(dot)com>
To: rancpine cui <rancpine(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: How does the partitioned lock manager works?
Date: 2007-04-27 09:01:58
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
rancpine cui wrote:
>    When the lock manager's data structures were split into "partitions",
> how many such data structures can one partition control? 

The number of partitions is 16 (NUM_LOCK_PARTITIONS). The total size of 
the lock hash table is max_locks_per_xact * (max_connections + 
max_prepared_xacts). So the number of "lock slots" per partition is 
(max_locks_per_xact * (max_connections + 

> Since we use
> LOCKTAG's hash value to decide the partition which the lock should in, can
> all locks be split into ONE partition?

In theory, yes. It's extremely unlikely to happen in practice.

   Heikki Linnakangas

In response to


pgsql-hackers by date

Next:From: Hans-Juergen SchoenigDate: 2007-04-27 10:56:27
Subject: Re: Hi, I wanto joinin the developer group of postgresql
Previous:From: Dave PageDate: 2007-04-27 08:53:10
Subject: Windows support - PostgreSQL 8.0 and 8.1

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group