From: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
---|---|
To: | Marcelo Fernandes <marcefern7(at)gmail(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org |
Subject: | Re: Do stuck replication slots prevent autovacuum of running entirely? |
Date: | 2025-05-21 06:05:19 |
Message-ID: | f6ab24958373f40b44ae68e3a524740ff7df8bd2.camel@cybertec.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Wed, 2025-05-21 at 16:34 +1200, Marcelo Fernandes wrote:
> I am trying to understand if a stuck replication slot would be sufficient to
> stop an autovacuum of even starting.
>
> Couldn't the autovacuum process start, but fail to remove dead tuples that
> are still necessary by the replication slot? Why would it prevent autovacuum
> of even starting instead?
I cannot think of a reason why an abandoned replication slot (not sure what
you mean with "stuck") would keep an autovacuum worker from starting.
Typical reasons why autovacuum doesn't start running on a table are:
- there are already "autovacuum_max_workers" worker processes running
- the thresholds for dead or inserted tuples have not been crossed
- the statistics collector has a problem and doesn't gather statistics;
this applies mostly to v14 and older, see
https://www.cybertec-postgresql.com/en/stale-statistics-cause-table-bloat/
- the parameter "track_activities" was disabled, so that PostgreSQL doesn't
collect statistics
- the functions "pg_stat_reset" or "pg_stat_reset_single_table_counters"
are called repeatedly and wipe out table statistics
Yours,
Laurenz Albe
From | Date | Subject | |
---|---|---|---|
Next Message | hubert depesz lubaczewski | 2025-05-21 11:09:36 | Re: Postgres query tool not working when I right click |
Previous Message | Marcelo Fernandes | 2025-05-21 04:34:22 | Do stuck replication slots prevent autovacuum of running entirely? |