Re: many sessions wait on LWlock WALWrite suddenly

2025-04-15 Thread Yura Sokolov
wal inserters does their job, we needlessly sleep on their WALInsertLock although they are already in the future. [1] https://commitfest.postgresql.org/patch/5633/ [2] https://commitfest.postgresql.org/patch/5511/ -- regards Yura Sokolov aka funny-falcon

Re: many sessions wait on LWlock WALWrite suddenly

2025-04-15 Thread Yura Sokolov
15.04.2025 13:53, Andres Freund пишет: > Hi, > > On 2025-04-15 13:44:09 +0300, Yura Sokolov wrote: >> 15.04.2025 13:00, Andres Freund пишет: >>> 1) Increasing NUM_XLOGINSERT_LOCKS allows more contention on insertpos_lck >>> and >>>spinlocks scale rea

Re: many sessions wait on LWlock WALWrite suddenly

2025-04-15 Thread Yura Sokolov
its each other, or, in other words, they waits latest of them!!! All backends waits until WAL record written by latest of them will be written and fsynced to disk. (Andres, iiuc it looks to be main bottleneck on the way of increasing NUM_XLOGINSERT_LOCKS. Right?) -- regards Yura Sokolov aka funny-falcon

Re: Lock contention high

2021-12-20 Thread Yura Sokolov
on in buffer manager by not acquiring two locks simultaneously on buffer eviction. v1-0001-* - it is file for postgresql 14 and master branch vpg13v1-0001-* - this file for postgresql 13 Corresponding (not so loud) discussion: https://postgr.es/m/flat/1edbb61981fe1d99c3f20e3d56d6c88999f4227c.camel%40po