Per Jessen wrote:
I've been trying to find some clues as to why mailman/postorious is so slow, e.g. when discarding held messages.
I have notcied some long-running queries, running for 5-10-15mins, which is bad enough, but I can't connect them to the slow discards. However, I also see a few commits that have been waiting since yesterday:
mailman=> select usename,query_start,query from pg_stat_activity WHERE (now()-query_start) > interval '5 minutes'; usename | query_start | query ---------+-------------------------------+-------- mailman | 2022-01-17 15:40:06.544184+00 | COMMIT mailman | 2022-01-18 16:26:05.343713+00 | COMMIT mailman | 2022-01-17 15:40:14.329369+00 | COMMIT mailman | 2022-01-17 15:40:13.993539+00 | COMMIT mailman | 2022-01-17 15:40:15.522812+00 | COMMIT (5 rows)
Earlier I had one more: mailman | 2022-01-17 15:40:12.888636+00 | COMMIT
More of the same from this morning: mailman=> select usename,query_start,now()-query_start as elapse,query from pg_stat_activity WHERE (now()-query_start) > interval '5 minutes'; usename | query_start | elapse | query ---------+-------------------------------+-----------------+-------- mailman | 2022-01-19 08:25:24.162833+00 | 01:13:06.656886 | COMMIT mailman | 2022-01-19 08:54:07.105261+00 | 00:44:23.714458 | COMMIT (2 rows) -- Per Jessen, Zürich (2.0°C) Member, openSUSE Heroes