Re: Performance regression when adding LIMIT 1 to a query

2025-04-07 Thread Costa Alexoglou
On Mon, Apr 7, 2025 at 4:06 PM Artur Zakirov wrote: > On Mon, 7 Apr 2025 at 14:45, Costa Alexoglou wrote: > > ... > > with a plan: > > ``` > > Gather Merge (cost=115584.47..118515.35 rows=25120 width=824) (actual > time=46.004..74.267 rows=29653 loops=1) > >

Performance regression when adding LIMIT 1 to a query

2025-04-07 Thread Costa Alexoglou
Hey folks, I faced an interesting regression and would love to have some help understanding why this happened. The postgres version if it's of any use is PostgreSQL 16.3 . The following query: ``` EXPLAIN ANALYZE SELECT "databases_metrics"."metrics" FROM "databases_metrics" WHERE ( "data

Empty query_id in pg_stat_activity

2024-12-06 Thread Costa Alexoglou
Hey folks, I am running Benchbase and pgbench at the same time just for debugging purposes, and I notice that sometimes query_id is missing from pg_stat_activity. Any clue why this is happening? ``` benchbase=# SELECT query_id, now() - query_start as duration, query FROM pg_stat_activity WHERE sta

Re: Used memory calculation in containers - docker stats and file cache

2024-11-04 Thread Costa Alexoglou
> I don't know if Docker does anything strange here. I am not sure if this is docker specific or cgroup comes into play. The measurement is implemented in docker CLI, but I would make the assumption that the eviction is done within the cgroup scope. > A large file (or many smaller files) which is

Re: insufficient privilege with pg_read_all_stats granted

2024-08-21 Thread Costa Alexoglou
> I think the problem is in the NOINHERIT attribute for the abcd role. Indeed that is the issue, thanks for helping find this out >

insufficient privilege with pg_read_all_stats granted

2024-08-20 Thread Costa Alexoglou
Hey folks, I run PostgreSQL v15.8 (docker official image), and there is an issue when reading pg_stat_staments table with a result of query most of the times having `` value. I have created the user that I use to fetch the data with the following way: ``` CREATE USER abcd WITH NOSUPERUSER NOCREAT

Re: Vacuum full connection exhaustion

2024-08-09 Thread Costa Alexoglou
On Fri, Aug 9, 2024 at 1:02 AM David Rowley wrote: > On Fri, 9 Aug 2024 at 02:12, Christophe Pettus wrote: > > VACUUM FULL takes an exclusive lock on the table that it is operating > on. It's possible that a connection becomes blocked on that exclusive lock > waiting for the VACUUM FULL to fini

Vacuum full connection exhaustion

2024-08-08 Thread Costa Alexoglou
Hey folks, I noticed something weird, and not sure if this is the expected behaviour or not in PostgreSQL. So I am running Benchbase (a benchmark framework) with 50 terminals (50 concurrent connections). There are 2-3 additional connections, one for a postgres-exporter container for example. So