Re: Free disk space decreasing after running Vaccum Full

From: Sabyasachi Mukherjee <mukherjee(dot)sabyasachi(at)outlook(dot)com>
To: Scott Ribe <scott_ribe(at)elevated-dev(dot)com>
Cc: Wells Oliver <wells(dot)oliver(at)gmail(dot)com>, Ron Johnson <ronljohnsonjr(at)gmail(dot)com>, Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: Free disk space decreasing after running Vaccum Full
Date: 2024-06-28 16:53:24
Message-ID: DB4PR10MB7469FE0143DE676E98748E4F8CD02@DB4PR10MB7469.EURPRD10.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Or I have to find a way to fix that replication. May be you can help me with that as well -
One error is as follows
2024-06-28 18:44:38.296 CEST [10000] STATEMENT: CREATE_REPLICATION_SLOT "pg_23568_sync_22182_7319873232440752272" LOGICAL pgoutput (SNAPSHOT 'use')
2024-06-28 18:44:38.318 CEST [11428] ERROR: duplicate key value violates unique constraint "bgw_job_stat_pkey"
2024-06-28 18:44:38.318 CEST [11428] DETAIL: Key (job_id)=(1) already exists.

The second error is -
2024-06-28 18:44:38.318 CEST [11428] CONTEXT: COPY bgw_job_stat, line 1
2024-06-28 18:44:38.337 CEST [4324] LOG: logical decoding found consistent point at 9D/AE199788
2024-06-28 18:44:38.337 CEST [4324] DETAIL: There are no running transactions.
2024-06-28 18:44:38.337 CEST [4324] STATEMENT: CREATE_REPLICATION_SLOT "pg_23568_sync_22389_7319873232440752272" LOGICAL pgoutput (SNAPSHOT 'use')
2024-06-28 18:44:38.355 CEST [4324] ERROR: syntax error at or near ")" at character 46
2024-06-28 18:44:38.355 CEST [4324] STATEMENT: COPY _timescaledb_cache.cache_inval_bgw_job () TO STDOUT
2024-06-28 18:44:38.355 CEST [10676] ERROR: could not start initial contents copy for table "_timescaledb_cache.cache_inval_bgw_job": ERROR: syntax error at or near ")"
      LINE 1: COPY _timescaledb_cache.cache_inval_bgw_job () TO STDOUT

Note I have timescale DB installed in the DB as well.

Some pointers would be helpful.

Sabyasachi Mukherjee
________________________________
From: Sabyasachi Mukherjee <mukherjee(dot)sabyasachi(at)outlook(dot)com>
Sent: 28 June 2024 18:23
To: Scott Ribe <scott_ribe(at)elevated-dev(dot)com>
Cc: Wells Oliver <wells(dot)oliver(at)gmail(dot)com>; Ron Johnson <ronljohnsonjr(at)gmail(dot)com>; Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: Free disk space decreasing after running Vaccum Full

I think Scott has a point. I do have a broken logical replication. And the replication is done on the same physical server. I will try to stop that replication.

________________________________
From: Scott Ribe <scott_ribe(at)elevated-dev(dot)com>
Sent: 28 June 2024 18:14
To: Sabyasachi Mukherjee <mukherjee(dot)sabyasachi(at)outlook(dot)com>
Cc: Wells Oliver <wells(dot)oliver(at)gmail(dot)com>; Ron Johnson <ronljohnsonjr(at)gmail(dot)com>; Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: Free disk space decreasing after running Vaccum Full

Perhaps WAL is accumulating from those table rewrites. Could be your WAL settings, and that the WAL will get reused eventually, which is no problem. Could be you have WAL archiving or replication slots, and archiving or replication is broken, and WAL will accumulate until it fills the disk.

That needs to be looked at. But the question still remains as to why you are running VACUUM FULL?

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Laurenz Albe 2024-06-29 04:31:01 Re: Strange "permission denied" errors on pg_restore
Previous Message Sabyasachi Mukherjee 2024-06-28 16:23:09 Re: Free disk space decreasing after running Vaccum Full