From: | Japin Li <japinli(at)hotmail(dot)com> |
---|---|
To: | Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> |
Cc: | wenhui qiu <qiuwenhuifx(at)gmail(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Thoughts about NUM_BUFFER_PARTITIONS |
Date: | 2024-02-19 02:26:06 |
Message-ID: | ME3P282MB3166E5DA8739A1A85EB0DADBB6512@ME3P282MB3166.AUSP282.PROD.OUTLOOK.COM |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, 19 Feb 2024 at 00:56, Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> wrote:
> On 2/18/24 03:30, Li Japin wrote:
>>
>> I find it seems need to change MAX_SIMUL_LWLOCKS if we enlarge the NUM_BUFFER_PARTITIONS,
>> I didn’t find any comments to describe the relation between MAX_SIMUL_LWLOCKS and
>> NUM_BUFFER_PARTITIONS, am I missing someghing?
>
> IMHO the relationship is pretty simple - MAX_SIMUL_LWLOCKS needs to be
> higher than NUM_BUFFER_PARTITIONS, so that the backend can acquire all
> the partition locks if needed.
>
Thanks for the explanation! Got it.
> There's other places that acquire a bunch of locks, and all of them need
> to be careful not to exceed MAX_SIMUL_LWLOCKS. For example gist has
> GIST_MAX_SPLIT_PAGES.
>
>
> regards
From | Date | Subject | |
---|---|---|---|
Next Message | Kyotaro Horiguchi | 2024-02-19 02:56:22 | Re: Do away with zero-padding assumption before WALRead() |
Previous Message | Masahiko Sawada | 2024-02-19 02:01:45 | Re: [PoC] Improve dead tuple storage for lazy vacuum |